Skip to content

Commit d6331ce

Browse files
Refactor ML configuration with new cut parameters
1 parent ab94ead commit d6331ce

1 file changed

Lines changed: 5 additions & 5 deletions

File tree

‎PWGHF/HFC/TableProducer/producerCharmHadronsCharmFemtoDream.cxx‎

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717
#include "PWGHF/Core/CentralityEstimation.h"
1818
#include "PWGHF/Core/HfMlResponseD0ToKPi.h"
1919
#include "PWGHF/Core/HfMlResponseDstarToD0Pi.h"
20+
#include "PWGHF/Core/SelectorCuts.h"
2021
#include "PWGHF/DataModel/CandidateReconstructionTables.h"
2122
#include "PWGHF/DataModel/CandidateSelectionTables.h"
2223
#include "PWGHF/Utils/utilsBfieldCCDB.h"
@@ -68,12 +69,11 @@ struct HfProducerCharmHadronsCharmFemtoDream {
6869
// Each species needs its own model, feature order and pT-dependent cuts.
6970
struct HfMlConfig : ConfigurableGroup {
7071
std::string prefix;
71-
static inline const std::array<double, 3> defaultCuts{1., 0., 0.};
7272
Configurable<int> mlApplicationMode{"mlApplicationMode", FillMlFromSelector, "0: no ML, 1: selector scores, 2: new BDT after selector"};
73-
Configurable<std::vector<double>> binsPtMl{"binsPtMl", std::vector<double>{0., 36.}, "pT bin limits for new BDT"};
74-
Configurable<LabeledArray<double>> cutsMl{"cutsMl", {defaultCuts.data(), 1, 3}, "New BDT cuts per pT bin: background, prompt, nonprompt"};
75-
Configurable<std::vector<int>> cutDirMl{"cutDirMl", std::vector<int>{0, 1, 1}, "Reject scores above (0), below (1), or do not cut (2)"};
76-
Configurable<int> nClassesMl{"nClassesMl", 3, "Three output classes: background, prompt, nonprompt"};
73+
Configurable<std::vector<double>> binsPtMl{"binsPtMl", std::vector<double>{hf_cuts_ml::vecBinsPt}, "pT bin limits for new BDT"};
74+
Configurable<LabeledArray<double>> cutsMl{"cutsMl", {hf_cuts_ml::Cuts[0], hf_cuts_ml::NBinsPt, hf_cuts_ml::NCutScores, hf_cuts_ml::labelsPt, hf_cuts_ml::labelsDmesCutScore}, "New BDT cuts per pT bin: background, prompt, nonprompt"};
75+
Configurable<std::vector<int>> cutDirMl{"cutDirMl", std::vector<int>{hf_cuts_ml::vecCutDir}, "Reject scores above (0), below (1), or do not cut (2)"};
76+
Configurable<int> nClassesMl{"nClassesMl", static_cast<int>(hf_cuts_ml::NCutScores), "Three output classes: background, prompt, nonprompt"};
7777
Configurable<std::vector<std::string>> namesInputFeatures{"namesInputFeatures", std::vector<std::string>{}, "Ordered input feature names for new BDT"};
7878
Configurable<std::vector<std::string>> onnxFileNames{"onnxFileNames", std::vector<std::string>{}, "Model files, one per pT bin"};
7979
Configurable<std::vector<std::string>> modelPathsCCDB{"modelPathsCCDB", std::vector<std::string>{}, "CCDB model paths, one per pT bin"};

0 commit comments

Comments
 (0)