@@ -517,7 +517,7 @@ struct TrackTuner : o2::framework::ConfigurableGroup {
517
517
grDcaZPullVsPtPionData.reserve (nPhiBins);
518
518
519
519
// / Lambda expression to get the TGraphErrors from file
520
- auto loadGraph = [&](int phiBin, const std::string& strBaseName) -> std::unique_ptr< TGraphErrors> {
520
+ auto loadGraph = [&](int phiBin, const std::string& strBaseName) -> TGraphErrors* {
521
521
std::string strGraphName = inputNphiBins != 0 ? fmt::format (" {}_{}" , strBaseName, phiBin) : strBaseName;
522
522
TObject* obj = td->Get (strGraphName.c_str ());
523
523
if (!obj) {
@@ -534,30 +534,30 @@ struct TrackTuner : o2::framework::ConfigurableGroup {
534
534
for (int iPhiBin = 0 ; iPhiBin < nPhiBins; ++iPhiBin) {
535
535
536
536
grDcaXYResVsPtPionMC[iPhiBin].reset (loadGraph (iPhiBin, " resCurrentDcaXY" ));
537
- grDcaXYResVsPtPionData[iPhiBin].reset (loadGraph (iPhiBin, " resUpgrDcaXY" )() );
538
- grDcaXYMeanVsPtPionMC[iPhiBin].reset (loadGraph (iPhiBin, " meanCurrentDcaXY" )() );
539
- grDcaXYMeanVsPtPionData[iPhiBin].reset (loadGraph (iPhiBin, " meanUpgrDcaXY" )() );
540
- grDcaXYPullVsPtPionMC[iPhiBin].reset (loadGraph (iPhiBin, " pullsCurrentDcaXY" )() );
541
- grDcaXYPullVsPtPionData[iPhiBin].reset (loadGraph (iPhiBin, " pullsUpgrDcaXY" )() );
537
+ grDcaXYResVsPtPionData[iPhiBin].reset (loadGraph (iPhiBin, " resUpgrDcaXY" ));
538
+ grDcaXYMeanVsPtPionMC[iPhiBin].reset (loadGraph (iPhiBin, " meanCurrentDcaXY" ));
539
+ grDcaXYMeanVsPtPionData[iPhiBin].reset (loadGraph (iPhiBin, " meanUpgrDcaXY" ));
540
+ grDcaXYPullVsPtPionMC[iPhiBin].reset (loadGraph (iPhiBin, " pullsCurrentDcaXY" ));
541
+ grDcaXYPullVsPtPionData[iPhiBin].reset (loadGraph (iPhiBin, " pullsUpgrDcaXY" ));
542
542
543
543
if (!grDcaXYResVsPtPionMC[iPhiBin].get () || !grDcaXYResVsPtPionData[iPhiBin].get () || !grDcaXYMeanVsPtPionMC[iPhiBin].get () || !grDcaXYMeanVsPtPionData[iPhiBin].get () || !grDcaXYPullVsPtPionMC[iPhiBin].get () || !grDcaXYPullVsPtPionData[iPhiBin].get ()) {
544
- LOG (fatal) << " [TrackTuner] Something wrong with the names of the correction graphs for dcaXY. Fix it! Problematic phi bin is" << iPhiBin;
544
+ LOG (fatal) << " [TrackTuner] Something wrong with the names of the correction graphs for dcaXY. Fix it! Problematic phi bin is" << iPhiBin;
545
545
}
546
546
}
547
547
548
548
if (inputNphiBins != 0 ) {
549
549
LOG (info) << " [TrackTuner] Loading phi-dependent Z TGraphErrors" ;
550
550
}
551
551
for (int iPhiBin = 0 ; iPhiBin < nPhiBins; ++iPhiBin) {
552
- grDcaZResVsPtPionMC[iPhiBin].reset (loadGraph (iPhiBin, " resCurrentDcaZ" )() );
553
- grDcaZMeanVsPtPionMC[iPhiBin].reset (loadGraph (iPhiBin, " meanCurrentDcaZ" )() );
554
- grDcaZPullVsPtPionMC[iPhiBin].reset (loadGraph (iPhiBin, " pullsCurrentDcaZ" )() );
555
- grDcaZResVsPtPionData[iPhiBin].reset (loadGraph (iPhiBin, " resUpgrDcaZ" )() );
556
- grDcaZMeanVsPtPionData[iPhiBin].reset (loadGraph (iPhiBin, " meanUpgrDcaZ" )() );
557
- grDcaZPullVsPtPionData[iPhiBin].reset (loadGraph (iPhiBin, " pullsUpgrDcaZ" )() );
552
+ grDcaZResVsPtPionMC[iPhiBin].reset (loadGraph (iPhiBin, " resCurrentDcaZ" ));
553
+ grDcaZMeanVsPtPionMC[iPhiBin].reset (loadGraph (iPhiBin, " meanCurrentDcaZ" ));
554
+ grDcaZPullVsPtPionMC[iPhiBin].reset (loadGraph (iPhiBin, " pullsCurrentDcaZ" ));
555
+ grDcaZResVsPtPionData[iPhiBin].reset (loadGraph (iPhiBin, " resUpgrDcaZ" ));
556
+ grDcaZMeanVsPtPionData[iPhiBin].reset (loadGraph (iPhiBin, " meanUpgrDcaZ" ));
557
+ grDcaZPullVsPtPionData[iPhiBin].reset (loadGraph (iPhiBin, " pullsUpgrDcaZ" ));
558
558
559
559
if (!grDcaZResVsPtPionMC[iPhiBin].get () || !grDcaZResVsPtPionData[iPhiBin].get () || !grDcaZMeanVsPtPionMC[iPhiBin].get () || !grDcaZMeanVsPtPionData[iPhiBin].get () || !grDcaZPullVsPtPionMC[iPhiBin].get () || !grDcaZPullVsPtPionData[iPhiBin].get ()) {
560
- LOG (fatal) << " [TrackTuner] Something wrong with the names of the correction graphs for dcaZ. Fix it! Problematic phi bin is" << iPhiBin;
560
+ LOG (fatal) << " [TrackTuner] Something wrong with the names of the correction graphs for dcaZ. Fix it! Problematic phi bin is" << iPhiBin;
561
561
}
562
562
}
563
563
0 commit comments