@@ -367,6 +367,8 @@ struct PidFlowPtCorr {
367367 ConfigurableAxis cfgaxisPhi{" cfgaxisPhi" , {60 , 0.0 , constants::math::TwoPI}, " phi axis for histograms" };
368368 ConfigurableAxis cfgaxisEta{" cfgaxisEta" , {40 , -1 ., 1 .}, " eta axis for histograms" };
369369 ConfigurableAxis cfgaxisPt{" cfgaxisPt" , {VARIABLE_WIDTH , 0.20 , 0.25 , 0.30 , 0.35 , 0.40 , 0.45 , 0.50 , 0.55 , 0.60 , 0.65 , 0.70 , 0.75 , 0.80 , 0.85 , 0.90 , 0.95 , 1.00 , 1.10 , 1.20 , 1.30 , 1.40 , 1.50 , 1.60 , 1.70 , 1.80 , 1.90 , 2.00 , 2.20 , 2.40 , 2.60 , 2.80 , 3.00 , 3.50 , 4.00 , 4.50 , 5.00 , 5.50 , 6.00 , 10.0 }, " pt (GeV)" };
370+ ConfigurableAxis cfgaxisTPCDedx{" cfgaxisTPCDedx" , {500 , 0 .0f , 1000 .0f }, " d#it{E}/d#it{x} axis for detector-PID QA" };
371+ ConfigurableAxis cfgaxisTOFDelta{" cfgaxisTOFDelta" , {200 , -1000 .0f , 1000 .0f }, " TOF #it{t} - #it{t}_{ev} - #it{t}_{exp} axis for detector-PID QA" };
370372 ConfigurableAxis cfgaxisMeanPt{" cfgaxisMeanPt" , {300 , 0 , 3 }, " pt (GeV)" };
371373 ConfigurableAxis cfgaxisNch{" cfgaxisNch" , {3000 , 0.5 , 3000.5 }, " Nch" };
372374 ConfigurableAxis cfgaxisLocalDensity{" cfgaxisLocalDensity" , {200 , 0 , 600 }, " local density" };
@@ -393,8 +395,10 @@ struct PidFlowPtCorr {
393395 Filter trackFilter = ((requireGlobalTrackInFilter()) || (aod::track::isGlobalTrackSDD == (uint8_t )true )) && (nabs(aod::track::eta) < trkQualityOpts.cfgCutEta.value);
394396
395397 using TracksPID = soa::Join<aod::pidTPCPi, aod::pidTPCKa, aod::pidTPCPr, aod::pidTOFPi, aod::pidTOFKa, aod::pidTOFPr>;
398+ using TracksPIDForDetectorPidQA = soa::Join<aod::pidTPCPi, aod::pidTPCKa, aod::pidTPCPr, aod::pidTOFFullPi, aod::pidTOFFullKa, aod::pidTOFFullPr>;
396399 // data tracks filter
397400 using AodTracks = soa::Filtered<soa::Join<aod::Tracks, aod::TrackSelection, o2::aod::TrackSelectionExtension, aod::TracksExtra, TracksPID, aod::TracksIU, aod::TracksDCA>>;
401+ using AodTracksForDetectorPidQA = soa::Filtered<soa::Join<aod::Tracks, aod::TrackSelection, o2::aod::TrackSelectionExtension, aod::TracksExtra, TracksPIDForDetectorPidQA, aod::TracksIU, aod::TracksDCA>>;
398402 // data collisions filter
399403 using AodCollisions = soa::Filtered<soa::Join<aod::Collisions, aod::EvSels, aod::CentFT0Cs, aod::CentFT0CVariant1s, aod::CentFT0Ms, aod::CentFV0As, aod::CentNTPVs, aod::CentNGlobals, aod::CentMFTs, aod::MultsRun3>>;
400404
@@ -609,20 +613,15 @@ struct PidFlowPtCorr {
609613
610614 registry.add (" hNchUnCorrectedVSNchCorrected" , " " , {HistType::kTH2D , {cfgaxisNch, cfgaxisNch}});
611615 runNumbers = cfgRunNumbers;
612- // TPC vs TOF vs its, comparation graphs, check the PID performance in difference pt
616+ // Minimal detector- PID performance QA.
613617 if (switchsOpts.cfgOutputQA .value ) {
614- registry.add (" DetectorPidPerformace/TPCvsTOF/Pi " , " " , {HistType::kTH3D , {{ 320 , - 20 , 20 }, { 320 , - 20 , 20 }, cfgaxisPt }});
615- registry.add (" DetectorPidPerformace/TPCvsTOF/Pr " , " " , {HistType::kTH3D , {{ 320 , - 20 , 20 }, { 320 , - 20 , 20 }, cfgaxisPt }});
616- registry.add (" DetectorPidPerformace/TPCvsTOF/Ka " , " " , {HistType::kTH3D , {{ 320 , - 20 , 20 }, { 320 , - 20 , 20 }, cfgaxisPt }});
618+ registry.add (" DetectorPidQA/TPC/dEdxPi " , " TPC d#it{E}/d#it{x} (pion) " , {HistType::kTH2F , {cfgaxisPt, cfgaxisTPCDedx }});
619+ registry.add (" DetectorPidQA/TPC/dEdxKa " , " TPC d#it{E}/d#it{x} (kaon) " , {HistType::kTH2F , {cfgaxisPt, cfgaxisTPCDedx }});
620+ registry.add (" DetectorPidQA/TPC/dEdxPr " , " TPC d#it{E}/d#it{x} (proton) " , {HistType::kTH2F , {cfgaxisPt, cfgaxisTPCDedx }});
617621
618- registry.add (" DetectorPidPerformace/TPCvsITS/Pi" , " " , {HistType::kTH3D , {{320 , -20 , 20 }, {320 , -20 , 20 }, cfgaxisPt}});
619- registry.add (" DetectorPidPerformace/TPCvsITS/Pr" , " " , {HistType::kTH3D , {{320 , -20 , 20 }, {320 , -20 , 20 }, cfgaxisPt}});
620- registry.add (" DetectorPidPerformace/TPCvsITS/Ka" , " " , {HistType::kTH3D , {{320 , -20 , 20 }, {320 , -20 , 20 }, cfgaxisPt}});
621-
622- registry.add (" DetectorPidPerformace/ITSvsTOF/Pi" , " " , {HistType::kTH3D , {{320 , -20 , 20 }, {320 , -20 , 20 }, cfgaxisPt}});
623- registry.add (" DetectorPidPerformace/ITSvsTOF/Pr" , " " , {HistType::kTH3D , {{320 , -20 , 20 }, {320 , -20 , 20 }, cfgaxisPt}});
624- registry.add (" DetectorPidPerformace/ITSvsTOF/Ka" , " " , {HistType::kTH3D , {{320 , -20 , 20 }, {320 , -20 , 20 }, cfgaxisPt}});
625- // end TPC vs TOF vs its, comparation graphs
622+ registry.add (" DetectorPidQA/TOF/deltaPi" , " TOF #it{t} - #it{t}_{ev} - #it{t}_{exp} (pion)" , {HistType::kTH2F , {cfgaxisPt, cfgaxisTOFDelta}});
623+ registry.add (" DetectorPidQA/TOF/deltaKa" , " TOF #it{t} - #it{t}_{ev} - #it{t}_{exp} (kaon)" , {HistType::kTH2F , {cfgaxisPt, cfgaxisTOFDelta}});
624+ registry.add (" DetectorPidQA/TOF/deltaPr" , " TOF #it{t} - #it{t}_{ev} - #it{t}_{exp} (proton)" , {HistType::kTH2F , {cfgaxisPt, cfgaxisTOFDelta}});
626625
627626 // run by run QA hists
628627 /* *
@@ -3923,16 +3922,19 @@ struct PidFlowPtCorr {
39233922 PROCESS_SWITCH (PidFlowPtCorr, processQA, " " , true );
39243923
39253924 /* *
3926- * @brief this main function is used to check the PID performance of ITS TOC TPC, also used to do QA
3925+ * @brief Minimal PID- performance QA for TPC dE/dx and TOF time-of-flight.
39273926 * @note open switch outputQA if use it
39283927 *
39293928 * @param collision
39303929 * @param tracks
39313930 */
3932- void detectorPidQA (AodCollisions::iterator const & collision, aod::BCsWithTimestamps const &, AodTracks const & tracks)
3931+ void detectorPidQA (AodCollisions::iterator const & collision, aod::BCsWithTimestamps const &, AodTracksForDetectorPidQA const & tracks)
39333932 {
3933+ if (!switchsOpts.cfgOutputQA .value ) {
3934+ return ;
3935+ }
3936+
39343937 // cut and correction
3935- o2::aod::ITSResponse itsResponse;
39363938 int nTot = tracks.size ();
39373939 auto bc = collision.bc_as <aod::BCsWithTimestamps>();
39383940 int runNumber = bc.runNumber ();
@@ -3985,39 +3987,37 @@ struct PidFlowPtCorr {
39853987
39863988 // start filling graphs
39873989 for (const auto & track : tracks) {
3988- // track cut
3989- if (!trackSelectedGlobal (track)) {
3990- continue ;
3991- }
3992- if (!track.hasITS ()) {
3993- continue ;
3994- }
3995- if (!track.hasTPC ()) {
3996- continue ;
3997- }
3998- if (!trackSelected4ITS (track)) {
3990+ // Use the same track-quality, PID and species pT selection as processData.
3991+ if (!trackSelectedForFlow (track)) {
39993992 continue ;
40003993 }
4001- if (!trackSelected4TPC (track)) {
3994+ const int pid = getPidConfigurable (track);
3995+ if (!isWithinPOIPtRange (pid, track.pt ())) {
40023996 continue ;
40033997 }
4004- // end track cut
4005-
4006- // TPC TOF
4007- registry.fill (HIST (" DetectorPidPerformace/TPCvsTOF/Pi" ), track.tpcNSigmaPi (), track.tofNSigmaPi (), track.pt ());
4008- registry.fill (HIST (" DetectorPidPerformace/TPCvsTOF/Pr" ), track.tpcNSigmaPr (), track.tofNSigmaPr (), track.pt ());
4009- registry.fill (HIST (" DetectorPidPerformace/TPCvsTOF/Ka" ), track.tpcNSigmaKa (), track.tofNSigmaKa (), track.pt ());
4010-
4011- // TPC ITS
4012- registry.fill (HIST (" DetectorPidPerformace/TPCvsITS/Pi" ), track.tpcNSigmaPi (), itsResponse.nSigmaITS <o2::track::PID ::Pion>(track), track.pt ());
4013- registry.fill (HIST (" DetectorPidPerformace/TPCvsITS/Pr" ), track.tpcNSigmaPr (), itsResponse.nSigmaITS <o2::track::PID ::Proton>(track), track.pt ());
4014- registry.fill (HIST (" DetectorPidPerformace/TPCvsITS/Ka" ), track.tpcNSigmaKa (), itsResponse.nSigmaITS <o2::track::PID ::Kaon>(track), track.pt ());
4015-
4016- // ITS vs TOF
4017- registry.fill (HIST (" DetectorPidPerformace/ITSvsTOF/Pi" ), itsResponse.nSigmaITS <o2::track::PID ::Pion>(track), track.tofNSigmaPi (), track.pt ());
4018- registry.fill (HIST (" DetectorPidPerformace/ITSvsTOF/Pr" ), itsResponse.nSigmaITS <o2::track::PID ::Proton>(track), track.tofNSigmaPr (), track.pt ());
4019- registry.fill (HIST (" DetectorPidPerformace/ITSvsTOF/Ka" ), itsResponse.nSigmaITS <o2::track::PID ::Kaon>(track), track.tofNSigmaKa (), track.pt ());
40203998
3999+ switch (pid) {
4000+ case MyParticleType::kPion :
4001+ registry.fill (HIST (" DetectorPidQA/TPC/dEdxPi" ), track.tpcInnerParam (), track.tpcSignal ());
4002+ if (track.hasTOF ()) {
4003+ registry.fill (HIST (" DetectorPidQA/TOF/deltaPi" ), track.p (), o2::aod::pidutils::tofExpSignalDiff<o2::track::PID ::Pion>(track));
4004+ }
4005+ break ;
4006+ case MyParticleType::kKaon :
4007+ registry.fill (HIST (" DetectorPidQA/TPC/dEdxKa" ), track.tpcInnerParam (), track.tpcSignal ());
4008+ if (track.hasTOF ()) {
4009+ registry.fill (HIST (" DetectorPidQA/TOF/deltaKa" ), track.p (), o2::aod::pidutils::tofExpSignalDiff<o2::track::PID ::Kaon>(track));
4010+ }
4011+ break ;
4012+ case MyParticleType::kProton :
4013+ registry.fill (HIST (" DetectorPidQA/TPC/dEdxPr" ), track.tpcInnerParam (), track.tpcSignal ());
4014+ if (track.hasTOF ()) {
4015+ registry.fill (HIST (" DetectorPidQA/TOF/deltaPr" ), track.p (), o2::aod::pidutils::tofExpSignalDiff<o2::track::PID ::Proton>(track));
4016+ }
4017+ break ;
4018+ default :
4019+ break ;
4020+ }
40214021 } // end filling graphs
40224022 }
40234023 PROCESS_SWITCH (PidFlowPtCorr, detectorPidQA, " " , true );
0 commit comments