|
16 | 16 | /// |
17 | 17 | /// \author Alexandre Bigot <alexandre.bigot@cern.ch>, IPHC Strasbourg |
18 | 18 |
|
| 19 | +#include <vector> |
| 20 | + |
19 | 21 | #include "CommonConstants/PhysicsConstants.h" |
20 | 22 | #include "Framework/AnalysisTask.h" |
21 | 23 | #include "Framework/runDataProcessing.h" |
@@ -254,7 +256,7 @@ struct HfTreeCreatorDplusToPiKPi { |
254 | 256 | Configurable<bool> fillOnlyBackground{"fillOnlyBackground", false, "Flag to fill derived tables with background for ML trainings"}; |
255 | 257 | Configurable<float> downSampleBkgFactor{"downSampleBkgFactor", 1., "Fraction of background candidates to keep for ML trainings"}; |
256 | 258 | Configurable<float> ptMaxForDownSample{"ptMaxForDownSample", 10., "Maximum pt for the application of the downsampling factor"}; |
257 | | - Configurable<std::vector<int>> classMl{"classMlindexes", {0, 2}, "Indexes of ML bkg and non-prompt scores."}; |
| 259 | + Configurable<std::vector<int>> classMlIndexes{"classMlIndexes", {0, 2}, "Indexes of ML bkg and non-prompt scores."}; |
258 | 260 |
|
259 | 261 | HfHelper hfHelper; |
260 | 262 |
|
@@ -304,8 +306,8 @@ struct HfTreeCreatorDplusToPiKPi { |
304 | 306 |
|
305 | 307 | std::vector<float> outputMl = {-999., -999.}; |
306 | 308 | if constexpr (doMl) { |
307 | | - for (unsigned int iclass = 0; iclass < classMl->size(); iclass++) { |
308 | | - outputMl[iclass] = candidate.mlProbDplusToPiKPi()[classMl->at(iclass)]; |
| 309 | + for (unsigned int iclass = 0; iclass < classMlIndexes->size(); iclass++) { |
| 310 | + outputMl[iclass] = candidate.mlProbDplusToPiKPi()[classMlIndexes->at(iclass)]; |
309 | 311 | } |
310 | 312 | rowCandidateMl( |
311 | 313 | outputMl[0], |
@@ -513,7 +515,7 @@ struct HfTreeCreatorDplusToPiKPi { |
513 | 515 | } |
514 | 516 | for (const auto& candidate : reconstructedCandSigMl) { |
515 | 517 | if (downSampleBkgFactor < 1.) { |
516 | | - float pseudoRndm = candidate.ptProng0() * 1000. - (int64_t)(candidate.ptProng0() * 1000); |
| 518 | + float pseudoRndm = candidate.ptProng0() * 1000. - static_cast<int64_t>(candidate.ptProng0() * 1000); |
517 | 519 | if (candidate.pt() < ptMaxForDownSample && pseudoRndm >= downSampleBkgFactor) { |
518 | 520 | continue; |
519 | 521 | } |
|
0 commit comments