20 chargeReq_ = iConfig.
getParameter<uint32_t>(
"AbsChargeReq");
24 ~CaloRecoTauDiscriminationByCharge()
override{}
29 bool oneOrThreeProng_;
32 double CaloRecoTauDiscriminationByCharge::discriminate(
34 uint16_t nSigTk = theTauRef->signalTracks().size();
35 bool chargeok = (
abs(theTauRef->charge()) ==
int(chargeReq_));
36 bool oneOrThreeProngOK = ( (nSigTk==1) || (nSigTk==3) || !oneOrThreeProng_ );
38 return ( (chargeok && oneOrThreeProngOK) ? 1. : 0. );
47 desc.
add<
unsigned int>(
"AbsChargeReq", 1);
48 desc.
add<
bool>(
"ApplyOneOrThreeProngCut",
false);
55 descriptions.
add(
"caloRecoTauDiscriminationByCharge", desc);
T getParameter(std::string const &) const
#define DEFINE_FWK_MODULE(type)
Abs< T >::type abs(const T &t)
ParameterDescriptionBase * add(U const &iLabel, T const &value)
virtual double discriminate(const TauRef &tau) const =0
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
void add(std::string const &label, ParameterSetDescription const &psetDescription)