Skip to content
Merged
Show file tree
Hide file tree
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
4 changes: 3 additions & 1 deletion PWGLF/DataModel/ReducedDoublePhiTables.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ namespace redphievent
{
DECLARE_SOA_COLUMN(NumPos, numPos, int); //! Number of positive Kaon
DECLARE_SOA_COLUMN(NumNeg, numNeg, int); //! Number of negative Kaon
DECLARE_SOA_COLUMN(Centrality, centrality, float); //! Number of negative Kaon
} // namespace redphievent
DECLARE_SOA_TABLE(RedPhiEvents, "AOD", "REDPHIEVENT",
o2::soa::Index<>,
Expand All @@ -36,7 +37,8 @@ DECLARE_SOA_TABLE(RedPhiEvents, "AOD", "REDPHIEVENT",
collision::PosZ,
collision::NumContrib,
redphievent::NumPos,
redphievent::NumNeg);
redphievent::NumNeg,
redphievent::Centrality);
using RedPhiEvent = RedPhiEvents::iterator;

namespace phitrack
Expand Down
7 changes: 4 additions & 3 deletions PWGLF/TableProducer/Resonances/doublephitable.cxx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright 2019-2020 CERN and copyright holders of ALICE O2.

Check failure on line 1 in PWGLF/TableProducer/Resonances/doublephitable.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/workflow-file]

Name of a workflow file must match the name of the main struct in it (without the PWG prefix). (Class implementation files should be in "Core" directories.)
// See https://alice-o2.web.cern.ch/copyright for details of the copyright holders.
// All rights not expressly granted are reserved.
//
Expand All @@ -17,6 +17,7 @@
#include "PWGLF/DataModel/ReducedDoublePhiTables.h"

#include "Common/CCDB/EventSelectionParams.h"
#include "Common/DataModel/Centrality.h"
#include "Common/DataModel/EventSelection.h"
#include "Common/DataModel/Multiplicity.h"
#include "Common/DataModel/PIDResponseITS.h"
Expand Down Expand Up @@ -66,7 +67,7 @@
Configurable<float> cfgCutEta{"cfgCutEta", 0.8, "Eta cut on daughter track"};
Configurable<float> cfgCutDCAxy{"cfgCutDCAxy", 2.0f, "DCAxy range for tracks"};
Configurable<float> cfgCutDCAz{"cfgCutDCAz", 2.0f, "DCAz range for tracks"};
Configurable<float> nsigmaCutTPC{"nsigmacutTPC", 3.0, "Value of the TPC Nsigma cut"};

Check failure on line 70 in PWGLF/TableProducer/Resonances/doublephitable.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[name/configurable]

Use lowerCamelCase for names of configurables and use the same name for the struct member as for the JSON string. (Declare the type and names on the same line.)
Configurable<float> nsigmaCutTOF{"nsigmaCutTOF", 3.0, "Value of the TOF Nsigma cut"};
Configurable<int> cfgITScluster{"cfgITScluster", 0, "Number of ITS cluster"};
Configurable<int> cfgTPCcluster{"cfgTPCcluster", 70, "Number of TPC cluster"};
Expand All @@ -83,7 +84,7 @@
Filter DCAcutFilter = (nabs(aod::track::dcaXY) < cfgCutDCAxy) && (nabs(aod::track::dcaZ) < cfgCutDCAz);
Filter PIDcutFilter = nabs(aod::pidtpc::tpcNSigmaKa) < nsigmaCutTPC;

using EventCandidates = soa::Filtered<soa::Join<aod::Collisions, aod::EvSels, aod::Mults>>;
using EventCandidates = soa::Filtered<soa::Join<aod::Collisions, aod::EvSels, aod::Mults, aod::CentFT0Ms>>;
using TrackCandidates = soa::Filtered<soa::Join<aod::Tracks, aod::TracksExtra, aod::TracksDCA, aod::TrackSelection, aod::pidTOFbeta, aod::pidTPCFullKa, aod::pidTOFFullKa>>;

SliceCache cache;
Expand Down Expand Up @@ -165,11 +166,11 @@

int Npostrack = 0;
int Nnegtrack = 0;

float centrality = collision.centFT0M();
if (collision.sel8() && collision.selection_bit(aod::evsel::kNoTimeFrameBorder) && collision.selection_bit(aod::evsel::kNoITSROFrameBorder) && collision.selection_bit(aod::evsel::kNoSameBunchPileup) && collision.selection_bit(aod::evsel::kIsGoodZvtxFT0vsPV)) {
auto posThisColl = posTracks->sliceByCached(aod::track::collisionId, collision.globalIndex(), cache);
auto negThisColl = negTracks->sliceByCached(aod::track::collisionId, collision.globalIndex(), cache);
for (auto track1 : posThisColl) {

Check failure on line 173 in PWGLF/TableProducer/Resonances/doublephitable.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[const-ref-in-for-loop]

Use constant references for non-modified iterators in range-based for loops.
// track selection
if (!selectionTrack(track1)) {
continue;
Expand All @@ -178,7 +179,7 @@
if (!selectionPID(track1)) {
continue;
}
if (!(itsResponse.nSigmaITS<o2::track::PID::Kaon>(track1) > -3.0 && itsResponse.nSigmaITS<o2::track::PID::Kaon>(track1) < 3.0)) {

Check failure on line 182 in PWGLF/TableProducer/Resonances/doublephitable.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[magic-number]

Avoid magic numbers in expressions. Assign the value to a clearly named variable or constant.
continue;
}
Npostrack = Npostrack + 1;
Expand All @@ -187,7 +188,7 @@
qaRegistry.fill(HIST("hNsigmaPtkaonTOF"), track1.tofNSigmaKa(), track1.pt());
}
auto track1ID = track1.globalIndex();
for (auto track2 : negThisColl) {

Check failure on line 191 in PWGLF/TableProducer/Resonances/doublephitable.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[const-ref-in-for-loop]

Use constant references for non-modified iterators in range-based for loops.
// track selection
if (!selectionTrack(track2)) {
continue;
Expand All @@ -203,7 +204,7 @@
if (track2ID == track1ID) {
continue;
}
if (!(itsResponse.nSigmaITS<o2::track::PID::Kaon>(track2) > -3.0 && itsResponse.nSigmaITS<o2::track::PID::Kaon>(track2) < 3.0)) {

Check failure on line 207 in PWGLF/TableProducer/Resonances/doublephitable.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[magic-number]

Avoid magic numbers in expressions. Assign the value to a clearly named variable or constant.
continue;
}
if (!selectionPair(track1, track2)) {
Expand Down Expand Up @@ -258,7 +259,7 @@
if (keepEventDoublePhi && numberPhi > 1 && Npostrack > 1 && Nnegtrack > 1 && (phiresonance.size() == phiresonanced1.size()) && (phiresonance.size() == phiresonanced2.size())) {
qaRegistry.fill(HIST("hEventstat"), 1.5);
/////////// Fill collision table///////////////
redPhiEvents(bc.globalBC(), currentRunNumber, bc.timestamp(), collision.posZ(), collision.numContrib(), Npostrack, Nnegtrack);
redPhiEvents(bc.globalBC(), currentRunNumber, bc.timestamp(), collision.posZ(), collision.numContrib(), Npostrack, Nnegtrack, centrality);
auto indexEvent = redPhiEvents.lastIndex();
//// Fill track table for Phi//////////////////
for (auto if1 = phiresonance.begin(); if1 != phiresonance.end(); ++if1) {
Expand Down
2 changes: 2 additions & 0 deletions PWGLF/Tasks/Resonances/doublephimeson.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
#include <Math/Vector3Dfwd.h>
#include <Math/Vector4D.h> // IWYU pragma: keep (do not replace with Math/Vector4Dfwd.h)
#include <Math/Vector4Dfwd.h>
#include <TLorentzVector.h>

Check failure on line 34 in PWGLF/Tasks/Resonances/doublephimeson.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[root/lorentz-vector]

Do not use the TLorentzVector legacy class. Use std::array with RecoDecay methods or the ROOT::Math::LorentzVector template instead.
#include <TMath.h>
#include <TMathBase.h>
#include <TVector2.h>
Expand Down Expand Up @@ -181,6 +181,7 @@
histos.add("hDeltaRkaonplus", "hDeltaRkaonplus", kTH1F, {{800, 0.0, 8.0}});
histos.add("hDeltaRkaonminus", "hDeltaRkaonminus", kTH1F, {{800, 0.0, 8.0}});
histos.add("hPtCorrelation", "hPtCorrelation", kTH2F, {{400, 0.0, 40.0}, {5000, 0.0, 100.0}});
histos.add("hPtCent", "hPtCent", kTH2F, {{100, 0.0, 100.0}, {100, 0.0, 100.0}});
const AxisSpec thnAxisdeltapt{configThnAxisDeltaPt, "Delta pt"};
const AxisSpec thnAxisdaughterpt{configThnAxisDaughterPt, "Daughter pt"};
const AxisSpec thnAxisInvMass{configThnAxisInvMass, "#it{M} (GeV/#it{c}^{2})"};
Expand Down Expand Up @@ -226,9 +227,9 @@
}

// get kstar
TLorentzVector trackSum, PartOneCMS, PartTwoCMS, trackRelK;

Check failure on line 230 in PWGLF/Tasks/Resonances/doublephimeson.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[root/lorentz-vector]

Do not use the TLorentzVector legacy class. Use std::array with RecoDecay methods or the ROOT::Math::LorentzVector template instead.
float getkstar(const TLorentzVector part1,

Check failure on line 231 in PWGLF/Tasks/Resonances/doublephimeson.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[root/lorentz-vector]

Do not use the TLorentzVector legacy class. Use std::array with RecoDecay methods or the ROOT::Math::LorentzVector template instead.
const TLorentzVector part2)

Check failure on line 232 in PWGLF/Tasks/Resonances/doublephimeson.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[root/lorentz-vector]

Do not use the TLorentzVector legacy class. Use std::array with RecoDecay methods or the ROOT::Math::LorentzVector template instead.
{
// const TLorentzVector trackSum = part1 + part2;
trackSum = part1 + part2;
Expand Down Expand Up @@ -1780,6 +1781,7 @@
}
if (pairPt > minExoticPt) {
histos.fill(HIST("hPtCorrelation"), pairPt, ptcorr);
histos.fill(HIST("hPtCent"), pairPt, collision.centrality());
histos.fill(HIST("SEMassUnlike_AllVars"),
M,
pairPt,
Expand Down
Loading