Skip to content

Commit 3211fd5

Browse files
committed
Please consider the following formatting changes
1 parent ea38636 commit 3211fd5

File tree

1 file changed

+49
-52
lines changed

1 file changed

+49
-52
lines changed

PWGJE/Tasks/jetSpectraCharged.cxx

Lines changed: 49 additions & 52 deletions
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,6 @@ struct JetSpectraCharged {
8383
Configurable<bool> checkGeoPtMatched{"checkGeoPtMatched", false, "0: turn off geometry and pT matching, 1: do geometry and pT matching"};
8484
Configurable<int> acceptSplitCollisions{"acceptSplitCollisions", 0, "0: only look at mcCollisions that are not split; 1: accept split mcCollisions, 2: accept split mcCollisions but only look at the first reco collision associated with it"};
8585

86-
8786
std::vector<int> eventSelectionBits;
8887
int trackSelection = -1;
8988

@@ -111,7 +110,7 @@ struct JetSpectraCharged {
111110
}
112111
}
113112

114-
if (doprocessSpectraData || doprocessSpectraMCD || doprocessSpectraMCDWeighted){
113+
if (doprocessSpectraData || doprocessSpectraMCD || doprocessSpectraMCDWeighted) {
115114
registry.add("h_jet_pt", "jet pT;#it{p}_{T,jet} (GeV/#it{c}); counts", {HistType::kTH1F, {jetPtAxis}});
116115
registry.add("h_jet_eta", "jet eta;#eta; counts", {HistType::kTH1F, {jetEtaAxis}});
117116
registry.add("h_jet_phi", "jet phi;#phi; counts", {HistType::kTH1F, {phiAxis}});
@@ -182,7 +181,7 @@ struct JetSpectraCharged {
182181
registry.add("h2_jet_pt_part_jet_area_part_rhoareasubtracted", "part jet #it{p}_{T,jet} vs. Area_{jet}; #it{p}_{T,jet}^{part} (GeV/#it{c}); Area_{jet}^{part}", {HistType::kTH2F, {jetPtAxisRhoAreaSub, {150, 0., 1.5}}});
183182
registry.add("h2_jet_pt_part_jet_ntracks_part_rhoareasubtracted", "part jet #it{p}_{T,jet} vs. N_{jet tracks}; #it{p}_{T,jet}^{part} (GeV/#it{c}); N_{jet, tracks}{part}", {HistType::kTH2F, {jetPtAxisRhoAreaSub, {200, -0.5, 199.5}}});
184183
registry.add("h3_jet_pt_eta_phi_part_rhoareasubtracted", "part jet pt vs. eta vs.phi", {HistType::kTH3F, {jetPtAxisRhoAreaSub, jetEtaAxis, phiAxis}});
185-
}
184+
}
186185

187186
if (doprocessEvtWiseConstSubJetsData || doprocessEvtWiseConstSubJetsMCD) {
188187
registry.add("h2_centrality_jet_pt_eventwiseconstituentsubtracted", "centrality vs. jet pT;centrality;#it{p}_{T,jet} (GeV/#it{c});entries", {HistType::kTH2F, {centralityAxis, jetPtAxis}});
@@ -325,7 +324,7 @@ struct JetSpectraCharged {
325324
registry.fill(HIST("h3_jet_pt_eta_phi_part"), jet.pt(), jet.eta(), jet.phi(), weight);
326325
registry.fill(HIST("h2_jet_pt_part_jet_area_part"), jet.pt(), jet.area(), weight);
327326
registry.fill(HIST("h2_jet_pt_part_jet_ntracks_part"), jet.pt(), jet.tracksIds().size(), weight);
328-
}
327+
}
329328

330329
for (const auto& constituent : jet.template tracks_as<aod::JetParticles>()) {
331330
registry.fill(HIST("h2_jet_pt_part_track_pt_part"), jet.pt(), constituent.pt(), weight);
@@ -337,14 +336,14 @@ struct JetSpectraCharged {
337336
{
338337
if (jet.r() == round(selectedJetsRadius * 100.0f)) {
339338
// fill mcp jet histograms
340-
double jetcorrpt = jet.pt() - (rho * jet.area());
341-
registry.fill(HIST("h_jet_pt_part_rhoareasubtracted"), jetcorrpt, weight);
342-
registry.fill(HIST("h3_jet_pt_eta_phi_part_rhoareasubtracted"), jetcorrpt, jet.eta(), jet.phi(), weight);
343-
if (jetcorrpt > 0) {
344-
registry.fill(HIST("h_jet_eta_part_rhoareasubtracted"), jet.eta(), weight);
345-
registry.fill(HIST("h_jet_phi_part_rhoareasubtracted"), jet.phi(), weight);
346-
registry.fill(HIST("h2_jet_pt_part_jet_area_part_rhoareasubtracted"), jetcorrpt, jet.area(), weight);
347-
registry.fill(HIST("h2_jet_pt_part_jet_ntracks_part_rhoareasubtracted"), jetcorrpt, jet.tracksIds().size(), weight);
339+
double jetcorrpt = jet.pt() - (rho * jet.area());
340+
registry.fill(HIST("h_jet_pt_part_rhoareasubtracted"), jetcorrpt, weight);
341+
registry.fill(HIST("h3_jet_pt_eta_phi_part_rhoareasubtracted"), jetcorrpt, jet.eta(), jet.phi(), weight);
342+
if (jetcorrpt > 0) {
343+
registry.fill(HIST("h_jet_eta_part_rhoareasubtracted"), jet.eta(), weight);
344+
registry.fill(HIST("h_jet_phi_part_rhoareasubtracted"), jet.phi(), weight);
345+
registry.fill(HIST("h2_jet_pt_part_jet_area_part_rhoareasubtracted"), jetcorrpt, jet.area(), weight);
346+
registry.fill(HIST("h2_jet_pt_part_jet_ntracks_part_rhoareasubtracted"), jetcorrpt, jet.tracksIds().size(), weight);
348347
}
349348
}
350349
}
@@ -516,19 +515,19 @@ struct JetSpectraCharged {
516515
aod::JetTracks const&)
517516
{
518517
if (!jetderiveddatautilities::selectCollision(collision, eventSelectionBits)) {
519-
return;
518+
return;
520519
}
521520
if (collision.trackOccupancyInTimeRange() < trackOccupancyInTimeRangeMin || trackOccupancyInTimeRangeMax < collision.trackOccupancyInTimeRange()) {
522-
return;
521+
return;
523522
}
524523
for (auto const& jet : jets) {
525-
if (!jetfindingutilities::isInEtaAcceptance(jet, jetEtaMin, jetEtaMax, trackEtaMin, trackEtaMax)) {
526-
continue;
527-
}
528-
if (!isAcceptedJet<aod::JetTracks>(jet)) {
529-
continue;
530-
}
531-
fillJetHistograms(jet, collision.centrality());
524+
if (!jetfindingutilities::isInEtaAcceptance(jet, jetEtaMin, jetEtaMax, trackEtaMin, trackEtaMax)) {
525+
continue;
526+
}
527+
if (!isAcceptedJet<aod::JetTracks>(jet)) {
528+
continue;
529+
}
530+
fillJetHistograms(jet, collision.centrality());
532531
}
533532
}
534533
PROCESS_SWITCH(JetSpectraCharged, processSpectraData, "jet spectra for Data", false);
@@ -538,19 +537,19 @@ struct JetSpectraCharged {
538537
aod::JetTracks const&)
539538
{
540539
if (!jetderiveddatautilities::selectCollision(collision, eventSelectionBits)) {
541-
return;
540+
return;
542541
}
543542
if (collision.trackOccupancyInTimeRange() < trackOccupancyInTimeRangeMin || trackOccupancyInTimeRangeMax < collision.trackOccupancyInTimeRange()) {
544-
return;
543+
return;
545544
}
546545
for (auto const& jet : jets) {
547-
if (!jetfindingutilities::isInEtaAcceptance(jet, jetEtaMin, jetEtaMax, trackEtaMin, trackEtaMax)) {
548-
continue;
549-
}
550-
if (!isAcceptedJet<aod::JetTracks>(jet)) {
551-
continue;
552-
}
553-
fillJetHistograms(jet, collision.centrality());
546+
if (!jetfindingutilities::isInEtaAcceptance(jet, jetEtaMin, jetEtaMax, trackEtaMin, trackEtaMax)) {
547+
continue;
548+
}
549+
if (!isAcceptedJet<aod::JetTracks>(jet)) {
550+
continue;
551+
}
552+
fillJetHistograms(jet, collision.centrality());
554553
}
555554
}
556555
PROCESS_SWITCH(JetSpectraCharged, processSpectraMCD, "jet spectra for MCD", false);
@@ -633,15 +632,15 @@ struct JetSpectraCharged {
633632
soa::Join<aod::ChargedMCParticleLevelJets, aod::ChargedMCParticleLevelJetConstituents> const& jets,
634633
aod::JetParticles const&)
635634
{
636-
registry.fill(HIST("h_mcColl_counts_areasub"), 0.5); //all mc collisions
635+
registry.fill(HIST("h_mcColl_counts_areasub"), 0.5); // all mc collisions
637636
if (std::abs(mccollision.posZ()) > vertexZCut) {
638637
return;
639638
}
640-
registry.fill(HIST("h_mcColl_counts_areasub"), 1.5); //cut on mccollision.posZ()
639+
registry.fill(HIST("h_mcColl_counts_areasub"), 1.5); // cut on mccollision.posZ()
641640
if (collisions.size() < 1) {
642641
return;
643642
}
644-
registry.fill(HIST("h_mcColl_counts_areasub"), 2.5); //mcCollisions with at least one resonstructed collision
643+
registry.fill(HIST("h_mcColl_counts_areasub"), 2.5); // mcCollisions with at least one resonstructed collision
645644
if (acceptSplitCollisions == 0 && collisions.size() > 1) {
646645
return;
647646
}
@@ -650,7 +649,7 @@ struct JetSpectraCharged {
650649
bool hasSel8Coll = false;
651650
bool centralityIsGood = false;
652651
bool occupancyIsGood = false;
653-
if (acceptSplitCollisions == 2) {
652+
if (acceptSplitCollisions == 2) {
654653
if (jetderiveddatautilities::selectCollision(collisions.begin(), eventSelectionBits)) { // Skipping MC events that have not a single selected reconstructed collision ; effect unclear if mcColl is split
655654
hasSel8Coll = true;
656655
}
@@ -660,8 +659,7 @@ struct JetSpectraCharged {
660659
if ((trackOccupancyInTimeRangeMin < collisions.begin().trackOccupancyInTimeRange()) && (collisions.begin().trackOccupancyInTimeRange() < trackOccupancyInTimeRangeMax)) {
661660
occupancyIsGood = true;
662661
}
663-
}
664-
else { // check that at least one of the reconstructed collisions passes the checks
662+
} else { // check that at least one of the reconstructed collisions passes the checks
665663
for (auto& collision : collisions) {
666664
if (jetderiveddatautilities::selectCollision(collision, eventSelectionBits)) { // Skipping MC events that have not a single selected reconstructed collision ; effect unclear if mcColl is split
667665
hasSel8Coll = true;
@@ -670,7 +668,7 @@ struct JetSpectraCharged {
670668
centralityIsGood = true;
671669
}
672670
if ((trackOccupancyInTimeRangeMin < collision.trackOccupancyInTimeRange()) && (collision.trackOccupancyInTimeRange() < trackOccupancyInTimeRangeMax)) {
673-
occupancyIsGood = true;
671+
occupancyIsGood = true;
674672
}
675673
}
676674
}
@@ -706,15 +704,15 @@ struct JetSpectraCharged {
706704
soa::Join<aod::ChargedMCParticleLevelJets, aod::ChargedMCParticleLevelJetConstituents> const& jets,
707705
aod::JetParticles const&)
708706
{
709-
registry.fill(HIST("h_mcColl_counts"), 0.5); //all mc collisions
707+
registry.fill(HIST("h_mcColl_counts"), 0.5); // all mc collisions
710708
if (std::abs(mccollision.posZ()) > vertexZCut) {
711709
return;
712710
}
713-
registry.fill(HIST("h_mcColl_counts"), 1.5); //cut on mccollision.posZ()
711+
registry.fill(HIST("h_mcColl_counts"), 1.5); // cut on mccollision.posZ()
714712
if (collisions.size() < 1) {
715713
return;
716714
}
717-
registry.fill(HIST("h_mcColl_counts"), 2.5); //mcCollisions with at least one resonstructed collision
715+
registry.fill(HIST("h_mcColl_counts"), 2.5); // mcCollisions with at least one resonstructed collision
718716

719717
bool hasSel8Coll = false;
720718
bool centralityIsGood = false;
@@ -745,32 +743,31 @@ struct JetSpectraCharged {
745743
registry.fill(HIST("h_mc_zvertex"), mccollision.posZ());
746744

747745
for (auto const& jet : jets) {
748-
if (!jetfindingutilities::isInEtaAcceptance(jet, jetEtaMin, jetEtaMax, trackEtaMin, trackEtaMax)) {
749-
continue;
750-
}
751-
if (!isAcceptedJet<aod::JetParticles>(jet)) {
752-
continue;
753-
}
754-
fillMCPHistograms(jet);
746+
if (!jetfindingutilities::isInEtaAcceptance(jet, jetEtaMin, jetEtaMax, trackEtaMin, trackEtaMax)) {
747+
continue;
748+
}
749+
if (!isAcceptedJet<aod::JetParticles>(jet)) {
750+
continue;
751+
}
752+
fillMCPHistograms(jet);
755753
}
756754
}
757755
PROCESS_SWITCH(JetSpectraCharged, processSpectraMCP, "jet spectra for MC particle level", false);
758756

759-
760757
void processSpectraMCPWeighted(aod::JetMcCollision const& mccollision,
761758
soa::SmallGroups<aod::JetCollisionsMCD> const& collisions,
762759
soa::Join<aod::ChargedMCParticleLevelJets, aod::ChargedMCParticleLevelJetConstituents, aod::ChargedMCParticleLevelJetEventWeights> const& jets,
763760
aod::JetParticles const&)
764-
{
765-
registry.fill(HIST("h_mcColl_counts"), 0.5); //all mc collisions
761+
{
762+
registry.fill(HIST("h_mcColl_counts"), 0.5); // all mc collisions
766763
if (std::abs(mccollision.posZ()) > vertexZCut) {
767764
return;
768765
}
769-
registry.fill(HIST("h_mcColl_counts"), 1.5); //cut on mccollision.posZ()
766+
registry.fill(HIST("h_mcColl_counts"), 1.5); // cut on mccollision.posZ()
770767
if (collisions.size() < 1) {
771768
return;
772769
}
773-
registry.fill(HIST("h_mcColl_counts"), 2.5); //mcCollisions with at least one resonstructed collision
770+
registry.fill(HIST("h_mcColl_counts"), 2.5); // mcCollisions with at least one resonstructed collision
774771

775772
bool hasSel8Coll = false;
776773
for (auto& collision : collisions) {

0 commit comments

Comments
 (0)