31 return (*iter).second;
40 return (*iter).second;
46 if (std::isnan(
value)) {
47 throw std::runtime_error(
"TauFeature::addFeature: Given " + name +
" value is NaN!");
49 if (std::isinf(
value)){
50 throw std::runtime_error(
"TauFeature::addFeature: Given " + name +
" value is inf!");
58 const std::vector<double>&
value) {
79 throw std::runtime_error(
"PanTau::TauFeature::add( PanTau::TauFeature* ): Error when adding scalar feature " + p.first);
86 throw std::runtime_error(
"PanTau::TauFeature::add( PanTau::TauFeature* ): Error when adding vector feature " + p.first);
bool isValid(const T &p)
Av: we implement here an ATLAS-sepcific convention: all particles which are 99xxxxx are fine.
static const std::vector< double > s_defaultVec(0)
Class containing features of a tau seed.
int nValues() const
returns the size of the m_featureMap
FeatureMap m_featureMap
The map containg all features.
VectorFeatureMap m_vecFeatureMap
The map containg all features.
int nVecValues() const
returns the size of the m_vecFeatureMap
bool addFeature(const std::string &name, const double value)
adds a new feature
FeatureMap::const_iterator FeatureMapConstIter
VectorFeatureMap::const_iterator VectorFeatureMapConstIter
bool addVecFeature(const std::string &name, const std::vector< double > &value)
adds a new vector feature
TauFeature()
Default constructor.
double value(const std::string &name, bool &isValid) const
returns the value of the feature given by its name
void add(PanTau::TauFeature *otherFeatures)
const std::vector< double > & vecValue(const std::string &name) const
returns the value of a vector feature given by its name
virtual ~TauFeature()
Destructor.