31 inline bool IsMode(
const int GenMode) {
71 inline std::string
GetName()
const {
return "MaCh3Modes";};
86 std::string
const &fancyname,
88 std::vector<int>
const &GenMap,
90 const std::string& SplineSuffix);
96 std::map<std::string, MaCh3Modes_t>
Mode;
98 std::map<MaCh3Modes_t, MaCh3ModeInfo>
fMode;
int MaCh3Modes_t
Enumerator of MaCh3Mode.
System and monitoring utilities for printing system information and status updates.
Utility functions for handling YAML nodes.
KS: Class describing MaCh3 modes used in the analysis, it is being initialised from config.
std::map< std::string, MaCh3Modes_t > Mode
KS: Handy map which helps find mode number based on string.
int nCCModes
DB: Number of CC modes.
bool IsMaCh3ModeNC(const int Index) const
DB: Get IsNC (a check whether the given MaCh3 corresponds to a Neutral Current mode)
void Initialise(const YAML::Node &config)
KS: Initialise MaCh3 modes based on provided config.
int GetNModes() const
KS: Get number of modes, keep in mind actual number is +1 greater due to unknown category.
MaCh3Modes(std::string const &filename)
KS: Initialise MaCh3 modes using path to config.
void DeclareNewMode(std::string const &name, std::string const &fancyname, int PlotColor, std::vector< int > const &GenMap, const bool IsNC, const std::string &SplineSuffix)
KS: Add new mode.
int NModes
KS: Number of modes, keep in mind actual number is +1 greater due to unknown category.
std::vector< int > ModeMap
KS: Handy map helping us find MaCh3 mode based on Generator mode value.
void Print() const
KS: Print info about initialised modes.
std::string Generator
KS: Name of generator like NEUT, NuWro etc. this is to make stuff fancy.
MaCh3Modes_t GetMode(const std::string &name) const
std::string GetSplineSuffixFromMaCh3Mode(const int Index)
DB: Get binned spline mode suffic from MaCh3 Mode.
std::string Title
KS: Name of loaded modes.
MaCh3Modes_t EnsureModeNameRegistered(std::string const &name)
int GetNCCModes() const
Return count of CC modes.
int GetMaCh3ModePlotColor(const int Index) const
KS: Get normal name of mode, if mode not known you will get UNKNOWN_BAD.
std::string GetName() const
Get class name.
void PrepareMap()
KS: Fill ModeMap.
virtual ~MaCh3Modes()
KS: Empty destructor.
std::string GetMaCh3ModeFancyName(const int Index) const
KS: Get fancy name of mode, if mode not known you will get UNKNOWN_BAD.
std::map< MaCh3Modes_t, MaCh3ModeInfo > fMode
KS: Main map storing info about used modes.
std::string GetMaCh3ModeName(const int Index) const
KS: Get normal name of mode, if mode not known you will get UNKNOWN_BAD.
MaCh3Modes_t GetModeFromGenerator(const int Index) const
KS: Get MaCh3 mode from generator mode.
KS: Class containing information for a single MaCh3Mode.
std::vector< int > GeneratorMaping
Mapping between mode and generator integers.
std::string SplineSuffix
Spline suffix.
std::string FancyName
Mode fancy name.
std::string Name
Mode name.
bool IsMode(const int GenMode)
KS: Checks MaCh3 modes is associated with a given generator mode.
int PlotColor
Mode color for plotting purposes.