7 #include <boost/regex.hpp>
11 using namespace reco::isodeposit;
16 inputIsoDepositToken_(iC.consumes<
Isolation>(input_))
27 else throw cms::Exception(
"Not Implemented") <<
"Mode '" << mode <<
"' not implemented. " <<
28 "Supported modes are 'sum', 'sumRelative', 'max', 'maxRelative', 'sum2', 'sum2Relative', 'count'." <<
29 "New methods can be easily implemented if requested.";
35 if (conf.
exists(
"threshold")) {
38 if (conf.
exists(
"skipDefaultVeto")) {
42 if (conf.
exists(
"vetos")) {
44 throw cms::Exception(
"Configuration") <<
"You can't both configure this module with 'veto'/'threshold' AND with 'vetos'!";
45 if (!conf.
exists(
"skipDefaultVeto"))
46 throw cms::Exception(
"Configuration") <<
"When using the expert configuration variable 'vetos' you must specify the value for 'skipDefaultVeto' too.";
48 typedef std::vector<std::string>
vstring;
51 for (vstring::const_iterator it = vetos.begin(), ed = vetos.end(); it != ed; ++it) {
60 for (AbsVetos::iterator it =
vetos_.begin(), ed =
vetos_.end(); it != ed; ++it) {
69 (*it)->setEvent(event,eventSetup);
91 for (AbsVetos::const_iterator it =
vetos_.begin(), ed =
vetos_.end(); it != ed; ++it) {
92 (
const_cast<AbsVeto *
>(*it))->centerOn(eta,
phi);
103 throw cms::Exception(
"Logic error") <<
"Should not happen at " << __FILE__ <<
", line " << __LINE__;
static reco::isodeposit::AbsVeto * make(const char *string, edm::ConsumesCollector &iC)
T getParameter(std::string const &) const
virtual void beginEvent(const edm::Event &event, const edm::EventSetup &eventSetup)
double candEnergy() const
Get energy or pT attached to cand trajectory.
double sum2Within(double coneSize, const AbsVetos &vetos=AbsVetos(), bool skipDepositVeto=false) const
reco::isodeposit::AbsVetos vetos_
bool exists(std::string const ¶meterName) const
checks if a parameter exists
double countWithin(double coneSize, const AbsVetos &vetos=AbsVetos(), bool skipDepositVeto=false) const
double maxWithin(double coneSize, const AbsVetos &vetos=AbsVetos(), bool skipDepositVeto=false) const
double sumWithin(double coneSize, const AbsVetos &vetos=AbsVetos(), bool skipDepositVeto=false) const
virtual ~IsoDepositIsolator()
edm::Handle< Isolation > handle_
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is excluding the probing of A single or multiple positive and the trigger will pass if any such matching triggers are PASS or EXCEPTION[A criterion thatmatches no triggers at all is detected and causes a throw.] A single negative with an expectation of appropriate bit checking in the decision and the trigger will pass if any such matching triggers are FAIL or EXCEPTION A wildcarded negative criterion that matches more than one trigger in the trigger but the state exists so we define the behavior If all triggers are the negative crieriion will lead to accepting the event(this again matches the behavior of"!*"before the partial wildcard feature was incorporated).The per-event"cost"of each negative criterion with multiple relevant triggers is about the same as!*was in the past
reco::isodeposit::EventDependentAbsVetos evdepVetos_
edm::EDGetTokenT< Isolation > inputIsoDepositToken_
virtual float getValue(const edm::ProductID &id, size_t index) const
volatile std::atomic< bool > shutdown_flag false
virtual std::string description() const