28 template <
typename T1,
typename T2>
35 inputToken1_(consumes<
trigger::TriggerFilterObjectWithRefs>(inputTag1_)),
36 inputToken2_(consumes<
trigger::TriggerFilterObjectWithRefs>(inputTag2_)),
37 triggerType1_(iConfig.
template getParameter<
int>(
"triggerType1")),
38 triggerType2_(iConfig.
template getParameter<
int>(
"triggerType2")),
39 min_Dphi_(iConfig.
template getParameter<double>(
"MinDphi")),
40 max_Dphi_(iConfig.
template getParameter<double>(
"MaxDphi")),
41 min_Deta_(iConfig.
template getParameter<double>(
"MinDeta")),
42 max_Deta_(iConfig.
template getParameter<double>(
"MaxDeta")),
43 min_Minv_(iConfig.
template getParameter<double>(
"MinMinv")),
44 max_Minv_(iConfig.
template getParameter<double>(
"MaxMinv")),
45 min_DelR_(iConfig.
template getParameter<double>(
"MinDelR")),
46 max_DelR_(iConfig.
template getParameter<double>(
"MaxDelR")),
47 min_Pt_(iConfig.
template getParameter<double>(
"MinPt")),
48 max_Pt_(iConfig.
template getParameter<double>(
"MaxPt")),
51 cutdphi_(min_Dphi_ <= max_Dphi_),
52 cutdeta_(min_Deta_ <= max_Deta_),
53 cutminv_(min_Minv_ <= max_Minv_),
54 cutdelr_(min_DelR_ <= max_DelR_),
55 cutpt_(min_Pt_ <= max_Pt_)
67 template <
typename T1,
typename T2>
69 template <
typename T1,
typename T2>
72 makeHLTFilterDescription(
desc);
79 desc.add<
int>(
"triggerType1", 0);
80 desc.add<
int>(
"triggerType2", 0);
81 desc.add<
double>(
"MinDphi", +1.0);
82 desc.add<
double>(
"MaxDphi", -1.0);
83 desc.add<
double>(
"MinDeta", +1.0);
84 desc.add<
double>(
"MaxDeta", -1.0);
85 desc.add<
double>(
"MinMinv", +1.0);
86 desc.add<
double>(
"MaxMinv", -1.0);
87 desc.add<
double>(
"MinDelR", +1.0);
88 desc.add<
double>(
"MaxDelR", -1.0);
89 desc.add<
double>(
"MinPt", +1.0);
90 desc.add<
double>(
"MaxPt", -1.0);
91 desc.add<
int>(
"MinN", 1);
100 template <
typename T1,
typename T2>
106 using namespace reco;
117 std::vector<T1Ref> coll1;
118 std::vector<T2Ref> coll2;
122 if (
iEvent.getByToken(inputToken1_, handle1) &&
iEvent.getByToken(inputToken2_, handle2)) {
130 for (
unsigned int i = 0;
i < originTag1_.size(); ++
i) {
138 const auto& prov =
iEvent.getStableProvenance(pid);
139 const string&
label(prov.moduleLabel());
140 const string&
instance(prov.productInstanceName());
141 const string&
process(prov.processName());
143 if (tagOld.encode() != tagNew.encode()) {
149 for (
unsigned int i = 0;
i < originTag2_.size(); ++
i) {
157 const auto& prov =
iEvent.getStableProvenance(pid);
158 const string&
label(prov.moduleLabel());
159 const string&
instance(prov.productInstanceName());
160 const string&
process(prov.processName());
162 if (tagOld.encode() != tagNew.encode()) {
174 for (
unsigned int i1 = 0;
i1 != n1;
i1++) {
181 for (
unsigned int i2 =
I;
i2 != n2;
i2++) {
187 Dphi = 2.0 *
M_PI - Dphi;
195 double DelR(
sqrt(Dphi * Dphi + Deta * Deta));
197 if (((!cutdphi_) || ((min_Dphi_ <= Dphi) && (Dphi <= max_Dphi_))) &&
198 ((!cutdeta_) || ((min_Deta_ <= Deta) && (Deta <= max_Deta_))) &&
199 ((!cutminv_) || ((min_Minv_ <= Minv) && (Minv <= max_Minv_))) &&
200 ((!cutdelr_) || ((min_DelR_ <= DelR) && (DelR <= max_DelR_))) &&
201 ((!cutpt_) || ((min_Pt_ <= Pt) && (Pt <= max_Pt_)))) {
203 filterproduct.
addObject(triggerType1_, r1);
const edm::InputTag inputTag2_
Log< level::Info, true > LogVerbatim
void getObjects(Vids &ids, VRphoton &refs) const
various physics-level getters:
HLTDoublet(const edm::ParameterSet &)
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
static PFTauRenderPlugin instance
const edm::InputTag inputTag1_
std::string defaultModuleLabel()
bool accept(const edm::Event &event, const edm::TriggerResults &triggerTable, const std::string &triggerPath)
void addObject(int id, const reco::RecoEcalCandidateRef &ref)
setters for L3 collections: (id=physics type, and Ref<C>)
Abs< T >::type abs(const T &t)
const std::complex< double > I
def template(fileName, svg, replaceme="REPLACEME")
void addCollectionTag(const edm::InputTag &collectionTag)
collectionTags
void add(std::string const &label, ParameterSetDescription const &psetDescription)
bool hltFilter(edm::Event &, const edm::EventSetup &, trigger::TriggerFilterObjectWithRefs &filterproduct) const override
math::PtEtaPhiELorentzVectorF LorentzVector