Skip to content

Commit 0648cf8

Browse files
authored
Merge branch 'AliceO2Group:master' into master
2 parents 49fe700 + 408545e commit 0648cf8

File tree

435 files changed

+41388
-18354
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

435 files changed

+41388
-18354
lines changed

ALICE3/Core/FastTracker.cxx

Lines changed: 29 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,6 +144,34 @@ void FastTracker::AddSiliconALICE3v2(std::vector<float> pixelResolution)
144144
AddLayer("B10", 80., 250, x0OT, xrhoOT, resRPhiOT, resZOT, eff, 1);
145145
}
146146

147+
void FastTracker::AddSiliconALICE3(std::vector<float> pixelResolution)
148+
{
149+
float x0IT = 0.001; // 0.1%
150+
float x0OT = 0.01; // 1.0%
151+
float xrhoIB = 2.3292e-02; // 100 mum Si
152+
float xrhoOT = 2.3292e-01; // 1000 mum Si
153+
float eff = 1.00;
154+
155+
float resRPhiIT = pixelResolution[0];
156+
float resZIT = pixelResolution[1];
157+
float resRPhiOT = pixelResolution[2];
158+
float resZOT = pixelResolution[3];
159+
160+
AddLayer("bpipe0", 0.48, 250, 0.00042, 2.772e-02, 0.0f, 0.0f, 0.0f, 0); // 150 mum Be
161+
AddLayer("B00", 0.5, 250, x0IT, xrhoIB, resRPhiIT, resZIT, eff, 1);
162+
AddLayer("B01", 1.2, 250, x0IT, xrhoIB, resRPhiIT, resZIT, eff, 1);
163+
AddLayer("B02", 2.5, 250, x0IT, xrhoIB, resRPhiIT, resZIT, eff, 1);
164+
AddLayer("bpipe1", 3.7, 250, 0.0014, 9.24e-02, 0.0f, 0.0f, 0.0f, 0); // 500 mum Be
165+
AddLayer("B03", 7., 250, x0OT, xrhoOT, resRPhiOT, resZOT, eff, 1);
166+
AddLayer("B04", 9., 250, x0OT, xrhoOT, resRPhiOT, resZOT, eff, 1);
167+
AddLayer("B05", 12., 250, x0OT, xrhoOT, resRPhiOT, resZOT, eff, 1);
168+
AddLayer("B06", 20., 250, x0OT, xrhoOT, resRPhiOT, resZOT, eff, 1);
169+
AddLayer("B07", 30., 250, x0OT, xrhoOT, resRPhiOT, resZOT, eff, 1);
170+
AddLayer("B08", 45., 250, x0OT, xrhoOT, resRPhiOT, resZOT, eff, 1);
171+
AddLayer("B09", 60., 250, x0OT, xrhoOT, resRPhiOT, resZOT, eff, 1);
172+
AddLayer("B10", 80., 250, x0OT, xrhoOT, resRPhiOT, resZOT, eff, 1);
173+
}
174+
147175
void FastTracker::AddTPC(float phiResMean, float zResMean)
148176
{
149177
LOG(info) << " Adding standard time projection chamber";
@@ -307,7 +335,7 @@ int FastTracker::FastTrack(o2::track::TrackParCov inputTrack, o2::track::TrackPa
307335
break;
308336
}
309337
}
310-
if (firstActiveLayer <= 0) {
338+
if (firstActiveLayer < 0) {
311339
LOG(fatal) << "No active layers found in FastTracker, check layer setup";
312340
return -2; // no active layers
313341
}

ALICE3/Core/FastTracker.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,9 +42,11 @@ class FastTracker
4242
// Layer and layer configuration
4343
void AddLayer(TString name, float r, float z, float x0, float xrho, float resRPhi = 0.0f, float resZ = 0.0f, float eff = 0.0f, int type = 0);
4444
DetLayer GetLayer(const int layer, bool ignoreBarrelLayers = true) const;
45+
std::vector<DetLayer> GetLayers() const { return layers; }
4546
int GetLayerIndex(const std::string& name) const;
4647
size_t GetNLayers() const { return layers.size(); }
4748
bool IsLayerInert(const int layer) const { return layers[layer].isInert(); }
49+
void ClearLayers() { layers.clear(); }
4850
void SetRadiationLength(const std::string layerName, float x0) { layers[GetLayerIndex(layerName)].setRadiationLength(x0); }
4951
void SetRadius(const std::string layerName, float r) { layers[GetLayerIndex(layerName)].setRadius(r); }
5052
void SetResolutionRPhi(const std::string layerName, float resRPhi) { layers[GetLayerIndex(layerName)].setResolutionRPhi(resRPhi); }
@@ -57,6 +59,7 @@ class FastTracker
5759

5860
void AddSiliconALICE3v4(std::vector<float> pixelResolution);
5961
void AddSiliconALICE3v2(std::vector<float> pixelResolution);
62+
void AddSiliconALICE3(std::vector<float> pixelResolution);
6063
void AddTPC(float phiResMean, float zResMean);
6164

6265
void Print();

ALICE3/TableProducer/alice3-multicharmTable.cxx

Lines changed: 23 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,7 @@ struct alice3multicharmTable {
124124
Configurable<float> xiccMaxEta{"xiccMaxEta", 1.5, "Max eta"};
125125
Configurable<float> massWindowXi{"massWindowXi", 0.015, "Mass window around Xi peak (GeV/c)"};
126126
Configurable<float> massWindowXiC{"massWindowXiC", 0.015, "Mass window around XiC peak (GeV/c)"};
127+
Configurable<float> massWindowXiCC{"massWindowXiCC", 0.4, "Mass window around XiCC peak (GeV/c). Make sure that bkg region is included in this window"};
127128

128129
ConfigurableAxis axisEta{"axisEta", {80, -4.0f, +4.0f}, "#eta"};
129130
ConfigurableAxis axisPt{"axisPt", {VARIABLE_WIDTH, 0.0f, 0.1f, 0.2f, 0.3f, 0.4f, 0.5f, 0.6f, 0.7f, 0.8f, 0.9f, 1.0f, 1.1f, 1.2f, 1.3f, 1.4f, 1.5f, 1.6f, 1.7f, 1.8f, 1.9f, 2.0f, 2.2f, 2.4f, 2.6f, 2.8f, 3.0f, 3.2f, 3.4f, 3.6f, 3.8f, 4.0f, 4.4f, 4.8f, 5.2f, 5.6f, 6.0f, 6.5f, 7.0f, 7.5f, 8.0f, 9.0f, 10.0f, 11.0f, 12.0f, 13.0f, 14.0f, 15.0f, 17.0f, 19.0f, 21.0f, 23.0f, 25.0f, 30.0f, 35.0f, 40.0f, 50.0f}, "pt axis for QA histograms"};
@@ -161,7 +162,8 @@ struct alice3multicharmTable {
161162
Partition<alice3tracks> tracksPiFromXiC =
162163
((aod::a3DecayMap::decayMap & trackSelectionPiFromXiC) == trackSelectionPiFromXiC) && aod::track::signed1Pt > 0.0f && 1.0f / nabs(aod::track::signed1Pt) > minPiCPt&& nabs(aod::track::dcaXY) > piFromXiC_dcaXYconstant + piFromXiC_dcaXYpTdep* nabs(aod::track::signed1Pt) && nabs(aod::track::dcaZ) > piFromXiC_dcaZconstant + piFromXiC_dcaZpTdep* nabs(aod::track::signed1Pt);
163164

164-
Partition<alice3tracks> tracksPiFromXiCC = ((aod::a3DecayMap::decayMap & trackSelectionPiFromXiCC) == trackSelectionPiFromXiCC) && aod::track::signed1Pt > 0.0f && 1.0f / nabs(aod::track::signed1Pt) > minPiCCPt&& nabs(aod::track::dcaXY) > piFromXiCC_dcaXYconstant + piFromXiCC_dcaXYpTdep* nabs(aod::track::signed1Pt);
165+
Partition<alice3tracks> tracksPiFromXiCC =
166+
((aod::a3DecayMap::decayMap & trackSelectionPiFromXiCC) == trackSelectionPiFromXiCC) && aod::track::signed1Pt > 0.0f && 1.0f / nabs(aod::track::signed1Pt) > minPiCCPt&& nabs(aod::track::dcaXY) > piFromXiCC_dcaXYconstant + piFromXiCC_dcaXYpTdep* nabs(aod::track::signed1Pt) && nabs(aod::track::dcaZ) > piFromXiCC_dcaZconstant + piFromXiCC_dcaZpTdep* nabs(aod::track::signed1Pt);
165167

166168
// Helper struct to pass candidate information
167169
struct {
@@ -251,6 +253,11 @@ struct alice3multicharmTable {
251253
}
252254

253255
thisXiCCcandidate.mass = RecoDecay::m(array{array{thisXiCCcandidate.prong0mom[0], thisXiCCcandidate.prong0mom[1], thisXiCCcandidate.prong0mom[2]}, array{thisXiCCcandidate.prong1mom[0], thisXiCCcandidate.prong1mom[1], thisXiCCcandidate.prong1mom[2]}}, array{mass0, mass1});
256+
257+
if (std::fabs(thisXiCCcandidate.mass - o2::constants::physics::MassXiCCPlusPlus) > massWindowXiCC) {
258+
return false;
259+
}
260+
254261
thisXiCCcandidate.pt = std::hypot(thisXiCCcandidate.prong0mom[0] + thisXiCCcandidate.prong1mom[0], thisXiCCcandidate.prong0mom[1] + thisXiCCcandidate.prong1mom[1]);
255262
thisXiCCcandidate.eta = RecoDecay::eta(array{thisXiCCcandidate.prong0mom[0] + thisXiCCcandidate.prong1mom[0], thisXiCCcandidate.prong0mom[1] + thisXiCCcandidate.prong1mom[1], thisXiCCcandidate.prong0mom[2] + thisXiCCcandidate.prong1mom[2]});
256263
return true;
@@ -440,6 +447,13 @@ struct alice3multicharmTable {
440447
histos.add("hPi2cPt", "hPi2cPt", kTH1D, {axisPt});
441448
histos.add("hPiccPt", "hPiccPt", kTH1D, {axisPt});
442449

450+
histos.add("hPi1cDCAxy", "hPi1cDCAxy", kTH1D, {axisDCA});
451+
histos.add("hPi1cDCAz", "hPi1cDCAz", kTH1D, {axisDCA});
452+
histos.add("hPi2cDCAxy", "hPi2cDCAxy", kTH1D, {axisDCA});
453+
histos.add("hPi2cDCAz", "hPi2cDCAz", kTH1D, {axisDCA});
454+
histos.add("hPiccDCAxy", "hPiccDCAxy", kTH1D, {axisDCA});
455+
histos.add("hPiccDCAz", "hPiccDCAz", kTH1D, {axisDCA});
456+
443457
histos.add("hMinXiDecayRadius", "hMinXiDecayRadius", kTH1D, {axisRadius2DXi});
444458
histos.add("hMinXiCDecayRadius", "hMinXiCDecayRadius", kTH1D, {axisRadius});
445459
histos.add("hMinXiCCDecayRadius", "hMinXiCCDecayRadius", kTH1D, {axisRadius});
@@ -717,7 +731,7 @@ struct alice3multicharmTable {
717731
histos.fill(HIST("hDCAxyXiCC"), std::fabs(xiccdcaXY * 1e+4));
718732
histos.fill(HIST("hDCAzXiCC"), std::fabs(xiccdcaZ * 1e+4));
719733

720-
if (std::fabs(thisXiCcandidate.eta) > xiccMaxEta)
734+
if (std::fabs(thisXiCCcandidate.eta) > xiccMaxEta)
721735
continue; // not in central barrel
722736

723737
histos.fill(HIST("hCharmBuilding"), 3.0f);
@@ -774,6 +788,13 @@ struct alice3multicharmTable {
774788
piFromLa.pt(), piFromLa.eta(),
775789
piFromLa.dcaXY(), piFromLa.dcaZ(),
776790
pi1c.eta(), pi2c.eta(), picc.eta());
791+
792+
histos.fill(HIST("hPi1cDCAxy"), std::abs(pi1c.dcaXY() * 1e+4));
793+
histos.fill(HIST("hPi1cDCAz"), std::abs(pi1c.dcaZ() * 1e+4));
794+
histos.fill(HIST("hPi2cDCAxy"), std::abs(pi2c.dcaXY() * 1e+4));
795+
histos.fill(HIST("hPi2cDCAz"), std::abs(pi2c.dcaZ() * 1e+4));
796+
histos.fill(HIST("hPiccDCAxy"), std::abs(picc.dcaXY() * 1e+4));
797+
histos.fill(HIST("hPiccDCAz"), std::abs(picc.dcaZ() * 1e+4));
777798
}
778799
}
779800
histos.fill(HIST("hCombinationsXiCC"), nCombinationsCC);

ALICE3/Tasks/alice3-multicharm.cxx

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -252,9 +252,10 @@ struct alice3multicharm {
252252

253253
histos.add("hBDTScore", "hBDTScore", kTH1D, {axisBDTScore});
254254
histos.add("hBDTScoreVsXiccMass", "hBDTScoreVsXiccMass", kTH2D, {axisXiccMass, axisBDTScore});
255-
histos.add("hBDTScoreVsXiccPt", "hBDTScoreVsXiccPt", kTH2D, {axisXiccMass, axisPt});
255+
histos.add("hBDTScoreVsXiccPt", "hBDTScoreVsXiccPt", kTH2D, {axisPt, axisBDTScore});
256+
histos.add("h3dBDTScore", "h3dBDTScore", kTH3D, {axisPt, axisXiccMass, axisBDTScore});
256257
for (const auto& score : bdt.requiredScores.value) {
257-
histPath = std::format("MLQA/RequiredBDTScore_{}/", static_cast<int>(score * 100));
258+
histPath = std::format("MLQA/RequiredBDTScore_{}/", static_cast<int>(score * 10000));
258259
histPointers.insert({histPath + "hDCAXicDaughters", histos.add((histPath + "hDCAXicDaughters").c_str(), "hDCAXicDaughters", {kTH1D, {{axisDcaDaughters}}})});
259260
histPointers.insert({histPath + "hDCAXiccDaughters", histos.add((histPath + "hDCAXiccDaughters").c_str(), "hDCAXiccDaughters", {kTH1D, {{axisDcaDaughters}}})});
260261
histPointers.insert({histPath + "hDCAxyXi", histos.add((histPath + "hDCAxyXi").c_str(), "hDCAxyXi", {kTH1D, {{axisDCA}}})});
@@ -293,7 +294,7 @@ struct alice3multicharm {
293294
}
294295

295296
template <typename TMCharmCands>
296-
void genericProcessXicc(TMCharmCands xiccCands)
297+
void genericProcessXicc(TMCharmCands const& xiccCands)
297298
{
298299
for (const auto& xiccCand : xiccCands) {
299300
if (bdt.enableML) {
@@ -324,10 +325,11 @@ struct alice3multicharm {
324325
histos.fill(HIST("hBDTScore"), bdtScore);
325326
histos.fill(HIST("hBDTScoreVsXiccMass"), xiccCand.xiccMass(), bdtScore);
326327
histos.fill(HIST("hBDTScoreVsXiccPt"), xiccCand.xiccPt(), bdtScore);
328+
histos.fill(HIST("h3dBDTScore"), xiccCand.xiccPt(), xiccCand.xiccMass(), bdtScore);
327329

328330
for (const auto& requiredScore : bdt.requiredScores.value) {
329331
if (bdtScore > requiredScore) {
330-
histPath = std::format("MLQA/RequiredBDTScore_{}/", static_cast<int>(requiredScore * 100));
332+
histPath = std::format("MLQA/RequiredBDTScore_{}/", static_cast<int>(requiredScore * 10000));
331333
getHist(TH1, histPath + "hDCAXicDaughters")->Fill(xiccCand.xicDauDCA() * 1e+4);
332334
getHist(TH1, histPath + "hDCAXiccDaughters")->Fill(xiccCand.xiccDauDCA() * 1e+4);
333335
getHist(TH1, histPath + "hDCAxyXi")->Fill(std::fabs(xiccCand.xiDCAxy() * 1e+4));
@@ -347,13 +349,13 @@ struct alice3multicharm {
347349
getHist(TH1, histPath + "hPi2cDCAz")->Fill(xiccCand.pi2cDCAz() * 1e+4);
348350
getHist(TH1, histPath + "hPiccDCAxy")->Fill(xiccCand.piccDCAxy() * 1e+4);
349351
getHist(TH1, histPath + "hPiccDCAz")->Fill(xiccCand.piccDCAz() * 1e+4);
350-
getHist(TH1, histPath + "hPi1cDCAz")->Fill(xiccCand.pi1cPt());
351-
getHist(TH1, histPath + "hPi2cDCAz")->Fill(xiccCand.pi2cPt());
352-
getHist(TH1, histPath + "hPiccDCAz")->Fill(xiccCand.piccPt());
352+
getHist(TH1, histPath + "hPi1cPt")->Fill(xiccCand.pi1cPt());
353+
getHist(TH1, histPath + "hPi2cPt")->Fill(xiccCand.pi2cPt());
354+
getHist(TH1, histPath + "hPiccPt")->Fill(xiccCand.piccPt());
353355
getHist(TH1, histPath + "hXiccMass")->Fill(xiccCand.xiccMass());
354356
getHist(TH1, histPath + "hXicMass")->Fill(xiccCand.xicMass());
355-
getHist(TH1, histPath + "hXiccPt")->Fill(xiccCand.xiccPt());
356357
getHist(TH1, histPath + "hXicPt")->Fill(xiccCand.xicPt());
358+
getHist(TH1, histPath + "hXiccPt")->Fill(xiccCand.xiccPt());
357359
getHist(TH3, histPath + "h3dXicc")->Fill(xiccCand.xiccPt(), xiccCand.xiccEta(), xiccCand.xiccMass());
358360
}
359361
}

Common/CCDB/TriggerAliases.h

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,11 @@
1212
#ifndef COMMON_CCDB_TRIGGERALIASES_H_
1313
#define COMMON_CCDB_TRIGGERALIASES_H_
1414

15+
#include <Rtypes.h>
16+
1517
#include <cstdint>
1618
#include <map>
1719
#include <string>
18-
#include <Rtypes.h>
1920

2021
enum triggerAliases {
2122
kINT7 = 0,
@@ -57,7 +58,7 @@ class TriggerAliases
5758
TriggerAliases() = default;
5859
~TriggerAliases() = default;
5960

60-
void AddAlias(uint32_t aliasId, std::string classNames) { mAliasToClassNames[aliasId] = classNames; }
61+
void AddAlias(uint32_t aliasId, std::string const& classNames) { mAliasToClassNames[aliasId] = classNames; }
6162
void AddClassIdToAlias(uint32_t aliasId, int classId);
6263
const std::map<uint32_t, std::string>& GetAliasToClassNamesMap() const { return mAliasToClassNames; }
6364
const std::map<uint32_t, ULong64_t>& GetAliasToTriggerMaskMap() const { return mAliasToTriggerMask; }

Common/CCDB/ctpRateFetcher.cxx

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -11,18 +11,19 @@
1111

1212
#include "ctpRateFetcher.h"
1313

14+
#include <CCDB/BasicCCDBManager.h>
15+
#include <CommonConstants/LHCConstants.h>
16+
#include <DataFormatsCTP/Configuration.h>
17+
#include <DataFormatsCTP/Scalers.h>
18+
#include <DataFormatsParameters/GRPLHCIFData.h>
19+
1420
#include <map>
21+
#include <string>
1522
#include <vector>
1623

17-
#include "CommonConstants/LHCConstants.h"
18-
#include "DataFormatsCTP/Configuration.h"
19-
#include "DataFormatsCTP/Scalers.h"
20-
#include "DataFormatsParameters/GRPLHCIFData.h"
21-
#include "CCDB/BasicCCDBManager.h"
22-
2324
namespace o2
2425
{
25-
double ctpRateFetcher::fetch(o2::ccdb::BasicCCDBManager* ccdb, uint64_t timeStamp, int runNumber, std::string sourceName, bool fCrashOnNull)
26+
double ctpRateFetcher::fetch(o2::ccdb::BasicCCDBManager* ccdb, uint64_t timeStamp, int runNumber, const std::string& sourceName, bool fCrashOnNull)
2627
{
2728
setupRun(runNumber, ccdb, timeStamp);
2829
if (sourceName.find("ZNC") != std::string::npos) {
@@ -109,7 +110,7 @@ void ctpRateFetcher::setupRun(int runNumber, o2::ccdb::BasicCCDBManager* ccdb, u
109110
delete mScalers;
110111
delete mLHCIFdata;
111112
}
112-
std::map<string, string> metadata;
113+
std::map<std::string, std::string> metadata;
113114
mLHCIFdata = ccdb->getSpecific<parameters::GRPLHCIFData>("GLO/Config/GRPLHCIF", timeStamp, metadata);
114115
if (mLHCIFdata == nullptr) {
115116
LOG(fatal) << "GRPLHCIFData not in database, timestamp:" << timeStamp;

Common/CCDB/ctpRateFetcher.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,9 @@
1212
#ifndef COMMON_CCDB_CTPRATEFETCHER_H_
1313
#define COMMON_CCDB_CTPRATEFETCHER_H_
1414

15-
#include <string>
15+
#include <CCDB/BasicCCDBManager.h>
1616

17-
#include "CCDB/BasicCCDBManager.h"
17+
#include <string>
1818

1919
namespace o2
2020
{
@@ -34,7 +34,7 @@ class ctpRateFetcher
3434
{
3535
public:
3636
ctpRateFetcher() = default;
37-
double fetch(o2::ccdb::BasicCCDBManager* ccdb, uint64_t timeStamp, int runNumber, std::string sourceName, bool fCrashOnNull = true);
37+
double fetch(o2::ccdb::BasicCCDBManager* ccdb, uint64_t timeStamp, int runNumber, const std::string& sourceName, bool fCrashOnNull = true);
3838

3939
void setManualCleanup(bool manualCleanup = true) { mManualCleanup = manualCleanup; }
4040

0 commit comments

Comments
 (0)