1- // Copyright 2019- 2020 CERN and copyright holders of ALICE O2.
2- // See https://alice-o2.web.cern.ch/copyright for details of the copyright
3- // holders. All rights not expressly granted are reserved.
1+ // Copyright 2020-2022 CERN and copyright holders of ALICE O2.
2+ // See https://alice-o2.web.cern.ch/copyright for details of the copyright holders.
3+ // All rights not expressly granted are reserved.
44//
55// This software is distributed under the terms of the GNU General Public
66// License v3 (GPL Version 3), copied verbatim in the file "COPYING".
@@ -97,21 +97,18 @@ struct RecoilJets {
9797 Configurable<float > trkEtaCut{" trkEtaCut" , 0.9 , " Eta acceptance of TPC" };
9898 Configurable<float > jetR{" jetR" , 0.4 , " Jet cone radius" };
9999
100- Configurable<std::string> triggerMasks{
101- " triggerMasks" , " " , " Relevant trigger masks: fTrackLowPt,fTrackHighPt" };
102- Configurable<bool > skipMBGapEvents{
103- " skipMBGapEvents" , false ,
104- " flag to choose to reject min. bias gap events; jet-level rejection "
105- " applied at the jet finder level, here rejection is applied for "
106- " collision and track process functions" };
100+ Configurable<std::string> triggerMasks{" triggerMasks" , " " ,
101+ " Relevant trigger masks: fTrackLowPt,fTrackHighPt" };
102+ Configurable<bool > skipMBGapEvents{" skipMBGapEvents" , false ,
103+ " flag to choose to reject min. bias gap events; jet-level rejection "
104+ " applied at the jet finder level, here rejection is applied for "
105+ " collision and track process functions" };
107106
108107 // List of configurable parameters for MC
109- Configurable<float > pTHatExponent{
110- " pTHatExponent" , 4.0 ,
111- " Exponent of the event weight for the calculation of pTHat" };
112- Configurable<float > pTHatMax{
113- " pTHatMax" , 999.0 ,
114- " Maximum fraction of hard scattering for jet acceptance in MC" };
108+ Configurable<float > pTHatExponent{" pTHatExponent" , 4.0 ,
109+ " Exponent of the event weight for the calculation of pTHat" };
110+ Configurable<float > pTHatMax{" pTHatMax" , 999.0 ,
111+ " Maximum fraction of hard scattering for jet acceptance in MC" };
115112
116113 // Parameters for recoil jet selection
117114 Configurable<float > ptTTrefMin{" ptTTrefMin" , 5 .,
@@ -124,8 +121,8 @@ struct RecoilJets {
124121 " Width of recoil acceptance" };
125122
126123 // List of configurable parameters for histograms
127- Configurable<uint16_t > histJetPt{
128- " histJetPt " , 100 , " Maximum value of jet pT shown in histograms" };
124+ Configurable<uint16_t > histJetPt{" histJetPt " , 100 ,
125+ " Maximum value of jet pT shown in histograms" };
129126
130127 // Axes specification
131128 AxisSpec pT{histJetPt, 0.0 , histJetPt * 1.0 , " #it{p}_{T} (GeV/#it{c})" };
@@ -426,8 +423,8 @@ struct RecoilJets {
426423
427424 // Fill histograms with raw or MC det. level data
428425 template <typename Collision, typename Jets, typename Tracks>
429- void fillHistograms (Collision const & collision, Jets const & jets,
430- Tracks const & tracks, float weight = 1 .) {
426+ void fillHistograms (Collision const & collision, Jets const & jets,
427+ Tracks const & tracks, float weight = 1 .) {
431428 bool bSigEv = false ;
432429 std::vector<double > vPhiOfTT;
433430 double phiTT = 0 .;
@@ -439,14 +436,14 @@ struct RecoilJets {
439436 bSigEv = true ;
440437
441438 // Remove whole event if jet passes the outlier removal condition
442- for (const auto & jet : jets) {
439+ for (const auto & jet : jets) {
443440 if (jet.pt () > pTHatMax * pTHat) {
444441 spectra.fill (HIST (" hEventSelectionCount" ), 2.5 );
445442 return ;
446443 }
447444 }
448445
449- for (const auto & track : tracks) {
446+ for (const auto & track : tracks) {
450447 spectra.fill (HIST (" hTrackSelectionCount" ), 0.5 );
451448
452449 if (skipTrack (track))
@@ -482,7 +479,7 @@ struct RecoilJets {
482479 }
483480 }
484481
485- for (const auto & jet : jets) {
482+ for (const auto & jet : jets) {
486483 spectra.fill (HIST (" hJetPtEtaPhiRhoArea" ), jet.pt (), jet.eta (), jet.phi (),
487484 collision.rho (), jet.area (), weight);
488485
@@ -534,14 +531,14 @@ struct RecoilJets {
534531 if (dice < fracSig)
535532 bSigEv = true ;
536533
537- for (const auto & jet : jets) {
534+ for (const auto & jet : jets) {
538535 if (jet.pt () > pTHatMax * pTHat) {
539536 spectra.fill (HIST (" hEventSelectionCountPartLevel" ), 1.5 );
540537 return ;
541538 }
542539 }
543540
544- for (const auto & particle : particles) {
541+ for (const auto & particle : particles) {
545542 auto pdgParticle = pdg->GetParticle (particle.pdgCode ());
546543 if (!pdgParticle)
547544 continue ;
@@ -580,7 +577,7 @@ struct RecoilJets {
580577 }
581578 }
582579
583- for (const auto & jet : jets) {
580+ for (const auto & jet : jets) {
584581 spectra.fill (HIST (" hJetPtEtaPhiRhoArea_Part" ), jet.pt (), jet.eta (),
585582 jet.phi (), collision.rho (), jet.area (), weight);
586583
@@ -628,12 +625,12 @@ struct RecoilJets {
628625 double phiTTSig = 0 .;
629626 float pTHat = getPtHat (weight);
630627
631- for (const auto & jetBase : jetsBase) {
628+ for (const auto & jetBase : jetsBase) {
632629 if (jetBase.pt () > pTHatMax * pTHat)
633630 return ;
634631 }
635632
636- for (const auto & track : tracks) {
633+ for (const auto & track : tracks) {
637634 if (skipTrack (track))
638635 continue ;
639636
@@ -647,7 +644,7 @@ struct RecoilJets {
647644 if (bIsThereTTSig)
648645 phiTTSig = getPhiTT (vPhiOfTT);
649646
650- for (const auto & jetBase : jetsBase) {
647+ for (const auto & jetBase : jetsBase) {
651648 bool bIsBaseJetRecoil =
652649 get<1 >(isRecoilJet (jetBase, phiTTSig)) && bIsThereTTSig;
653650 dataForUnfolding (jetBase, jetsTag, bIsBaseJetRecoil, weight);
@@ -678,8 +675,8 @@ struct RecoilJets {
678675
679676 // ------------------------------------------------------------------------------
680677 // Process functions
681- void processData (FilteredColl const & collision, FilteredTracks const & tracks,
682- FilteredJets const & jets) {
678+ void processData (FilteredColl const & collision, FilteredTracks const & tracks,
679+ FilteredJets const & jets) {
683680 spectra.fill (HIST (" hEventSelectionCount" ), 0.5 );
684681
685682 if (skipEvent (collision))
@@ -692,9 +689,9 @@ struct RecoilJets {
692689 }
693690 PROCESS_SWITCH (RecoilJets, processData, " process data" , true );
694691
695- void processMCDetLevel (FilteredColl const & collision,
696- FilteredTracks const & tracks,
697- FilteredJetsDetLevel const & jets) {
692+ void processMCDetLevel (FilteredColl const & collision,
693+ FilteredTracks const & tracks,
694+ FilteredJetsDetLevel const & jets) {
698695 spectra.fill (HIST (" hEventSelectionCount" ), 0.5 );
699696 if (skipEvent (collision) || skipMBGapEvent (collision))
700697 return ;
@@ -707,10 +704,10 @@ struct RecoilJets {
707704 PROCESS_SWITCH (RecoilJets, processMCDetLevel, " process MC detector level" ,
708705 false );
709706
710- void processMCDetLevelWeighted (FilteredCollDetLevelGetWeight const & collision,
711- aod::JetMcCollisions const &,
712- FilteredTracks const & tracks,
713- FilteredJetsDetLevel const & jets) {
707+ void processMCDetLevelWeighted (FilteredCollDetLevelGetWeight const & collision,
708+ aod::JetMcCollisions const &,
709+ FilteredTracks const & tracks,
710+ FilteredJetsDetLevel const & jets) {
714711 spectra.fill (HIST (" hEventSelectionCount" ), 0.5 );
715712 if (skipEvent (collision) || skipMBGapEvent (collision))
716713 return ;
@@ -731,9 +728,9 @@ struct RecoilJets {
731728 PROCESS_SWITCH (RecoilJets, processMCDetLevelWeighted,
732729 " process MC detector level with event weight" , false );
733730
734- void processMCPartLevel (FilteredCollPartLevel const & collision,
735- FilteredParticles const & particles,
736- FilteredJetsPartLevel const & jets) {
731+ void processMCPartLevel (FilteredCollPartLevel const & collision,
732+ FilteredParticles const & particles,
733+ FilteredJetsPartLevel const & jets) {
737734 spectra.fill (HIST (" hEventSelectionCountPartLevel" ), 0.5 );
738735 if (skipMBGapEvent (collision))
739736 return ;
@@ -744,9 +741,9 @@ struct RecoilJets {
744741 PROCESS_SWITCH (RecoilJets, processMCPartLevel, " process MC particle level" ,
745742 false );
746743
747- void processMCPartLevelWeighted (FilteredCollPartLevel const & collision,
748- FilteredParticles const & particles,
749- FilteredJetsPartLevel const & jets) {
744+ void processMCPartLevelWeighted (FilteredCollPartLevel const & collision,
745+ FilteredParticles const & particles,
746+ FilteredJetsPartLevel const & jets) {
750747 spectra.fill (HIST (" hEventSelectionCountPartLevel" ), 0.5 );
751748 if (skipMBGapEvent (collision))
752749 return ;
@@ -767,11 +764,11 @@ struct RecoilJets {
767764 PROCESS_SWITCH (RecoilJets, processMCPartLevelWeighted,
768765 " process MC particle level with event weight" , false );
769766
770- void processJetsMatched (FilteredCollDetLevelGetWeight const & collision,
771- aod::JetMcCollisions const &,
772- FilteredTracks const & tracks,
773- FilteredMatchedJetsDetLevel const & mcdjets,
774- FilteredMatchedJetsPartLevel const & mcpjets) {
767+ void processJetsMatched (FilteredCollDetLevelGetWeight const & collision,
768+ aod::JetMcCollisions const &,
769+ FilteredTracks const & tracks,
770+ FilteredMatchedJetsDetLevel const & mcdjets,
771+ FilteredMatchedJetsPartLevel const & mcpjets) {
775772 if (skipEvent (collision) || skipMBGapEvent (collision))
776773 return ;
777774
@@ -784,11 +781,11 @@ struct RecoilJets {
784781 " process matching of MC jets (no weight)" , false );
785782
786783 void
787- processJetsMatchedWeighted (FilteredCollDetLevelGetWeight const & collision,
788- aod::JetMcCollisions const &,
789- FilteredTracks const & tracks,
790- FilteredMatchedJetsDetLevel const & mcdjets,
791- FilteredMatchedJetsPartLevel const & mcpjets) {
784+ processJetsMatchedWeighted (FilteredCollDetLevelGetWeight const & collision,
785+ aod::JetMcCollisions const &,
786+ FilteredTracks const & tracks,
787+ FilteredMatchedJetsDetLevel const & mcdjets,
788+ FilteredMatchedJetsPartLevel const & mcpjets) {
792789 if (skipEvent (collision) || skipMBGapEvent (collision))
793790 return ;
794791
@@ -801,7 +798,7 @@ struct RecoilJets {
801798 PROCESS_SWITCH (RecoilJets, processJetsMatchedWeighted,
802799 " process matching of MC jets (weighted)" , false );
803800
804- void processMultiplicity (FilteredEventMultiplicity const & collision) {
801+ void processMultiplicity (FilteredEventMultiplicity const & collision) {
805802 if (skipEvent (collision))
806803 return ;
807804
@@ -852,10 +849,10 @@ struct RecoilJets {
852849 bool bIsThereMatchedJet = partJet.has_matchedJetGeo ();
853850
854851 if (bIsThereMatchedJet) {
855- const auto & jetsMatched =
852+ const auto & jetsMatched =
856853 partJet.template matchedJetGeo_as <std::decay_t <DetJet>>();
857854
858- for (const auto & jetMatched : jetsMatched) {
855+ for (const auto & jetMatched : jetsMatched) {
859856 spectra.fill (HIST (" hNumberMatchedJetsPerOneBaseJet" ),
860857 jetsMatched.size (), jetMatched.pt (), weight);
861858 spectra.fill (HIST (" hJetPt_DetLevel_vs_PartLevel" ), jetMatched.pt (),
@@ -884,7 +881,7 @@ struct RecoilJets {
884881 }
885882
886883 // Fake jets
887- for (const auto & detJet : detJets) {
884+ for (const auto & detJet : detJets) {
888885 bIsThereMatchedJet = detJet.has_matchedJetGeo ();
889886 if (!bIsThereMatchedJet) {
890887 spectra.fill (HIST (" hFakeJets_pT" ), detJet.pt (), weight);
0 commit comments