Skip to content

Commit 801ac0b

Browse files
committed
make it compile
1 parent c2c814a commit 801ac0b

3 files changed

Lines changed: 9 additions & 11 deletions

File tree

ALICE3/TableProducer/OTF/testCcdbConsumer0.cxx

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@
1616
/// \author Nicolò Jacazio <nicolo.jacazio@cern.ch>, Universita del Piemonte Orientale (IT)
1717
///
1818

19-
#include "ALICE3/Core/FastTracker.h"
2019
#include "ALICE3/Core/FlatLutEntry.h"
2120
#include "ALICE3/Core/FlatTrackSmearer.h"
2221
#include "ALICE3/Core/TrackUtilities.h"
@@ -30,7 +29,6 @@
3029

3130
#include <TPDGCode.h>
3231

33-
#include <map>
3432
#include <string>
3533
#include <vector>
3634

@@ -151,35 +149,37 @@ struct TestCcdbConsumer0 {
151149
}
152150

153151
o2::track::TrackParCov fullTrack = o2::upgrade::convertMCParticleToO2Track(mcParticle, pdgDB);
152+
float interpolatedEff;
153+
const o2::delphes::lutEntry_t* lutEntry = fullSmearer.getLUTEntry(std::abs(mcParticle.pdgCode()), mcParticles.size(), 0.f, mcParticle.eta(), mcParticle.pt(), interpolatedEff);
154154
switch (std::abs(mcParticle.pdgCode())) {
155155
case PDG_t::kElectron:
156-
success = fullSmearer.smearTrack(fullTrack, lutDataEl, mcParticles.size());
156+
success = fullSmearer.smearTrack(fullTrack, lutEntry, mcParticles.size());
157157
if (success) {
158158
histos.fill(HIST("full/hDeltaPtEl"), (mcParticle.pt() - fullTrack.getPt()) / fullTrack.getPt());
159159
histos.fill(HIST("full/h2dDeltaPtEl"), fullTrack.getPt(), (mcParticle.pt() - fullTrack.getPt()) / fullTrack.getPt());
160160
}
161161
break;
162162
case PDG_t::kMuonMinus:
163-
success = fullSmearer.smearTrack(fullTrack, lutDataMu, mcParticles.size());
163+
success = fullSmearer.smearTrack(fullTrack, lutEntry, mcParticles.size());
164164
histos.fill(HIST("full/hDeltaPtMu"), (fullTrack.getPt() - mcParticle.pt()) / fullTrack.getPt());
165165
histos.fill(HIST("full/h2dDeltaPtMu"), fullTrack.getPt(), (mcParticle.pt() - fullTrack.getPt()) / fullTrack.getPt());
166166
break;
167167
case PDG_t::kPiPlus:
168-
success = fullSmearer.smearTrack(fullTrack, lutDataPi, mcParticles.size());
168+
success = fullSmearer.smearTrack(fullTrack, lutEntry, mcParticles.size());
169169
if (success) {
170170
histos.fill(HIST("full/hDeltaPtPi"), (fullTrack.getPt() - mcParticle.pt()) / fullTrack.getPt());
171171
histos.fill(HIST("full/h2dDeltaPtPi"), fullTrack.getPt(), (mcParticle.pt() - fullTrack.getPt()) / fullTrack.getPt());
172172
}
173173
break;
174174
case PDG_t::kKPlus:
175-
success = fullSmearer.smearTrack(fullTrack, lutDataKa, mcParticles.size());
175+
success = fullSmearer.smearTrack(fullTrack, lutEntry, mcParticles.size());
176176
if (success) {
177177
histos.fill(HIST("full/hDeltaPtKa"), (fullTrack.getPt() - mcParticle.pt()) / fullTrack.getPt());
178178
histos.fill(HIST("full/h2dDeltaPtKa"), fullTrack.getPt(), (mcParticle.pt() - fullTrack.getPt()) / fullTrack.getPt());
179179
}
180180
break;
181181
case PDG_t::kProton:
182-
success = fullSmearer.smearTrack(fullTrack, lutDataPr, mcParticles.size());
182+
success = fullSmearer.smearTrack(fullTrack, lutEntry, mcParticles.size());
183183
if (success) {
184184
histos.fill(HIST("full/hDeltaPtPr"), (fullTrack.getPt() - mcParticle.pt()) / fullTrack.getPt());
185185
histos.fill(HIST("full/h2dDeltaPtPr"), fullTrack.getPt(), (mcParticle.pt() - fullTrack.getPt()) / fullTrack.getPt());

ALICE3/TableProducer/OTF/testCcdbConsumer1.cxx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,8 @@ struct TestCcdbConsumer1 {
3838
o2::framework::Service<o2::framework::O2DatabasePDG> pdgDB;
3939
const std::unordered_set<int> pdgsToBeHandled = {PDG_t::kElectron, PDG_t::kMuonMinus, PDG_t::kPiPlus, PDG_t::kKPlus, PDG_t::kProton};
4040

41+
o2::delphes::TrackSmearer smearer;
42+
4143
void init(o2::framework::InitContext&)
4244
{
4345
histos.add("hDeltaPtEl", "hDeltaPtEl", o2::framework::kTH1D, {axisDeltaPt});
@@ -59,7 +61,6 @@ struct TestCcdbConsumer1 {
5961
void process(o2::aod::McCollisions const& mcCollisions, o2::aod::McParticles const& mcParticles, o2::aod::A3LookUpTables const& luts)
6062
{
6163
for (const auto& _ : mcCollisions) {
62-
o2::delphes::TrackSmearer smearer;
6364
const auto thisTable = luts.begin();
6465
smearer.viewTable(PDG_t::kElectron, thisTable.lutEl());
6566
smearer.viewTable(PDG_t::kMuonMinus, thisTable.lutMu());

ALICE3/TableProducer/OTF/testCcdbConsumer2.cxx

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,6 @@
1616
/// \author Nicolò Jacazio <nicolo.jacazio@cern.ch>, Universita del Piemonte Orientale (IT)
1717
///
1818

19-
#include "ALICE3/Core/FastTracker.h"
20-
#include "ALICE3/Core/FlatLutEntry.h"
2119
#include "ALICE3/Core/FlatTrackSmearer.h"
2220
#include "ALICE3/Core/TrackUtilities.h"
2321
#include "ALICE3/DataModel/OTFLUT.h"
@@ -30,7 +28,6 @@
3028

3129
#include <TPDGCode.h>
3230

33-
#include <map>
3431
#include <string>
3532
#include <vector>
3633

0 commit comments

Comments
 (0)