Skip to content

Commit

Permalink
[PWGCF] support for EP angle and few more event cuts (AliceO2Group#8904)
Browse files Browse the repository at this point in the history
  • Loading branch information
abilandz authored and Archita-Dash committed Dec 11, 2024
1 parent 47111fe commit e22f0c1
Show file tree
Hide file tree
Showing 5 changed files with 301 additions and 104 deletions.
15 changes: 10 additions & 5 deletions PWGCF/MultiparticleCorrelations/Core/MuPa-Configurables.h
Original file line number Diff line number Diff line change
Expand Up @@ -46,20 +46,20 @@ struct : ConfigurableGroup {
Configurable<bool> cfCheckUnderflowAndOverflow{"cfCheckUnderflowAndOverflow", false, "check and bail out if in event and particle histograms there are entries which went to underflow or overflow bins (use only locally)"};
Configurable<int> cfRebin{"cfRebin", 1, "number of bins of selected heavy 2D histograms are devided with this number"};
Configurable<bool> cfFillQAEventHistograms2D{"cfFillQAEventHistograms2D", false, "if false, all QA 2D event histograms are not filled. if true, only the ones for which fBookQAEventHistograms2D[...] is true, are filled"};
Configurable<vector<string>> cfBookQAEventHistograms2D{"cfBookQAEventHistograms2D", {"1-Multiplicity_vs_ReferenceMultiplicity", "1-Multiplicity_vs_NContributors", "1-Multiplicity_vs_Centrality", "1-Multiplicity_vs_Vertex_z", "1-Multiplicity_vs_Occupancy", "1-ReferenceMultiplicity_vs_NContributors", "1-ReferenceMultiplicity_vs_Centrality", "1-ReferenceMultiplicity_vs_Vertex_z", "1-ReferenceMultiplicity_vs_Occupancy", "1-NContributors_vs_Centrality", "1-NContributors_vs_Vertex_z", "1-NContributors_vs_Occupancy", "1-Centrality_vs_Vertex_z", "1-Centrality_vs_Occupancy", "1-Vertex_z_vs_Occupancy", "0-CentFT0C_vs_CentNTPV", "0-CentFT0M_vs_CentNTPV", "0-CentRun2V0M_vs_CentRun2SPDTracklets", "1-TrackOccupancyInTimeRange_vs_FT0COccupancyInTimeRange", "1-CurrentRunDuration_vs_InteractionRate"}, "book (1) or do not book (0) this QA 2D event histogram"};
Configurable<vector<string>> cfBookQAEventHistograms2D{"cfBookQAEventHistograms2D", {"1-Multiplicity_vs_ReferenceMultiplicity", "1-Multiplicity_vs_NContributors", "1-Multiplicity_vs_Centrality", "1-Multiplicity_vs_Vertex_z", "1-Multiplicity_vs_Occupancy", "1-ReferenceMultiplicity_vs_NContributors", "1-ReferenceMultiplicity_vs_Centrality", "1-ReferenceMultiplicity_vs_Vertex_z", "1-ReferenceMultiplicity_vs_Occupancy", "1-NContributors_vs_Centrality", "1-NContributors_vs_Vertex_z", "1-NContributors_vs_Occupancy", "1-Centrality_vs_Vertex_z", "1-Centrality_vs_Occupancy", "1-Centrality_vs_ImpactParameter", "1-Vertex_z_vs_Occupancy", "0-MultNTracksPV_vs_MultNTracksGlobal", "0-CentFT0C_vs_CentNTPV", "0-CentFT0M_vs_CentNTPV", "0-CentRun2V0M_vs_CentRun2SPDTracklets", "1-TrackOccupancyInTimeRange_vs_FT0COccupancyInTimeRange", "1-CurrentRunDuration_vs_InteractionRate"}, "book (1) or do not book (0) this QA 2D event histogram"};
Configurable<bool> cfFillQAParticleHistograms2D{"cfFillQAParticleHistograms2D", false, "if false, all QA 2D particle histograms are not filled. if true, only the ones for which fBookQAParticleHistograms2D[...] is true, are filled"};
Configurable<vector<string>> cfBookQAParticleHistograms2D{"cfBookQAParticleHistograms2D", {"1-Pt_vs_dcaXY"}, "book (1) or do not book (0) this QA 2D particle histogram"};
} cf_qa;

// *) Event histograms:
struct : ConfigurableGroup {
Configurable<bool> cfFillEventHistograms{"cfFillEventHistograms", true, "if false, all event histograms are not filled. if true, only the ones for which fBookEventHistograms[...] is true, are filled"};
Configurable<vector<string>> cfBookEventHistograms{"cfBookEventHistograms", {"1-NumberOfEvents", "1-TotalMultiplicity", "1-Multiplicity", "1-ReferenceMultiplicity", "1-Centrality", "1-Vertex_x", "1-Vertex_y", "1-Vertex_z", "1-NContributors", "0-ImpactParameter", "1-Occupancy", "1-InteractionRate", "1-CurrentRunDuration", "0-MultMCNParticlesEta08"}, "Book (1) or do not book (0) event histogram"};
Configurable<vector<string>> cfBookEventHistograms{"cfBookEventHistograms", {"1-NumberOfEvents", "1-TotalMultiplicity", "1-Multiplicity", "1-ReferenceMultiplicity", "1-Centrality", "1-Vertex_x", "1-Vertex_y", "1-Vertex_z", "1-NContributors", "0-ImpactParameter", "0-EventPlaneAngle", "1-Occupancy", "1-InteractionRate", "1-CurrentRunDuration", "0-MultMCNParticlesEta08"}, "Book (1) or do not book (0) event histogram"};
} cf_eh;

// *) Event cuts:
struct : ConfigurableGroup {
Configurable<vector<string>> cfUseEventCuts{"cfUseEventCuts", {"1-NumberOfEvents", "1-TotalMultiplicity", "1-Multiplicity", "1-ReferenceMultiplicity", "1-Centrality", "1-Vertex_x", "1-Vertex_y", "1-Vertex_z", "1-NContributors", "1-ImpactParameter", "1-Occupancy", "1-InteractionRate", "1-CurrentRunDuration", "0-MultMCNParticlesEta08", "0-Trigger", "0-Sel7", "1-Sel8", "1-MultiplicityEstimator", "1-ReferenceMultiplicityEstimator", "1-CentralityEstimator", "1-SelectedEvents", "1-NoSameBunchPileup", "1-IsGoodZvtxFT0vsPV", "1-IsVertexITSTPC", "1-IsVertexTOFmatched", "1-IsVertexTRDmatched", "1-OccupancyEstimator"}, "use (1) or do not use (0) event cuts"};
Configurable<vector<string>> cfUseEventCuts{"cfUseEventCuts", {"1-NumberOfEvents", "1-TotalMultiplicity", "1-Multiplicity", "1-ReferenceMultiplicity", "1-Centrality", "1-Vertex_x", "1-Vertex_y", "1-Vertex_z", "1-NContributors", "1-ImpactParameter", "0-EventPlaneAngle", "1-Occupancy", "1-InteractionRate", "1-CurrentRunDuration", "0-MultMCNParticlesEta08", "0-Trigger", "0-Sel7", "1-Sel8", "1-MultiplicityEstimator", "1-ReferenceMultiplicityEstimator", "1-CentralityEstimator", "1-SelectedEvents", "1-NoSameBunchPileup", "1-IsGoodZvtxFT0vsPV", "1-IsVertexITSTPC", "1-IsVertexTOFmatched", "1-IsVertexTRDmatched", "0-NoCollInTimeRangeStrict", "0-NoCollInTimeRangeStandard", "0-NoCollInRofStrict", "0-NoCollInRofStandard", "0-NoHighMultCollInPrevRof", "1-OccupancyEstimator"}, "use (1) or do not use (0) event cuts"};
Configurable<bool> cfUseEventCutCounterAbsolute{"cfUseEventCutCounterAbsolute", false, "profile and save how many times each event cut counter triggered (absolute). Use with care, as this is computationally heavy"};
Configurable<bool> cfUseEventCutCounterSequential{"cfUseEventCutCounterSequential", false, "profile and save how many times each event cut counter triggered (sequential). Use with care, as this is computationally heavy"};
Configurable<bool> cfPrintCutCounterContent{"cfPrintCutCounterContent", false, "if true, prints on the screen after each event the content of fEventCutCounterHist[*][*] (all which were booked)"};
Expand All @@ -74,11 +74,12 @@ struct : ConfigurableGroup {
Configurable<vector<float>> cfVertex_z{"cfVertex_z", {-10., 10.}, "vertex z position range: {min, max}[cm], with convention: min <= Vz < max"};
Configurable<vector<int>> cfNContributors{"cfNContributors", {2, 1000000000}, "Number of vertex contributors: {min, max}, with convention: min <= N < max"};
Configurable<vector<float>> cfImpactParameter{"cfImpactParameter", {-1, 1000000000}, "Impact parameter range (can be used only for sim): {min, max}, with convention: min <= IP < max"};
Configurable<vector<float>> cfEventPlaneAngle{"cfEventPlaneAngle", {-1000, 1000000000}, "Event Plane Angle range (can be used only for sim): {min, max}, with convention: min <= EP < max"};
Configurable<vector<float>> cfOccupancy{"cfOccupancy", {-2, 1000000000}, "Range for occupancy (use cfOccupancyEstimator to set specific estimator): {min, max}, with convention: min <= X < max"};
Configurable<vector<float>> cfInteractionRate{"cfInteractionRate", {-2, 1000000000}, "Range for interaction rate: {min, max}, with convention: min <= X < max"};
Configurable<vector<float>> cfCurrentRunDuration{"cfCurrentRunDuration", {-2, 1000000000}, "Range for current run duration (i.e. seconds since start of run) in seconds: {min, max}, with convention: min <= X < max. Only collisions taken in this range (measured from SOR) are taken for analysis"};
Configurable<vector<float>> cfMultMCNParticlesEta08{"cfMultMCNParticlesEta08", {-1, 1000000000}, "Range for MultMCNParticlesEta08 : {min, max}, with convention: min <= X < max"};
Configurable<string> cfTrigger{"cfTrigger", "some supported trigger (e.g. kINT7, ...)", "set here some supported trigger"};
Configurable<string> cfTrigger{"cfTrigger", "some supported trigger (e.g. INT7 for Run 2, TVXinTRD for Run 3, etc...)", "set here some supported trigger"};
Configurable<bool> cfUseSel7{"cfUseSel7", false, "use for Run 1 and 2 data and MC (see official doc)"};
Configurable<bool> cfUseSel8{"cfUseSel8", false, "use for Run 3 data and MC (see official doc)"};
Configurable<string> cfMultiplicityEstimator{"cfMultiplicityEstimator", "SelectedTracks", "all results vs. mult are calculated against this multiplicity. Can be set to SelectedTracks (calculated internally), ReferenceMultiplicity (calculated outside of my code), etc."};
Expand All @@ -92,7 +93,11 @@ struct : ConfigurableGroup {
Configurable<bool> cfUseIsVertexITSTPC{"cfUseIsVertexITSTPC", false, "TBI 20240521 explanation"};
Configurable<bool> cfUseIsVertexTOFmatched{"cfUseIsVertexTOFmatched", false, "TBI 20240521 explanation"};
Configurable<bool> cfUseIsVertexTRDmatched{"cfUseIsVertexTRDmatched", false, "TBI 20240521 explanation"};
// Configurable<string> cfOccupancyEstimator{"cfOccupancyEstimator", "some supported occupancy estimator (e.g. TrackOccupancyInTimeRange, FT0COccupancyInTimeRange, ...)", "set here some supported occupancy estimator (TrackOccupancyInTimeRange, FT0COccupancyInTimeRange, ..."};
Configurable<bool> cfUseNoCollInTimeRangeStrict{"cfUseNoCollInTimeRangeStrict", false, "TBI 20240521 explanation"};
Configurable<bool> cfUseNoCollInTimeRangeStandard{"cfUseNoCollInTimeRangeStandard", false, "TBI 20240521 explanation"};
Configurable<bool> cfUseNoCollInRofStrict{"cfUseNoCollInRofStrict", false, "TBI 20240521 explanation"};
Configurable<bool> cfUseNoCollInRofStandard{"cfUseNoCollInRofStandard", false, "TBI 20240521 explanation"};
Configurable<bool> cfUseNoHighMultCollInPrevRof{"cfUseNoHighMultCollInPrevRof", false, "TBI 20240521 explanation"};
Configurable<string> cfOccupancyEstimator{"cfOccupancyEstimator", "FT0COccupancyInTimeRange", "set here some supported occupancy estimator (TrackOccupancyInTimeRange, FT0COccupancyInTimeRange, ..."};
} cf_ec;

Expand Down
8 changes: 4 additions & 4 deletions PWGCF/MultiparticleCorrelations/Core/MuPa-DataMembers.h
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ struct Qvector {
struct MultiparticleCorrelations {
TList* fCorrelationsList = NULL; // list to hold all correlations objects
TProfile* fCorrelationsFlagsPro = NULL; // profile to hold all flags for correlations
Bool_t fCalculateCorrelations = kTRUE; // calculate and store integrated correlations
bool fCalculateCorrelations = false; // calculate and store integrated correlations
TProfile* fCorrelationsPro[4][gMaxHarmonic][eAsFunctionOf_N] = {{{NULL}}}; //! multiparticle correlations
// [2p=0,4p=1,6p=2,8p=3][n=1,n=2,...,n=gMaxHarmonic]
// [0=integrated,1=vs. multiplicity,2=vs. centrality,3=pT,4=eta,5=vs. occupancy]
Expand Down Expand Up @@ -300,15 +300,15 @@ struct EtaSeparations {
TProfile* fEtaSeparationsPro[gMaxHarmonic][gMaxNumberEtaSeparations][eAsFunctionOf_N]; // [harmonic, 0 = v1, 8 = v9][ different eta Separations - see that enum ] [ AFO ]
} es;

// *) Common cosmetics:
struct CommonCosmetics {
// *) Global cosmetics:
struct GlobalCosmetics {
TString srs[2] = {"rec", "sim"}; // used in the histogram name as index when saved to the file
TString srs_long[2] = {"reconstructed", "simulated"}; // used in the histogram title
TString sba[2] = {"before", "after"}; // used in the histogram name as index when saved to the file
TString sba_long[2] = {"before cuts", "after cuts"}; // used in the histogram title
TString scc[eCutCounter_N] = {"abs", "seq"}; // used in the histogram name as index when saved to the file
TString scc_long[eCutCounter_N] = {"absolute", "sequential"}; // used in the histogram title
} cc;
} gc;

// *) Results:
struct Results { // This is in addition also sort of "abstract" interface, which defines common binning, etc., for other groups of histograms.
Expand Down
25 changes: 18 additions & 7 deletions PWGCF/MultiparticleCorrelations/Core/MuPa-Enums.h
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,7 @@ enum eEventHistograms {
eVertex_z,
eNContributors, // number of tracks used for the vertex
eImpactParameter,
eEventPlaneAngle,
eOccupancy, // from helper task o2-analysis-event-selection, see also IA's presentation in https://indico.cern.ch/event/1464946, slide 38. Use specific occupancy estimator via eOccupancyEstimator
eInteractionRate, // from utility ctpRateFetcher
eCurrentRunDuration, // calculated with utility ctpRateFetcher
Expand All @@ -113,7 +114,10 @@ enum eEventHistograms {
enum eEventCuts {
// a) For available event selection bits, check https://github.com/AliceO2Group/O2Physics/blob/master/Common/CCDB/EventSelectionParams.cxx
// b) Some settings are configurable, check: https://github.com/AliceO2Group/O2Physics/blob/master/Common/TableProducer/eventSelection.cxx
eTrigger = eEventHistograms_N, // Do NOT use eTrigger for Run 3. Validated only for Run 2, and it has to be "kINT7" . TBI 20240522 investigate for Run 1
eTrigger = eEventHistograms_N, // Implemented and validated so far:
// a) Run 3: "kTVXinTRD" (use optionally for systematics, and only in real data)
// b) Run 2: "kINT7" (at the moment the usage of this one is enfored in fact)
// c) Run 1: TBI 20241209 check if I can use kINT7 also for Run 1
eSel7, // See def. of sel7 in Ref. b) above. Event selection decision based on V0A & V0C => use only in Run 2 and Run 1. TBI 20240522 I stil need to validate this one over MC
eSel8, // See def. of sel7 in Ref. b) above. Event selection decision based on TVX => use only in Run 3, both for data and MC
// *) As of 20240410, kNoITSROFrameBorder (only in MC) and kNoTimeFrameBorder event selection cuts are part of Sel8
Expand All @@ -127,6 +131,11 @@ enum eEventCuts {
eIsVertexITSTPC, // at least one ITS-TPC track (reject vertices built from ITS-only tracks) (emails from IA on 20240404 and EK on 20240410
eIsVertexTOFmatched, // at least one of vertex contributors is matched to TOF
eIsVertexTRDmatched, // at least one of vertex contributors is matched to TRD
eNoCollInTimeRangeStrict, // rejects a collision if there are other events in dtime +/- 10 μs, see IA Slide 39 in https://indico.cern.ch/event/1462154/
eNoCollInTimeRangeStandard, // rejects a collision if there are other events in dtime +/- 2 μs + additional cuts on multiplicity, see IA Slide 39 in https://indico.cern.ch/event/1462154/
eNoCollInRofStrict, // rejects a collision if there are other events within the same ROF (in-ROF pileup), ROF = "ITS Readout Frames", see IA Slide 39 in https://indico.cern.ch/event/1462154/
eNoCollInRofStandard, // same as previous + additional cuts on multiplicity, see IA Slide 39 in https://indico.cern.ch/event/1462154/
eNoHighMultCollInPrevRof, // veto an event if FT0C amplitude in previous ITS ROF is above threshold (default is >5000 a.e. by FT0C), see IA Slide 39 in https://indico.cern.ch/event/1462154/
eOccupancyEstimator, // the default Occupancy estimator, set via configurable. All supported centrality estimators, for QA, etc, are in enum eOccupancyEstimators
eEventCuts_N
};
Expand Down Expand Up @@ -248,15 +257,16 @@ enum eQAEventHistograms2D {
eNContributors_vs_Occupancy,
eCentrality_vs_Vertex_z,
eCentrality_vs_Occupancy,
eCentrality_vs_ImpactParameter, // [sim] = reconstructed centrality vs. simulated impact parameter. [rec] = ... TBI 20241210
eVertex_z_vs_Occupancy,
// ...
// Specific (everything is hardwired):
eMultNTracksPV_vs_MultNTracksGlobal, // Run 3 multiplicity
eCentFT0C_vs_CentNTPV, // Run 3 centrality
eCentFT0M_vs_CentNTPV, // Run 3 centrality
eCentRun2V0M_vs_CentRun2SPDTracklets, // Run 2 centrality (do not use in Run 1 converted, because there is no centrality information)
eTrackOccupancyInTimeRange_vs_FT0COccupancyInTimeRange,
eCurrentRunDuration_vs_InteractionRate,
// ...
eCurrentRunDuration_vs_InteractionRate, // ...
eQAEventHistograms2D_N
};

Expand All @@ -268,10 +278,11 @@ enum eQAParticleHistograms2D {
enum eReferenceMultiplicityEstimators {
// Run 3:
eMultTPC = 0,
eMultFV0M, // ref. mult from helper task o2-analysis-multiplicity-table
eMultFT0C, // ref. mult from helper task o2-analysis-multiplicity-table
eMultFT0M, // ref. mult from helper task o2-analysis-multiplicity-table
eMultNTracksPV, // ref. mult from helper task o2-analysis-multiplicity-table
eMultFV0M, // ref. mult from helper task o2-analysis-multiplicity-table
eMultFT0C, // ref. mult from helper task o2-analysis-multiplicity-table
eMultFT0M, // ref. mult from helper task o2-analysis-multiplicity-table
eMultNTracksPV, // ref. mult from helper task o2-analysis-multiplicity-table
eMultNTracksGlobal, // ref. mult from helper task o2-analysis-multiplicity-table
// Run 2:
eMultTracklets, // ref. mult from helper task o2-analysis-multiplicity-table, use only for Run 2
eReferenceMultiplicityEstimators_N
Expand Down
Loading

0 comments on commit e22f0c1

Please sign in to comment.