8 #ifndef IMPSCORE_FUNCTOR_SCORE_UNARY_FUNCTION_H
9 #define IMPSCORE_FUNCTOR_SCORE_UNARY_FUNCTION_H
11 #include <IMP/score_functor/score_functor_config.h>
15 IMPSCOREFUNCTOR_BEGIN_NAMESPACE
19 template <
class Score,
int D = 2>
29 return score_.get_score_and_derivative(
33 virtual double evaluate(
double feature)
const IMP_OVERRIDE {
41 IMPSCOREFUNCTOR_END_NAMESPACE
Import IMP/kernel/UnaryFunction.h in the namespace.
IMP::kernel::UnaryFunction UnaryFunction
Abstract single variable functor class for score functions.
A class to store an fixed array of same-typed values.
virtual double evaluate(double feature) const
Calculate score with respect to the given feature.
#define IMP_OBJECT_METHODS(Name)
Define the basic things needed by any Object.
virtual DerivativePair evaluate_with_derivative(double feature) const
Calculate score and derivative with respect to the given feature.
A Score on the distance between a pair of particles.
std::pair< double, double > DerivativePair
A pair representing a function value with its first derivative.
Various general useful macros for IMP.