Options for the PDF MVA method.
More...
#include <PDF.h>
|
virtual void | load (const boost::property_tree::ptree &pt) override |
| Load mechanism (used by Weightfile) to load Options from a xml tree.
|
|
virtual void | save (boost::property_tree::ptree &pt) const override |
| Save mechanism (used by Weightfile) to store Options in a xml tree.
|
|
virtual po::options_description | getDescription () override |
| Returns a program options description for all available options.
|
|
virtual std::string | getMethod () const override |
| Return method name.
|
|
|
std::string | m_binning = "frequency" |
| which type of binning is performed e.g.
|
|
std::string | m_mode = "probability" |
| mode which defines the final output e.g.
|
|
unsigned int | m_nBins = 100 |
| number of bins used to bin the data
|
|
Options for the PDF MVA method.
Definition at line 29 of file PDF.h.
◆ getDescription()
po::options_description getDescription |
( |
| ) |
|
|
overridevirtual |
Returns a program options description for all available options.
Implements Options.
Definition at line 40 of file PDF.cc.
41 {
42 po::options_description description("PDF options");
43 description.add_options()
44 (
"binning", po::value<std::string>(&
m_binning),
"Binning used to bin the data (frequency|equidistant)")
45 (
"nBins", po::value<unsigned int>(&
m_nBins),
"Number of bins used to bin the data")
46 (
"mode", po::value<std::string>(&
m_mode),
"Mode used to calculate return value of expert");
47 return description;
48 }
unsigned int m_nBins
number of bins used to bin the data
std::string m_binning
which type of binning is performed e.g.
std::string m_mode
mode which defines the final output e.g.
◆ getMethod()
virtual std::string getMethod |
( |
| ) |
const |
|
inlineoverridevirtual |
◆ load()
void load |
( |
const boost::property_tree::ptree & |
pt | ) |
|
|
overridevirtual |
Load mechanism (used by Weightfile) to load Options from a xml tree.
- Parameters
-
Implements Options.
Definition at line 19 of file PDF.cc.
20 {
21 int version = pt.get<int>("PDF_version");
22 if (version != 1) {
23 B2ERROR("Unknown weightfile version " << std::to_string(version));
24 throw std::runtime_error("Unknown weightfile version " + std::to_string(version));
25 }
26 m_binning = pt.get<std::string>(
"PDF_binning");
27 m_mode = pt.get<std::string>(
"PDF_mode");
28 m_nBins = pt.get<
unsigned int>(
"PDF_nBins");
29
30 }
◆ save()
void save |
( |
boost::property_tree::ptree & |
pt | ) |
const |
|
overridevirtual |
Save mechanism (used by Weightfile) to store Options in a xml tree.
- Parameters
-
Implements Options.
Definition at line 32 of file PDF.cc.
33 {
34 pt.put("PDF_version", 1);
36 pt.put(
"PDF_mode",
m_mode);
38 }
◆ m_binning
std::string m_binning = "frequency" |
which type of binning is performed e.g.
frequency or equidistant
Definition at line 54 of file PDF.h.
◆ m_mode
std::string m_mode = "probability" |
mode which defines the final output e.g.
probability
Definition at line 55 of file PDF.h.
◆ m_nBins
unsigned int m_nBins = 100 |
number of bins used to bin the data
Definition at line 56 of file PDF.h.
The documentation for this class was generated from the following files: