34 std::cout <<
"TpcLoadDistortionCorrection::InitRun - DST Node missing, quitting" << std::endl;
43 dstNode->addNode(svtxNode);
47 auto distortion_correction_object = findNode::getClass<TpcDistortionCorrectionContainer>( topNode,
m_node_name );
48 if( !distortion_correction_object )
50 std::cout <<
"TpcLoadDistortionCorrection::InitRun - creating TpcDistortionCorrectionContainer in node " <<
m_node_name << std::endl;
53 svtxNode->addNode(node);
56 std::cout <<
"TpcLoadDistortionCorrection::InitRun - reading distortions from " <<
m_distortion_filename << std::endl;
58 if( !distortion_tfile )
60 std::cout <<
"TpcLoadDistortionCorrection::InitRun - cannot open " <<
m_distortion_filename << std::endl;
64 const std::array<const std::string,2> extension = {{
"_negz",
"_posz" }};
65 for(
int i =0; i < 2; ++i )
67 distortion_correction_object->m_hDPint[i] =
dynamic_cast<TH3*
>(distortion_tfile->Get(Form(
"hIntDistortionP%s", extension[i].c_str()))); assert( distortion_correction_object->m_hDPint[i] );
68 distortion_correction_object->m_hDRint[i] =
dynamic_cast<TH3*
>(distortion_tfile->Get(Form(
"hIntDistortionR%s", extension[i].c_str()))); assert( distortion_correction_object->m_hDRint[i] );
69 distortion_correction_object->m_hDZint[i] =
dynamic_cast<TH3*
>(distortion_tfile->Get(Form(
"hIntDistortionZ%s", extension[i].c_str()))); assert( distortion_correction_object->m_hDZint[i] );
75 for(
int i =0; i < 2; ++i )
77 std::cout <<
"TpcLoadDistortionCorrection::InitRun - histogram: " << distortion_correction_object->m_hDPint[i]->GetName() << std::endl;
78 for(
const auto& axis:{
79 distortion_correction_object->m_hDPint[i]->GetXaxis(),
80 distortion_correction_object->m_hDPint[i]->GetYaxis(),
81 distortion_correction_object->m_hDPint[i]->GetZaxis() })
84 <<
"TpcLoadDistortionCorrection::InitRun -"
85 <<
" axis: " << axis->GetTitle()
86 <<
" bins: " << axis->GetNbins()
87 <<
" limits: " << axis->GetXmin() <<
" " << axis->GetXmax()