Skip to content

Commit 8331d11

Browse files
committed
Removed unused headers in chargedJetHadron task
1 parent a77c36a commit 8331d11

File tree

1 file changed

+39
-45
lines changed

1 file changed

+39
-45
lines changed

PWGJE/Tasks/chargedJetHadron.cxx

Lines changed: 39 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -13,37 +13,24 @@
1313
/// \brief Charged-particle jet - hadron correlation task
1414
/// \author Yongzhen Hou <yongzhen.hou@cern.ch>
1515

16-
#include "PWGHF/DataModel/CandidateReconstructionTables.h"
17-
#include "PWGHF/DataModel/CandidateSelectionTables.h"
1816
#include "PWGJE/Core/JetDerivedDataUtilities.h"
1917
#include "PWGJE/Core/JetFindingUtilities.h"
20-
#include "PWGJE/Core/JetHFUtilities.h"
2118
#include "PWGJE/DataModel/Jet.h"
2219
#include "PWGJE/DataModel/JetReducedData.h"
2320
#include "PWGJE/DataModel/JetSubtraction.h"
2421

25-
#include "Common/CCDB/EventSelectionParams.h"
2622
#include "Common/Core/RecoDecay.h"
27-
#include "Common/DataModel/Centrality.h"
28-
#include "Common/DataModel/EventSelection.h"
29-
#include "Common/DataModel/Multiplicity.h"
30-
#include "Common/DataModel/TrackSelectionTables.h"
3123

3224
#include "Framework/ASoA.h"
3325
#include "Framework/AnalysisTask.h"
3426
#include "Framework/HistogramRegistry.h"
3527
#include <CommonConstants/MathConstants.h>
36-
#include <CommonConstants/PhysicsConstants.h>
37-
#include <Framework/ASoAHelpers.h>
3828
#include <Framework/AnalysisDataModel.h>
39-
#include <Framework/AnalysisHelpers.h>
4029
#include <Framework/BinningPolicy.h>
4130
#include <Framework/Configurable.h>
4231
#include <Framework/GroupedCombinations.h>
4332
#include <Framework/HistogramSpec.h>
4433
#include <Framework/InitContext.h>
45-
#include <Framework/O2DatabasePDGPlugin.h>
46-
#include <Framework/OutputObjHeader.h> //refer-hfFF
4734
#include <Framework/runDataProcessing.h>
4835

4936
#include <THn.h>
@@ -58,6 +45,7 @@ using namespace o2::framework;
5845
using namespace o2::framework::expressions;
5946
using namespace o2::soa;
6047
const double absPiCut = 1.5;
48+
const double assoHadronPtCut = 2.0;
6149

6250
struct ChargedJetHadron {
6351

@@ -68,6 +56,9 @@ struct ChargedJetHadron {
6856
Configurable<float> centralityMax{"centralityMax", 100.0, "maximum centrality"};
6957
Configurable<float> leadingjetptMin{"leadingjetptMin", 20.0, "minimum leadingjetpt"};
7058
Configurable<float> subleadingjetptMin{"subleadingjetptMin", 10.0, "minimum subleadingjetpt"};
59+
Configurable<float> assoHadronPtMaxCut{"assoHadronPtMaxCut", 10.0, "maximum associate hadron pt cut"};
60+
Configurable<float> etaGapdw{"etaGapdw", 0.5, "dijet eta gap low threshold"};
61+
Configurable<float> etaGapup{"etaGapup", 1.0, "dijet eta gap high threshold"};
7162
Configurable<float> trackEtaMin{"trackEtaMin", -0.9, "minimum eta acceptance for tracks"};
7263
Configurable<float> trackEtaMax{"trackEtaMax", 0.9, "maximum eta acceptance for tracks"};
7364
Configurable<float> trackPtMin{"trackPtMin", 0.15, "minimum pT acceptance for tracks"};
@@ -146,7 +137,6 @@ struct ChargedJetHadron {
146137

147138
void init(o2::framework::InitContext&)
148139
{
149-
150140
eventSelectionBits = jetderiveddatautilities::initialiseEventSelectionBits(static_cast<std::string>(eventSelections));
151141
trackSelection = jetderiveddatautilities::initialiseTrackSelection(static_cast<std::string>(trackSelections));
152142

@@ -202,7 +192,7 @@ struct ChargedJetHadron {
202192
registry.add("h_jet_eta_rhoareasubtracted", "jet eta; #eta_{jet}; counts", {HistType::kTH1F, {etaAxis}});
203193
registry.add("h_jet_phi_rhoareasubtracted", "jet phi; #phi_{jet}; counts", {HistType::kTH1F, {phiAxis}});
204194
registry.add("h_jet_area_rhoareasubtracted", "jet Area_{jet}; Area_{jet}; counts", {HistType::kTH1F, {{150, 0., 1.5}}});
205-
registry.add("h_jet_ntracks_rhoareasubtracted", "jet N_{jet tracks}; N_{jet, tracks; counts}", {HistType::kTH1F, {{200, 0., 200.}}});
195+
registry.add("h_jet_ntracks_rhoareasubtracted", "jet N_{jet tracks}; N_{jet,tracks}; counts", {HistType::kTH1F, {{200, 0., 200.}}});
206196
}
207197

208198
//========jet-hadron correlations======================
@@ -291,7 +281,9 @@ struct ChargedJetHadron {
291281
registry.add("h_mixjeth_dphi", "ME: jet-hadron correlations; #Delta#phi", {HistType::kTH1F, {dphiAxis}});
292282
registry.add("h2_mixjeth_detatot_dphi", "ME: jet-hadron correlations; no flip #Delta#eta; #Delta#phi", {HistType::kTH2F, {detaAxis, dphiAxis}});
293283
registry.add("h2_mixjeth_deta_dphi", "ME: jet-hadron correlations; #Delta#eta; #Delta#phi", {HistType::kTH2F, {detaAxis, dphiAxis}});
294-
registry.add("h2_mixjeth_physicalcutsHup_deta_dphi", "ME: jeth deta vs dphi with physical cuts |#Delta#eta_{jet1,2}| > 1.0,#Delta#eta_{jet1}>#Delta#eta_{jet2}; #Delta#eta; #Delta#phi", {HistType::kTH2F, {detaAxis, dphiAxis}});
284+
registry.add("h2_mixjeth_physicalcutsup_deta_dphi", "ME: jeth deta vs dphi with physical cuts |#Delta#eta_{jet1,2}| > 1.0; #Delta#eta; #Delta#phi", {HistType::kTH2F, {detaAxis, dphiAxis}});
285+
registry.add("h2_mixjeth_physicalcutsmd_deta_dphi", "ME: jeth deta vs dphi with physical cuts |#Delta#eta_{jet1,2}| #in (0.5, 1.0); #Delta#eta; #Delta#phi", {HistType::kTH2F, {detaAxis, dphiAxis}});
286+
registry.add("h2_mixjeth_physicalcutsdw_deta_dphi", "ME: jeth deta vs dphi with physical cuts |#Delta#eta_{jet1,2}| < 0.5; #Delta#eta; #Delta#phi", {HistType::kTH2F, {detaAxis, dphiAxis}});
295287
registry.add("h2_mixjeth_physicalcutsHdw_deta_dphi", "ME: jeth deta vs dphi with physical cuts |#Delta#eta_{jet1,2}| < 0.5 #Delta#eta_{jet1}> #Delta#eta_{jet2}; #Delta#eta; #Delta#phi", {HistType::kTH2F, {detaAxis, dphiAxis}});
296288
registry.add("thn_mixljeth_correlations", "ME: jet-h correlations; leadingJetpT; subleadingJetpT; trackpT; timedijeteta; track #eta; #Delta#eta_{jet1,2}; jeth#Delta#eta; jeth#Delta#phi; poolBin",
297289
HistType::kTHnSparseF, {jetPtAxisRhoAreaSub, jetPtAxisRhoAreaSub, trackPtAxis, jetmultetaAxis, etaAxis, detaAxis, detaAxis, dphiAxis, {10, 0, 10}});
@@ -404,7 +396,6 @@ struct ChargedJetHadron {
404396
registry.add("h2_jeth_physicalcutsup_deta_dphi_part", "MCP: jeth deta vs dphi with physical cuts |#Delta#eta_{jet}| > 1.0; #Delta#eta; #Delta#phi", {HistType::kTH2F, {detaAxis, dphiAxis}});
405397
registry.add("h2_jeth_physicalcutsmd_deta_dphi_part", "MCP: jeth deta vs dphi with physical cuts |#Delta#eta_{jet1,2}| #in (0.5, 1.0); #Delta#eta; #Delta#phi", {HistType::kTH2F, {detaAxis, dphiAxis}});
406398
registry.add("h2_jeth_physicalcutsdw_deta_dphi_part", "MCP: jeth deta vs dphi with physical cuts |#Delta#eta_{jet1,2}| < 0.5; #Delta#eta; #Delta#phi", {HistType::kTH2F, {detaAxis, dphiAxis}});
407-
registry.add("h2_jeth_physicalcutsHup_deta_dphi_part", "MCP: jeth deta vs dphi with physical cuts |#Delta#eta_{jet1,2}| > 1.0,#Delta#eta_{jet1}>#Delta#eta_{jet2}; #Delta#eta; #Delta#phi", {HistType::kTH2F, {detaAxis, dphiAxis}});
408399
registry.add("h2_jeth_physicalcutsHdw_deta_dphi_part", "MCP: jeth deta vs dphi with physical cuts |#Delta#eta_{jet1,2}| < 0.5 #Delta#eta_{jet1}>#Delta#eta_{jet2}; #Delta#eta; #Delta#phi", {HistType::kTH2F, {detaAxis, dphiAxis}});
409400
registry.add("thn_ljeth_correlations_part", "MCP: leading jet-h correlations; leadingjetpT; subleadingjetpT; trackpT; timedijeteta; track #eta; #Delta#eta_{jet1,2}; jeth#Delta#eta; jeth#Delta#varphi", HistType::kTHnSparseF, {jetPtAxisRhoAreaSub, jetPtAxisRhoAreaSub, trackPtAxis, jetmultetaAxis, etaAxis, detaAxis, detaAxis, dphiAxis});
410401

@@ -425,6 +416,10 @@ struct ChargedJetHadron {
425416
registry.add("h_mixjeth_dphi_part", "mcpME: jet-hadron correlations; #Delta#phi", {HistType::kTH1F, {dphiAxis}});
426417
registry.add("h2_mixjeth_detatot_dphi_part", "mcpME: jet-hadron correlations; no flip #Delta#eta; #Delta#phi", {HistType::kTH2F, {detaAxis, dphiAxis}});
427418
registry.add("h2_mixjeth_deta_dphi_part", "mcpME: jet-hadron correlations; #Delta#eta; #Delta#phi", {HistType::kTH2F, {detaAxis, dphiAxis}});
419+
registry.add("h2_mixjeth_physicalcutsup_deta_dphi_part", "mcpME: jeth deta vs dphi with physical cuts |#Delta#eta_{jet}| > 1.0; #Delta#eta; #Delta#phi", {HistType::kTH2F, {detaAxis, dphiAxis}});
420+
registry.add("h2_mixjeth_physicalcutsmd_deta_dphi_part", "mcpME: jeth deta vs dphi with physical cuts |#Delta#eta_{jet1,2}| #in (0.5, 1.0); #Delta#eta; #Delta#phi", {HistType::kTH2F, {detaAxis, dphiAxis}});
421+
registry.add("h2_mixjeth_physicalcutsdw_deta_dphi_part", "mcpME: jeth deta vs dphi with physical cuts |#Delta#eta_{jet1,2}| < 0.5; #Delta#eta; #Delta#phi", {HistType::kTH2F, {detaAxis, dphiAxis}});
422+
registry.add("h2_mixjeth_physicalcutsHdw_deta_dphi_part", "mcpME: jeth deta vs dphi with physical cuts |#Delta#eta_{jet1,2}| < 0.5 #Delta#eta_{jet1}>#Delta#eta_{jet2}; #Delta#eta; #Delta#phi", {HistType::kTH2F, {detaAxis, dphiAxis}});
428423
registry.add("thn_mixljeth_correlations_part", "mcpME: leading jet-h correlations; leadingJetpT; subleadingJetpT; trackpT; timedijeteta; track #eta; #Delta#eta_{jet1,2}; jeth#Delta#eta; jeth#Delta#phi; poolBin",
429424
HistType::kTHnSparseF, {jetPtAxisRhoAreaSub, jetPtAxisRhoAreaSub, trackPtAxis, jetmultetaAxis, etaAxis, detaAxis, detaAxis, dphiAxis, {10, 0, 10}});
430425

@@ -782,10 +777,6 @@ struct ChargedJetHadron {
782777
{
783778
registry.fill(HIST("h_centrality"), getCentrality(collision));
784779

785-
const double trackJethCut = 2.0;
786-
const double trackJethMaxCut = 10.0;
787-
const double etaGapdw = 0.5;
788-
const double etaGapup = 1.0;
789780
using JetType = std::decay_t<decltype(*jets.begin())>;
790781
std::optional<JetType> leadingJet;
791782
std::optional<JetType> subleadingJet;
@@ -866,15 +857,15 @@ struct ChargedJetHadron {
866857
double dphi = track.phi() - leadingJet->phi();
867858
dphi = RecoDecay::constrainAngle(dphi, -o2::constants::math::PIHalf);
868859

869-
if (hpt > trackJethMaxCut)
860+
if (hpt > assoHadronPtMaxCut)
870861
continue;
871862
registry.fill(HIST("h_jeth_detatot"), detatot, eventWeight);
872863
registry.fill(HIST("h_jeth_deta"), deta, eventWeight);
873864
registry.fill(HIST("h_jeth_dphi"), dphi, eventWeight);
874865
registry.fill(HIST("h2_jeth_detatot_dphi"), detatot, dphi, eventWeight);
875-
registry.fill(HIST("h2_jeth_deta_dphi"), deta, dphi, eventWeight);
876866
registry.fill(HIST("thn_ljeth_correlations"), ptLeadingCorr, ptSubleadingCorr, hpt, multEta1Eta2, heta, deltaEtaJets, deta, dphi, eventWeight);
877-
if (hpt < trackJethCut) {
867+
if (hpt < assoHadronPtCut) {
868+
registry.fill(HIST("h2_jeth_deta_dphi"), deta, dphi, eventWeight);
878869
if (std::abs(deltaEtaJets) >= etaGapup)
879870
registry.fill(HIST("h2_jeth_physicalcutsup_deta_dphi"), deta, dphi, eventWeight);
880871
if (std::abs(deltaEtaJets) >= etaGapdw && std::abs(deltaEtaJets) < etaGapup)
@@ -899,10 +890,6 @@ struct ChargedJetHadron {
899890
int totaldijetscut = 0;
900891
int totalPairs = 0;
901892
int passedPairs = 0;
902-
const double trackJethCut = 2.0;
903-
const double trackJethMaxCut = 10.0;
904-
const double etaGapdw = 0.5;
905-
const double etaGapup = 1.0;
906893

907894
auto tracksTuple = std::make_tuple(jets, tracks);
908895
Pair<TCollisions, TJets, TTracks, BinningType> pairData{corrBinning, numberEventsMixed, -1, collisions, tracksTuple, &cache};
@@ -999,17 +986,21 @@ struct ChargedJetHadron {
999986
double dphi = track.phi() - leadingJet->phi();
1000987
dphi = RecoDecay::constrainAngle(dphi, -o2::constants::math::PIHalf);
1001988

1002-
if (hpt > trackJethMaxCut)
989+
if (hpt > assoHadronPtMaxCut)
1003990
continue;
1004991
registry.fill(HIST("h_mixjeth_detatot"), detatot, eventWeight);
1005992
registry.fill(HIST("h_mixjeth_deta"), deta, eventWeight);
1006993
registry.fill(HIST("h_mixjeth_dphi"), dphi, eventWeight);
1007994
registry.fill(HIST("h2_mixjeth_detatot_dphi"), detatot, dphi, eventWeight);
1008-
registry.fill(HIST("h2_mixjeth_deta_dphi"), deta, dphi, eventWeight);
1009995
registry.fill(HIST("thn_mixjethadron"), ptLeadingCorr, ptSubleadingCorr, hpt, multEta1Eta2, heta, deltaEtaJets, deta, dphi, poolBin, eventWeight);
1010-
if (hpt < trackJethCut) {
1011-
if (etaJet1Raw > etaJet2Raw && std::abs(deltaEtaJets) >= etaGapup)
1012-
registry.fill(HIST("h2_mixjeth_physicalcutsHup_deta_dphi"), detatot, dphi, eventWeight); // Dr.Yang
996+
if (hpt < assoHadronPtCut) {
997+
registry.fill(HIST("h2_mixjeth_deta_dphi"), deta, dphi, eventWeight);
998+
if (std::abs(deltaEtaJets) >= etaGapup)
999+
registry.fill(HIST("h2_mixjeth_physicalcutsup_deta_dphi"), deta, dphi, eventWeight);
1000+
if (std::abs(deltaEtaJets) >= etaGapdw && std::abs(deltaEtaJets) < etaGapup)
1001+
registry.fill(HIST("h2_mixjeth_physicalcutsmd_deta_dphi"), deta, dphi, eventWeight);
1002+
if (std::abs(deltaEtaJets) < etaGapdw)
1003+
registry.fill(HIST("h2_mixjeth_physicalcutsdw_deta_dphi"), deta, dphi, eventWeight);
10131004
if (etaJet1Raw > etaJet2Raw && std::abs(deltaEtaJets) < etaGapdw)
10141005
registry.fill(HIST("h2_mixjeth_physicalcutsHdw_deta_dphi"), detatot, dphi, eventWeight); // Dr.Yang
10151006
}
@@ -1028,10 +1019,6 @@ struct ChargedJetHadron {
10281019
template <typename TmcCollision, typename TJets, typename TParticles>
10291020
void fillMCPLeadingJetHadronHistograms(const TmcCollision& mccollision, const TJets& jets, const TParticles& particles, float eventWeight = 1.0)
10301021
{
1031-
const double particleJethCut = 2.0;
1032-
const double particleJethMaxCut = 10.0;
1033-
const double etaGapdw = 0.5;
1034-
const double etaGapup = 1.0;
10351022
using JetType = std::decay_t<decltype(*jets.begin())>;
10361023
std::optional<JetType> leadingJet;
10371024
std::optional<JetType> subleadingJet;
@@ -1105,24 +1092,22 @@ struct ChargedJetHadron {
11051092
double dphi = particle.phi() - leadingJet->phi();
11061093

11071094
dphi = RecoDecay::constrainAngle(dphi, -o2::constants::math::PIHalf);
1108-
if (hpt > particleJethMaxCut)
1095+
if (hpt > assoHadronPtMaxCut)
11091096
continue;
11101097

11111098
registry.fill(HIST("h_jeth_detatot_part"), detatot, eventWeight);
11121099
registry.fill(HIST("h_jeth_deta_part"), deta, eventWeight);
11131100
registry.fill(HIST("h_jeth_dphi_part"), dphi, eventWeight);
11141101
registry.fill(HIST("h2_jeth_detatot_dphi_part"), detatot, dphi, eventWeight);
1115-
registry.fill(HIST("h2_jeth_deta_dphi_part"), deta, dphi, eventWeight);
11161102
registry.fill(HIST("thn_ljeth_correlations_part"), ptLeadingCorr, ptSubleadingCorr, hpt, multEta1Eta2, heta, deltaEtaJets, deta, dphi, eventWeight);
1117-
if (hpt < particleJethCut) {
1103+
if (hpt < assoHadronPtCut) {
1104+
registry.fill(HIST("h2_jeth_deta_dphi_part"), deta, dphi, eventWeight);
11181105
if (std::abs(deltaEtaJets) >= etaGapup)
11191106
registry.fill(HIST("h2_jeth_physicalcutsup_deta_dphi_part"), deta, dphi, eventWeight);
11201107
if (std::abs(deltaEtaJets) >= etaGapdw && std::abs(deltaEtaJets) < etaGapup)
11211108
registry.fill(HIST("h2_jeth_physicalcutsmd_deta_dphi_part"), deta, dphi, eventWeight);
11221109
if (std::abs(deltaEtaJets) < etaGapdw)
11231110
registry.fill(HIST("h2_jeth_physicalcutsdw_deta_dphi_part"), deta, dphi, eventWeight);
1124-
if (std::abs(deltaEtaJets) >= etaGapup && etaJet1Raw > etaJet2Raw)
1125-
registry.fill(HIST("h2_jeth_physicalcutsHup_deta_dphi_part"), detatot, dphi, eventWeight);
11261111
if (std::abs(deltaEtaJets) < etaGapdw && etaJet1Raw > etaJet2Raw)
11271112
registry.fill(HIST("h2_jeth_physicalcutsHdw_deta_dphi_part"), detatot, dphi, eventWeight);
11281113
}
@@ -1136,7 +1121,6 @@ struct ChargedJetHadron {
11361121
{
11371122
auto particlesTuple = std::make_tuple(jets, particles);
11381123
Pair<TmcCollisions, TJets, TParticles, BinningTypeMC> pairMCData{corrBinningMC, numberEventsMixed, -1, mcCollisions, particlesTuple, &cache};
1139-
const double particleJethMaxCut = 10.0;
11401124

11411125
for (const auto& [c1, jets1, c2, particles2] : pairMCData) {
11421126
registry.fill(HIST("h_mixevent_stats_part"), 1);
@@ -1216,16 +1200,26 @@ struct ChargedJetHadron {
12161200
double deta = flip * (particle.eta() - etaJet1Raw);
12171201
double dphi = particle.phi() - leadingJet->phi();
12181202
dphi = RecoDecay::constrainAngle(dphi, -o2::constants::math::PIHalf);
1219-
if (hpt > particleJethMaxCut)
1203+
if (hpt > assoHadronPtMaxCut)
12201204
continue;
12211205

12221206
registry.fill(HIST("h_mixevent_stats_part"), 5);
12231207
registry.fill(HIST("h_mixjeth_detatot_part"), detatot, eventWeight);
12241208
registry.fill(HIST("h_mixjeth_deta_part"), deta, eventWeight);
12251209
registry.fill(HIST("h_mixjeth_dphi_part"), dphi, eventWeight);
12261210
registry.fill(HIST("h2_mixjeth_detatot_dphi_part"), detatot, dphi, eventWeight);
1227-
registry.fill(HIST("h2_mixjeth_deta_dphi_part"), deta, dphi, eventWeight);
12281211
registry.fill(HIST("thn_mixljeth_correlations_part"), ptLeadingCorr, ptSubleadingCorr, hpt, multEta1Eta2, heta, deltaEtaJets, deta, dphi, poolBin, eventWeight);
1212+
if (hpt < assoHadronPtCut) {
1213+
registry.fill(HIST("h2_mixjeth_deta_dphi_part"), deta, dphi, eventWeight);
1214+
if (std::abs(deltaEtaJets) >= etaGapup)
1215+
registry.fill(HIST("h2_mixjeth_physicalcutsup_deta_dphi_part"), deta, dphi, eventWeight);
1216+
if (std::abs(deltaEtaJets) >= etaGapdw && std::abs(deltaEtaJets) < etaGapup)
1217+
registry.fill(HIST("h2_mixjeth_physicalcutsmd_deta_dphi_part"), deta, dphi, eventWeight);
1218+
if (std::abs(deltaEtaJets) < etaGapdw)
1219+
registry.fill(HIST("h2_mixjeth_physicalcutsdw_deta_dphi_part"), deta, dphi, eventWeight);
1220+
if (std::abs(deltaEtaJets) < etaGapdw && etaJet1Raw > etaJet2Raw)
1221+
registry.fill(HIST("h2_mixjeth_physicalcutsHdw_deta_dphi_part"), detatot, dphi, eventWeight);
1222+
}
12291223
}
12301224
}
12311225
}

0 commit comments

Comments
 (0)