Skip to content

Commit 910fa76

Browse files
authored
[PWGCF] changed histogram name, and criteria for creating them (#15982)
1 parent 4f2c081 commit 910fa76

1 file changed

Lines changed: 64 additions & 43 deletions

File tree

PWGCF/TwoParticleCorrelations/Tasks/corrFit.cxx

Lines changed: 64 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -168,6 +168,7 @@ struct CorrFit {
168168
ConfigurableAxis axisDeltaEtaTpcFt0a{"axisDeltaEtaTpcFt0a", {32, -5.8, -2.6}, "delta eta axis, -5.8~-2.6 for TPC-FT0A,"};
169169
ConfigurableAxis axisDeltaEtaTpcFt0c{"axisDeltaEtaTpcFt0c", {32, 1.2, 4.2}, "delta eta axis, 1.2~4.2 for TPC-FT0C"};
170170
ConfigurableAxis axisDeltaEtaFt0aFt0c{"axisDeltaEtaFt0aFt0c", {32, -1.5, 3.0}, "delta eta axis"};
171+
ConfigurableAxis axisDeltaEtaTpcTpc{"axisDeltaEtaTpcTpc", {32, -0.8, 0.8}, "delta eta axis for TPC-TPC"};
171172
ConfigurableAxis axisPtTrigger{"axisPtTrigger", {VARIABLE_WIDTH, 0.2, 0.5, 1, 1.5, 2, 3, 4, 6, 10}, "pt trigger axis for histograms"};
172173
ConfigurableAxis axisPtAssoc{"axisPtAssoc", {VARIABLE_WIDTH, 0.2, 0.5, 1, 1.5, 2, 3, 4, 6, 10}, "pt associated axis for histograms"};
173174
ConfigurableAxis axisVtxMix{"axisVtxMix", {VARIABLE_WIDTH, -10, -9, -8, -7, -6, -5, -4, -3, -2, -1, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10}, "vertex axis for mixed event histograms"};
@@ -209,7 +210,7 @@ struct CorrFit {
209210
OutputObj<CorrelationContainer> sameTpcFt0c{"sameEvent_TPC_FT0C"};
210211
OutputObj<CorrelationContainer> mixedTpcFt0c{"mixedEvent_TPC_FT0C"};
211212
OutputObj<CorrelationContainer> sameFt0aFt0c{"sameEvent_FT0A_FT0C"};
212-
OutputObj<CorrelationContainer> mixedFt0aFt0c{"mixedEvent_FA_FT0C"};
213+
OutputObj<CorrelationContainer> mixedFt0aFt0c{"mixedEvent_FT0A_FT0C"};
213214
OutputObj<CorrelationContainer> sameTPC{"sameEvent_TPC"};
214215
OutputObj<CorrelationContainer> mixedTPC{"mixedEvent_TPC"};
215216

@@ -291,7 +292,8 @@ struct CorrFit {
291292
registry.get<TH1>(HIST("hEventCountSpecific"))->GetXaxis()->SetBinLabel(12, "MultCorrelation");
292293
registry.get<TH1>(HIST("hEventCountSpecific"))->GetXaxis()->SetBinLabel(13, "cfgEvSelV0AT0ACut");
293294
}
294-
if (doprocessSameFt0aFt0c || doprocessSameTpcFt0c || doprocessSameTPC) {
295+
296+
if ((doprocessSameFt0aFt0c || doprocessSameTpcFt0a || doprocessSameTpcFt0c || doprocessSameTPC) && cfgQaCheck) {
295297
registry.add("hPassedEventSelection", "Number of Event;; Count", {HistType::kTH1D, {{13, 0, 13}}});
296298
registry.get<TH1>(HIST("hPassedEventSelection"))->GetXaxis()->SetBinLabel(1, "all tracks");
297299
registry.get<TH1>(HIST("hPassedEventSelection"))->GetXaxis()->SetBinLabel(2, "after sel8");
@@ -342,8 +344,8 @@ struct CorrFit {
342344
registry.add("Trig_hist_FT0A_FT0C", "", {HistType::kTHnSparseF, {{axisSample, axisVertex, axisPtTrigger}}});
343345
}
344346
if (doprocessSameTPC) {
345-
registry.add("deltaEta_deltaPhi_same_TPC", "", {HistType::kTH2D, {axisDeltaPhi, axisDeltaEtaTpcFt0a}}); // check to see the delta eta and delta phi distribution
346-
registry.add("deltaEta_deltaPhi_mixed_TPC", "", {HistType::kTH2D, {axisDeltaPhi, axisDeltaEtaTpcFt0a}});
347+
registry.add("deltaEta_deltaPhi_same_TPC", "", {HistType::kTH2D, {axisDeltaPhi, axisDeltaEtaTpcTpc}}); // check to see the delta eta and delta phi distribution
348+
registry.add("deltaEta_deltaPhi_mixed_TPC", "", {HistType::kTH2D, {axisDeltaPhi, axisDeltaEtaTpcTpc}});
347349
registry.add("Trig_hist_TPC", "", {HistType::kTHnSparseF, {{axisSample, axisVertex, axisPtTrigger}}});
348350
}
349351

@@ -511,56 +513,45 @@ struct CorrFit {
511513

512514
registry.fill(HIST("hPassedEventSelection"), 0.5);
513515

514-
if (!collision.sel8()) {
516+
if (collision.sel8()) {
515517
registry.fill(HIST("hPassedEventSelection"), 1.5);
516518
}
517519

518-
if (!collision.selection_bit(o2::aod::evsel::kNoSameBunchPileup)) {
520+
if (collision.selection_bit(o2::aod::evsel::kNoSameBunchPileup)) {
519521
registry.fill(HIST("hPassedEventSelection"), 2.5);
520522
}
521523

522-
if (!collision.selection_bit(o2::aod::evsel::kNoTimeFrameBorder)) {
524+
if (collision.selection_bit(o2::aod::evsel::kNoTimeFrameBorder)) {
523525
registry.fill(HIST("hPassedEventSelection"), 3.5);
524526
}
525527

526-
if (!collision.selection_bit(o2::aod::evsel::kNoITSROFrameBorder)) {
528+
if (collision.selection_bit(o2::aod::evsel::kNoITSROFrameBorder)) {
527529
registry.fill(HIST("hPassedEventSelection"), 4.5);
528530
}
529531

530-
if (!collision.selection_bit(o2::aod::evsel::kIsGoodZvtxFT0vsPV)) {
532+
if (collision.selection_bit(o2::aod::evsel::kIsGoodZvtxFT0vsPV)) {
531533
registry.fill(HIST("hPassedEventSelection"), 5.5);
532534
}
533535

534-
if (!collision.selection_bit(o2::aod::evsel::kNoCollInTimeRangeStandard)) {
536+
if (collision.selection_bit(o2::aod::evsel::kNoCollInTimeRangeStandard)) {
535537
registry.fill(HIST("hPassedEventSelection"), 6.5);
536538
}
537539

538-
if (!collision.selection_bit(o2::aod::evsel::kIsGoodITSLayer0123)) {
540+
if (collision.selection_bit(o2::aod::evsel::kIsGoodITSLayer0123)) {
539541
registry.fill(HIST("hPassedEventSelection"), 7.5);
540542
}
541543

542-
if (!collision.selection_bit(o2::aod::evsel::kIsGoodITSLayersAll)) {
544+
if (collision.selection_bit(o2::aod::evsel::kIsGoodITSLayersAll)) {
543545
registry.fill(HIST("hPassedEventSelection"), 8.5);
544546
}
545547

546-
if (!collision.selection_bit(o2::aod::evsel::kNoCollInRofStandard)) {
548+
if (collision.selection_bit(o2::aod::evsel::kNoCollInRofStandard)) {
547549
registry.fill(HIST("hPassedEventSelection"), 9.5);
548550
}
549551

550-
if (!collision.selection_bit(o2::aod::evsel::kNoHighMultCollInPrevRof)) {
552+
if (collision.selection_bit(o2::aod::evsel::kNoHighMultCollInPrevRof)) {
551553
registry.fill(HIST("hPassedEventSelection"), 10.5);
552554
}
553-
554-
auto occupancy = collision.trackOccupancyInTimeRange();
555-
if ((occupancy < cfgEventSelection.cfgCutOccupancyLow || occupancy > cfgEventSelection.cfgCutOccupancyHigh)) {
556-
registry.fill(HIST("hPassedEventSelection"), 11.5);
557-
}
558-
559-
// V0A T0A 5 sigma cut
560-
float sigma = 5.0;
561-
if ((std::fabs(collision.multFV0A() - cfgFuncParas.fT0AV0AMean->Eval(collision.multFT0A())) > sigma * cfgFuncParas.fT0AV0ASigma->Eval(collision.multFT0A()))) {
562-
registry.fill(HIST("hPassedEventSelection"), 12.5);
563-
}
564555
}
565556

566557
double getPhiFT0(uint64_t chno, int i)
@@ -755,6 +746,7 @@ struct CorrFit {
755746
{
756747
int mult = 0;
757748
for (auto const& track : tracks) {
749+
758750
if (!trackSelected(track))
759751
continue;
760752
mult++;
@@ -776,8 +768,14 @@ struct CorrFit {
776768
// loop over all tracks
777769
for (auto const& track1 : tracks1) {
778770

779-
if (!trackSelected(track1))
780-
continue;
771+
if (cfgSystematics.cfgSystematicsVariation) {
772+
if (!trackSelectedSystematics(track1))
773+
continue;
774+
} else {
775+
if (!trackSelected(track1))
776+
continue;
777+
}
778+
781779
if (!getEfficiencyCorrection(triggerWeight, track1.eta(), track1.pt(), posZ))
782780
continue;
783781

@@ -810,22 +808,30 @@ struct CorrFit {
810808
// fill the right sparse and histograms
811809
if (system == SameEvent) {
812810
if (corType == kFT0A) {
813-
registry.fill(HIST("Assoc_amp_same_TPC_FT0A"), chanelid, ampl);
814-
registry.fill(HIST("deltaEta_deltaPhi_same_TPC_FT0A"), deltaPhi, deltaEta, ampl * eventWeight * triggerWeight);
811+
if (cfgQaCheck) {
812+
registry.fill(HIST("Assoc_amp_same_TPC_FT0A"), chanelid, ampl);
813+
registry.fill(HIST("deltaEta_deltaPhi_same_TPC_FT0A"), deltaPhi, deltaEta, ampl * eventWeight * triggerWeight);
814+
}
815815
sameTpcFt0a->getPairHist()->Fill(step, fSampleIndex, posZ, track1.pt(), multiplicity, deltaPhi, deltaEta, ampl * eventWeight * triggerWeight);
816816
} else if (corType == kFT0C) {
817-
registry.fill(HIST("Assoc_amp_same_TPC_FT0C"), chanelid, ampl);
818-
registry.fill(HIST("deltaEta_deltaPhi_same_TPC_FT0C"), deltaPhi, deltaEta, ampl * eventWeight * triggerWeight);
817+
if (cfgQaCheck) {
818+
registry.fill(HIST("Assoc_amp_same_TPC_FT0C"), chanelid, ampl);
819+
registry.fill(HIST("deltaEta_deltaPhi_same_TPC_FT0C"), deltaPhi, deltaEta, ampl * eventWeight * triggerWeight);
820+
}
819821
sameTpcFt0c->getPairHist()->Fill(step, fSampleIndex, posZ, track1.pt(), multiplicity, deltaPhi, deltaEta, ampl * eventWeight * triggerWeight);
820822
}
821823
} else if (system == MixedEvent) {
822824
if (corType == kFT0A) {
823-
registry.fill(HIST("Assoc_amp_mixed_TPC_FT0A"), chanelid, ampl);
824-
registry.fill(HIST("deltaEta_deltaPhi_mixed_TPC_FT0A"), deltaPhi, deltaEta, ampl * eventWeight * triggerWeight);
825+
if (cfgQaCheck) {
826+
registry.fill(HIST("Assoc_amp_mixed_TPC_FT0A"), chanelid, ampl);
827+
registry.fill(HIST("deltaEta_deltaPhi_mixed_TPC_FT0A"), deltaPhi, deltaEta, ampl * eventWeight * triggerWeight);
828+
}
825829
mixedTpcFt0a->getPairHist()->Fill(step, fSampleIndex, posZ, track1.pt(), multiplicity, deltaPhi, deltaEta, ampl * eventWeight * triggerWeight);
826830
} else if (corType == kFT0C) {
827-
registry.fill(HIST("Assoc_amp_mixed_TPC_FT0C"), chanelid, ampl);
828-
registry.fill(HIST("deltaEta_deltaPhi_mixed_TPC_FT0C"), deltaPhi, deltaEta, ampl * eventWeight * triggerWeight);
831+
if (cfgQaCheck) {
832+
registry.fill(HIST("Assoc_amp_mixed_TPC_FT0C"), chanelid, ampl);
833+
registry.fill(HIST("deltaEta_deltaPhi_mixed_TPC_FT0C"), deltaPhi, deltaEta, ampl * eventWeight * triggerWeight);
834+
}
829835
mixedTpcFt0c->getPairHist()->Fill(step, fSampleIndex, posZ, track1.pt(), multiplicity, deltaPhi, deltaEta, ampl * eventWeight * triggerWeight);
830836
}
831837
}
@@ -889,10 +895,14 @@ struct CorrFit {
889895

890896
// fill the right sparse and histograms
891897
if (system == SameEvent) {
892-
registry.fill(HIST("deltaEta_deltaPhi_same_FT0A_FT0C"), deltaPhi, deltaEta, amplA * amplC * eventWeight * triggerWeight);
898+
if (cfgQaCheck) {
899+
registry.fill(HIST("deltaEta_deltaPhi_same_FT0A_FT0C"), deltaPhi, deltaEta, amplA * amplC * eventWeight * triggerWeight);
900+
}
893901
sameFt0aFt0c->getPairHist()->Fill(step, fSampleIndex, posZ, 0.5, multiplicity, deltaPhi, deltaEta, amplA * amplC * eventWeight * triggerWeight);
894902
} else if (system == MixedEvent) {
895-
registry.fill(HIST("deltaEta_deltaPhi_mixed_FT0A_FT0C"), deltaPhi, deltaEta, amplA * amplC * eventWeight * triggerWeight);
903+
if (cfgQaCheck) {
904+
registry.fill(HIST("deltaEta_deltaPhi_mixed_FT0A_FT0C"), deltaPhi, deltaEta, amplA * amplC * eventWeight * triggerWeight);
905+
}
896906
mixedFt0aFt0c->getPairHist()->Fill(step, fSampleIndex, posZ, 0.5, multiplicity, deltaPhi, deltaEta, amplA * amplC * eventWeight * triggerWeight);
897907
}
898908
}
@@ -910,14 +920,19 @@ struct CorrFit {
910920
// loop over all tracks
911921
for (auto const& track1 : tracks1) {
912922

913-
if (!trackSelected(track1))
914-
continue;
923+
if (cfgSystematics.cfgSystematicsVariation) {
924+
if (!trackSelectedSystematics(track1))
925+
continue;
926+
} else {
927+
if (!trackSelected(track1))
928+
continue;
929+
}
915930

916931
if (!getEfficiencyCorrection(triggerWeight, track1.eta(), track1.pt(), posZ))
917932
continue;
918933

919934
if (system == SameEvent) {
920-
registry.fill(HIST("Trig_hist"), fSampleIndex, posZ, track1.pt(), triggerWeight);
935+
registry.fill(HIST("Trig_hist_TPC"), fSampleIndex, posZ, track1.pt(), triggerWeight);
921936
}
922937

923938
for (auto const& track2 : tracks2) {
@@ -957,12 +972,16 @@ struct CorrFit {
957972
if (system == SameEvent) {
958973

959974
sameTPC->getPairHist()->Fill(step, fSampleIndex, posZ, track1.pt(), multiplicity, deltaPhi, deltaEta);
960-
registry.fill(HIST("deltaEta_deltaPhi_same_TPC"), deltaPhi, deltaEta);
961-
975+
if (cfgQaCheck) {
976+
registry.fill(HIST("deltaEta_deltaPhi_same_TPC"), deltaPhi, deltaEta);
977+
}
962978
} else if (system == MixedEvent) {
963979

964980
mixedTPC->getPairHist()->Fill(step, fSampleIndex, posZ, track1.pt(), multiplicity, deltaPhi, deltaEta);
965-
registry.fill(HIST("deltaEta_deltaPhi_mixed_TPC"), deltaPhi, deltaEta);
981+
982+
if (cfgQaCheck) {
983+
registry.fill(HIST("deltaEta_deltaPhi_mixed_TPC"), deltaPhi, deltaEta);
984+
}
966985
}
967986
}
968987
}
@@ -1018,6 +1037,7 @@ struct CorrFit {
10181037
Pair<FilteredCollisions, FilteredTracks, FilteredTracks, MixedBinning> pairs{binningOnVtxAndMult, cfgMinMixEventNum, -1, collisions, tracksTuple, &cache}; // -1 is the number of the bin to skip
10191038
for (auto it = pairs.begin(); it != pairs.end(); it++) {
10201039
auto& [collision1, tracks1, collision2, tracks2] = *it;
1040+
10211041
if (!collision1.sel8() || !collision2.sel8())
10221042
continue;
10231043

@@ -1030,6 +1050,7 @@ struct CorrFit {
10301050
continue;
10311051

10321052
registry.fill(HIST("eventcount"), MixedEvent); // fill the mixed event in the 3 bin
1053+
10331054
auto bc = collision1.bc_as<aod::BCsWithTimestamps>();
10341055
loadAlignParam(bc.timestamp());
10351056
loadCorrection(bc.timestamp());

0 commit comments

Comments
 (0)