Skip to content
Open
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
26 changes: 12 additions & 14 deletions PWGEM/PhotonMeson/Utils/NMHistograms.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@

#include "PWGEM/PhotonMeson/Utils/MCUtilities.h"

#include <CommonConstants/PhysicsConstants.h>
#include <CommonConstants/MathConstants.h>
#include <CommonConstants/PhysicsConstants.h>
#include <Framework/Concepts.h>
#include <Framework/HistogramRegistry.h>
#include <Framework/HistogramSpec.h>
Expand All @@ -33,13 +33,13 @@

namespace o2::aod::pwgem::photonmeson::utils::nmhistogram
{
using namespace o2::constants::math;

Check failure on line 36 in PWGEM/PhotonMeson/Utils/NMHistograms.h

View workflow job for this annotation

GitHub Actions / O2 linter

[using-directive]

Do not put using directives at global scope in headers.
inline void addNMHistograms(o2::framework::HistogramRegistry* fRegistry, bool isMC,
bool sparseFullAxes = false,
std::vector<double> const& occBins = {0, 500, 1000, 2000, 3000, 5000, 10000},
std::vector<double> const& epBins = {-PIHalf, -PIQuarter, 0, PIQuarter, PIHalf},
std::vector<double> const& vtxBins = {-10, -8, -6, -4, -2, 0, 2, 4, 6, 8, 10},
const char* pairname = "#gamma#gamma")
inline void addNMHistograms(o2::framework::HistogramRegistry* fRegistry, bool isMC,
bool sparseFullAxes = false,
std::vector<double> const& occBins = {0, 500, 1000, 2000, 3000, 5000, 10000},
std::vector<double> const& epBins = {-PIHalf, -PIQuarter, 0, PIQuarter, PIHalf},
std::vector<double> const& vtxBins = {-10, -8, -6, -4, -2, 0, 2, 4, 6, 8, 10},
const char* pairname = "#gamma#gamma")
{
// !!Don't change pt,eta,y binning. These binnings have to be consistent with binned data at skimming.!!
std::vector<double> ptbins;
Expand All @@ -59,7 +59,7 @@
const o2::framework::AxisSpec axis_pt{ptbins, Form("p_{T,%s} (GeV/c)", pairname)};
const o2::framework::AxisSpec axis_mass{400, 0, 0.8, Form("m_{%s} (GeV/c^{2})", pairname)};
const o2::framework::AxisSpec axis_occ{occBins, "occupancy"};
const o2::framework::AxisSpec axis_ep {epBins, "#Psi_{2} (rad)"};
const o2::framework::AxisSpec axis_ep{epBins, "#Psi_{2} (rad)"};
const o2::framework::AxisSpec axis_vtx{vtxBins, "Z_{vtx} (cm)"};

if (isMC) {
Expand All @@ -86,17 +86,15 @@
} else {
if (sparseFullAxes) {
fRegistry->add("Pair/same/hs", "diphoton",
o2::framework::HistType::kTHnSparseD,
{axis_mass, axis_pt, axis_ep, axis_occ, axis_vtx}, true);
o2::framework::HistType::kTHnSparseD,
{axis_mass, axis_pt, axis_ep, axis_occ, axis_vtx}, true);
} else {
fRegistry->add("Pair/same/hs", "diphoton",
o2::framework::HistType::kTHnSparseD,
{axis_mass, axis_pt}, true);
o2::framework::HistType::kTHnSparseD,
{axis_mass, axis_pt}, true);
}
fRegistry->addClone("Pair/same/", "Pair/mix/");
}


}

template <typename TDiphoton, o2::soa::is_iterator TMCParitlce, o2::soa::is_table TMCParticles, o2::soa::is_table TMCCollisions>
Expand Down
Loading