Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 11 additions & 13 deletions PWGJE/Tasks/jetCorrelationD0.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,6 @@
#include "Framework/HistogramRegistry.h"
#include "Framework/Logger.h"
#include "Framework/runDataProcessing.h"
#include <Framework/ASoA.h>
#include <Framework/HistogramSpec.h>

#include <fairlogger/Logger.h>

#include <string>
#include <vector>
Expand All @@ -57,8 +53,10 @@ DECLARE_SOA_TABLE(McCollisionTables, "AOD", "MCCOLLINFOTABLE",

namespace collisionInfo
{
DECLARE_SOA_INDEX_COLUMN(CollisionTable, collisionTable);
DECLARE_SOA_INDEX_COLUMN(McCollisionTable, mcCollisionTable);
// DECLARE_SOA_INDEX_COLUMN(CollisionTable, collisionTable);
DECLARE_SOA_INDEX_COLUMN_CUSTOM(CollisionTable, collisionTable, "COLLINFOTABLES");
// DECLARE_SOA_INDEX_COLUMN(McCollisionTable, mcCollisionTable);
DECLARE_SOA_INDEX_COLUMN_CUSTOM(McCollisionTable, mcCollisionTable, "MCCOLLINFOTABLES");
} // namespace collisionInfo
namespace d0Info
{
Expand Down Expand Up @@ -91,7 +89,7 @@ DECLARE_SOA_TABLE(D0DataTables, "AOD", "D0DATATABLE",
d0Info::D0Phi,
d0Info::D0Y);

DECLARE_SOA_TABLE(D0McPTables, "AOD", "D0MCPARTICLELEVELTABLE",
DECLARE_SOA_TABLE(D0McPTables, "AOD", "D0MCPTABLE",
o2::soa::Index<>,
collisionInfo::McCollisionTableId,
d0Info::D0McOrigin,
Expand All @@ -103,8 +101,8 @@ DECLARE_SOA_TABLE(D0McPTables, "AOD", "D0MCPARTICLELEVELTABLE",
namespace jetInfo
{
// D0 tables
DECLARE_SOA_INDEX_COLUMN(D0DataTable, d0Data);
DECLARE_SOA_INDEX_COLUMN(D0McPTable, d0MCP);
DECLARE_SOA_INDEX_COLUMN(D0DataTable, d0DataTable);
DECLARE_SOA_INDEX_COLUMN(D0McPTable, d0McPTable);
// Jet
DECLARE_SOA_COLUMN(JetPt, jetPt, float);
DECLARE_SOA_COLUMN(JetEta, jetEta, float);
Expand Down Expand Up @@ -202,7 +200,7 @@ struct JetCorrelationD0 {
{
for (const auto& jetBase : jetsBase) {
if (jetBase.has_matchedJetGeo()) { // geometric matching
for (auto& jetTag : jetBase.template matchedJetGeo_as<std::decay_t<U>>()) {
for (auto const& jetTag : jetBase.template matchedJetGeo_as<std::decay_t<U>>()) {
registry.fill(HIST("hPtMatched"), jetBase.pt() - (rho * jetBase.area()), jetTag.pt(), weight);
registry.fill(HIST("hPtMatched1d"), jetTag.pt(), weight);
registry.fill(HIST("hPhiMatched"), jetBase.phi(), jetTag.phi(), weight);
Expand Down Expand Up @@ -280,7 +278,7 @@ struct JetCorrelationD0 {
continue;
}
float dphi = RecoDecay::constrainAngle(jet.phi() - d0Candidate.phi());
if (abs(dphi - M_PI) > (M_PI / 2)) { // this is quite loose instead of pi/2 could do 0.6
if (std::abs(dphi - o2::constants::math::PI) > (o2::constants::math::PI / 2)) { // this is quite loose instead of pi/2 could do 0.6
continue;
}
fillJetHistograms(jet, dphi);
Expand Down Expand Up @@ -323,7 +321,7 @@ struct JetCorrelationD0 {
continue;
}
float dphi = RecoDecay::constrainAngle(jet.phi() - d0Candidate.phi());
if (abs(dphi - M_PI) > (M_PI / 2)) { // this is quite loose instead of pi/2 could do 0.6
if (std::abs(dphi - o2::constants::math::PI) > (o2::constants::math::PI / 2)) { // this is quite loose instead of pi/2 could do 0.6
continue;
}
fillJetHistograms(jet, dphi);
Expand Down Expand Up @@ -362,7 +360,7 @@ struct JetCorrelationD0 {
continue;
}
float dphi = RecoDecay::constrainAngle(jet.phi() - d0MCPCandidate.phi());
if (abs(dphi - M_PI) > (M_PI / 2)) {
if (std::abs(dphi - o2::constants::math::PI) > (o2::constants::math::PI / 2)) {
continue;
}
fillJetHistograms(jet, dphi);
Expand Down
Loading