20 #ifndef TMVA_TREEINFERENCE_OBJECTIVES
21 #define TMVA_TREEINFERENCE_OBJECTIVES
29 namespace Experimental {
30 namespace Objectives {
36 return 1.0 / (1.0 +
std::exp(-1.0 * value));
60 if (
name.compare(
"identity") == 0)
61 return std::function<T(T)>(Identity<T>);
62 else if (
name.compare(
"logistic") == 0)
63 return std::function<T(T)>(Logistic<T>);
64 else if (
name.compare(
"softmax") == 0)
65 return std::function<T(T)>(Exponential<T>);
67 throw std::runtime_error(
"Objective function with name \"" +
name +
"\" is not implemented.");