69 #ifndef IClassifierReader__def
70 #define IClassifierReader__def
81 virtual double GetMvaValue(
const std::vector<double>& inputValues )
const = 0;
98 ReadCuts( std::vector<std::string>& theInputVars )
105 const char* inputVars[] = {
"vtx_radius",
"photon_m",
"photon_pT" };
108 if (theInputVars.size() <= 0) {
109 std::cout <<
"Problem in class \"" <<
fClassName <<
"\": empty input vector" << std::endl;
113 if (theInputVars.size() !=
fNvars) {
114 std::cout <<
"Problem in class \"" <<
fClassName <<
"\": mismatch in number of input values: "
115 << theInputVars.size() <<
" != " <<
fNvars << std::endl;
120 for (
size_t ivar = 0; ivar < theInputVars.size(); ivar++) {
121 if (theInputVars[ivar] != inputVars[ivar]) {
122 std::cout <<
"Problem in class \"" <<
fClassName <<
"\": mismatch in input variable names" << std::endl
123 <<
" for variable [" << ivar <<
"]: " << theInputVars[ivar].c_str() <<
" != " << inputVars[ivar] << std::endl;
154 double GetMvaValue(
const std::vector<double>& inputValues )
const;
175 return 2*(x -
xmin)/(xmax - xmin) - 1.0;
183 double GetMvaValue__(
const std::vector<double>& inputValues )
const;
195 std::cout <<
"Problem in class \"" <<
fClassName <<
"\": cannot return classifier response"
196 <<
" because status is dirty" << std::endl;
202 std::vector<double> iV;
203 iV.reserve(inputValues.size());
205 for (std::vector<double>::const_iterator varIt = inputValues.begin();
206 varIt != inputValues.end(); varIt++, ivar++) {