Skip to content

Commit aeff252

Browse files
ddobrigkalibuild
authored andcommitted
Add simple output (AliceO2Group#3543)
* Add simple output * Please consider the following formatting changes (AliceO2Group#174) --------- Co-authored-by: David Dobrigkeit Chinellato <david.dobrigkeit.chinellato.cern.ch> Co-authored-by: ALICE Builder <alibuild@users.noreply.github.com>
1 parent 6cdd7cc commit aeff252

File tree

1 file changed

+9
-3
lines changed

1 file changed

+9
-3
lines changed

Common/Tasks/integrationTestCCDB.cxx

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,9 @@ struct integrationTestCCDB {
5555
Configurable<std::string> lutPath{"lutPath", "GLO/Param/MatLUT", "Path of the Lut parametrization"};
5656
Configurable<std::string> geoPath{"geoPath", "GLO/Config/GeometryAligned", "Path of the geometry file"};
5757

58+
HistogramRegistry histos{"Histos", {}, OutputObjHandlingPolicy::AnalysisObject};
59+
o2::base::MatLayerCylSet* lut;
60+
5861
int mRunNumber;
5962

6063
void initMagneticFieldCCDB(aod::BCsWithTimestamps::iterator const& bc)
@@ -93,22 +96,25 @@ struct integrationTestCCDB {
9396

9497
void init(InitContext& context)
9598
{
96-
// Empty for the time being
99+
lut = 0x0;
100+
const AxisSpec axis{1, 0.0f, 1.0f, ""};
101+
histos.add<TH1>("hDFs", "hDFs", HistType::kTH1F, {axis});
97102
}
98103

99104
void process(aod::BCsWithTimestamps const& bcs)
100105
{
101106
mRunNumber = 0;
102107

103108
auto bc = bcs.begin(); // first element
109+
histos.fill(HIST("hDFs"), 0.5f);
104110

105111
ccdb->setURL(ccdburl);
106112
ccdb->setCaching(true);
107113
ccdb->setLocalObjectValidityChecking();
108114
ccdb->setFatalWhenNull(false);
109-
if (loadMatLut) {
115+
if (loadMatLut && !lut) {
110116
LOG(info) << "Loading material LUT...";
111-
o2::base::MatLayerCylSet* lut = o2::base::MatLayerCylSet::rectifyPtrFromFile(ccdb->get<o2::base::MatLayerCylSet>(lutPath));
117+
lut = o2::base::MatLayerCylSet::rectifyPtrFromFile(ccdb->get<o2::base::MatLayerCylSet>(lutPath));
112118
LOG(info) << "Material LUT successfully loaded!";
113119
LOG(info) << "Material LUT min R: " << lut->getRMin() << " max R: " << lut->getRMax();
114120
}

0 commit comments

Comments
 (0)