Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:24:10

0001 #ifndef PhysicsTools_PatUtils_interface_SimpleCutBasedElectronIDSelectionFunctor_h
0002 #define PhysicsTools_PatUtils_interface_SimpleCutBasedElectronIDSelectionFunctor_h
0003 
0004 #include "DataFormats/PatCandidates/interface/Electron.h"
0005 #include "FWCore/MessageLogger/interface/MessageLogger.h"
0006 
0007 #include "PhysicsTools/SelectorUtils/interface/Selector.h"
0008 #include "FWCore/ParameterSet/interface/ParameterSet.h"
0009 
0010 #include "FWCore/Utilities/interface/InputTag.h"
0011 
0012 /*
0013 ___________________________________________________________________________________
0014 
0015 Description:
0016 ^^^^^^^^^^^^
0017     This is a class that implements the Simple Cut Based Electron 
0018     Identification cuts.  A more detailed description of the cuts
0019     and the tuning method can be found on this twiki:
0020     
0021     https://twiki.cern.ch/twiki/bin/view/CMS/SimpleCutBasedEleID
0022 
0023     For more information on how to calculate the magnetic field
0024     look here:
0025 
0026     https://twiki.cern.ch/twiki/bin/viewauth/CMS/ConversionBackgroundRejection
0027 ___________________________________________________________________________________
0028 
0029 How to use:
0030 ^^^^^^^^^^^
0031     From CMSSW39 onwards you can simply define an instance of this class:
0032 
0033       SimpleCutBasedElectronIDSelectionFunctor patSele95
0034       (SimpleCutBasedElectronIDSelectionFunctor::relIso95);
0035 
0036     and get the decision with the following method:
0037       pat::Electron *myElec = .....;
0038       bool pass = patSele90(*myElec);
0039 
0040     The various options are listed in the enumeration Version_t. There
0041     is also the option to enter as a constructor argument a PSet
0042     with your favorite cuts.
0043 ___________________________________________________________________________________
0044 
0045     Contacts: Nikolaos Rompotis and Chris Seez
0046     Nikolaos dot Rompotis at Cern dot ch
0047     Chris    dot Seez     at Cern dot ch
0048 
0049     Author:    Nikolaos Rompotis
0050                many thanks to Sal Rappoccio
0051     Imperial College London
0052     7 June 2010, first commit for CMSSW_3_6_1_patchX
0053     11July 2010, implementing the ICHEP Egamma recommendation for 
0054                  removing the Delta Eta cut in the endcaps
0055     30Sept 2010, simplification of conversion rejection in CMSSW39X
0056 ___________________________________________________________________________________
0057 
0058 */
0059 
0060 class SimpleCutBasedElectronIDSelectionFunctor : public Selector<pat::Electron> {
0061 public:  // interface
0062   enum Version_t {
0063     relIso95 = 0,
0064     cIso95,
0065     relIso90,
0066     cIso90,
0067     relIso85,
0068     cIso85,
0069     relIso80,
0070     cIso80,
0071     relIso70,
0072     cIso70,
0073     relIso60,
0074     cIso60,
0075     NONE
0076   };
0077 
0078   SimpleCutBasedElectronIDSelectionFunctor() {}
0079 
0080   // initialize it by inserting directly the cut values in a parameter set
0081   SimpleCutBasedElectronIDSelectionFunctor(edm::ParameterSet const& parameters) {
0082     // get the cuts from the PS
0083     initialize(parameters.getParameter<Double_t>("trackIso_EB"),
0084                parameters.getParameter<Double_t>("ecalIso_EB"),
0085                parameters.getParameter<Double_t>("hcalIso_EB"),
0086                parameters.getParameter<Double_t>("sihih_EB"),
0087                parameters.getParameter<Double_t>("dphi_EB"),
0088                parameters.getParameter<Double_t>("deta_EB"),
0089                parameters.getParameter<Double_t>("hoe_EB"),
0090                parameters.getParameter<Double_t>("cIso_EB"),
0091                parameters.getParameter<Double_t>("trackIso_EE"),
0092                parameters.getParameter<Double_t>("ecalIso_EE"),
0093                parameters.getParameter<Double_t>("hcalIso_EE"),
0094                parameters.getParameter<Double_t>("sihih_EE"),
0095                parameters.getParameter<Double_t>("dphi_EE"),
0096                parameters.getParameter<Double_t>("deta_EE"),
0097                parameters.getParameter<Double_t>("hoe_EE"),
0098                parameters.getParameter<Double_t>("cIso_EE"),
0099                parameters.getParameter<Int_t>("conversionRejection"),
0100                parameters.getParameter<Int_t>("maxNumberOfExpectedMissingHits"));
0101     retInternal_ = getBitTemplate();
0102   }
0103   // initialize it by using only the version name
0104   SimpleCutBasedElectronIDSelectionFunctor(Version_t version) {
0105     if (version == NONE) {
0106       std::cout << "SimpleCutBasedElectronIDSelectionFunctor: If you want to use version NONE "
0107                 << "then you have also to provide the selection cuts by yourself " << std::endl;
0108       std::cout << "SimpleCutBasedElectronIDSelectionFunctor: ID Version is changed to 80cIso " << std::endl;
0109       version = cIso80;
0110     }
0111     initialize(version);
0112     retInternal_ = getBitTemplate();
0113   }
0114 
0115   void initialize(Version_t version) {
0116     version_ = version;
0117     // push back the variables
0118     push_back("trackIso_EB");
0119     push_back("ecalIso_EB");
0120     push_back("hcalIso_EB");
0121     push_back("sihih_EB");
0122     push_back("dphi_EB");
0123     push_back("deta_EB");
0124     push_back("hoe_EB");
0125     push_back("cIso_EB");
0126 
0127     push_back("trackIso_EE");
0128     push_back("ecalIso_EE");
0129     push_back("hcalIso_EE");
0130     push_back("sihih_EE");
0131     push_back("dphi_EE");
0132     push_back("deta_EE");
0133     push_back("hoe_EE");
0134     push_back("cIso_EE");
0135 
0136     push_back("conversionRejection");
0137     push_back("maxNumberOfExpectedMissingHits");
0138 
0139     if (version_ == relIso95) {
0140       set("trackIso_EB", 1.5e-01);
0141       set("ecalIso_EB", 2.0e+00);
0142       set("hcalIso_EB", 1.2e-01);
0143       set("sihih_EB", 1.0e-02);
0144       set("dphi_EB", 8.0e-01);
0145       set("deta_EB", 7.0e-03);
0146       set("hoe_EB", 1.5e-01);
0147       set("cIso_EB", 10000.);
0148 
0149       set("trackIso_EE", 8.0e-02);
0150       set("ecalIso_EE", 6.0e-02);
0151       set("hcalIso_EE", 5.0e-02);
0152       set("sihih_EE", 3.0e-02);
0153       set("dphi_EE", 7.0e-01);
0154       set("deta_EE", 1.0e-02);
0155       set("hoe_EE", 7.0e-02);
0156       set("cIso_EE", 10000.);
0157 
0158       set("conversionRejection", 0);
0159       set("maxNumberOfExpectedMissingHits", 1);
0160 
0161     } else if (version_ == cIso95) {
0162       set("trackIso_EB", 100000.);
0163       set("ecalIso_EB", 100000.);
0164       set("hcalIso_EB", 100000.);
0165       set("sihih_EB", 1.0e-02);
0166       set("dphi_EB", 8.0e-01);
0167       set("deta_EB", 7.0e-03);
0168       set("hoe_EB", 1.5e-01);
0169       set("cIso_EB", 1.5e-01);
0170 
0171       set("trackIso_EE", 100000.);
0172       set("ecalIso_EE", 100000.);
0173       set("hcalIso_EE", 100000.);
0174       set("sihih_EE", 3.0e-02);
0175       set("dphi_EE", 7.0e-01);
0176       set("deta_EE", 1.0e-02);
0177       set("hoe_EE", 7.0e-02);
0178       set("cIso_EE", 1.0e-01);
0179 
0180       set("conversionRejection", 0);
0181       set("maxNumberOfExpectedMissingHits", 1);
0182 
0183     } else if (version_ == relIso90) {
0184       set("trackIso_EB", 1.2e-01);
0185       set("ecalIso_EB", 9.0e-02);
0186       set("hcalIso_EB", 1.0e-01);
0187       set("sihih_EB", 1.0e-02);
0188       set("dphi_EB", 8.0e-01);
0189       set("deta_EB", 7.0e-03);
0190       set("hoe_EB", 1.2e-01);
0191       set("cIso_EB", 10000.);
0192 
0193       set("trackIso_EE", 5.0e-02);
0194       set("ecalIso_EE", 6.0e-02);
0195       set("hcalIso_EE", 3.0e-02);
0196       set("sihih_EE", 3.0e-02);
0197       set("dphi_EE", 7.0e-01);
0198       set("deta_EE", 9.0e-03);
0199       set("hoe_EE", 5.0e-02);
0200       set("cIso_EE", 10000.);
0201 
0202       set("conversionRejection", 1);
0203       set("maxNumberOfExpectedMissingHits", 1);
0204     } else if (version_ == cIso90) {
0205       set("trackIso_EB", 100000.);
0206       set("ecalIso_EB", 100000.);
0207       set("hcalIso_EB", 100000.);
0208       set("sihih_EB", 1.0e-02);
0209       set("dphi_EB", 8.0e-01);
0210       set("deta_EB", 7.0e-03);
0211       set("hoe_EB", 1.2e-01);
0212       set("cIso_EB", 1.0e-01);
0213 
0214       set("trackIso_EE", 100000.);
0215       set("ecalIso_EE", 100000.);
0216       set("hcalIso_EE", 100000.);
0217       set("sihih_EE", 3.0e-02);
0218       set("dphi_EE", 7.0e-01);
0219       set("deta_EE", 9.0e-03);
0220       set("hoe_EE", 5.0e-02);
0221       set("cIso_EE", 7.0e-02);
0222 
0223       set("conversionRejection", 1);
0224       set("maxNumberOfExpectedMissingHits", 1);
0225     } else if (version_ == relIso85) {
0226       set("trackIso_EB", 9.0e-02);
0227       set("ecalIso_EB", 8.0e-02);
0228       set("hcalIso_EB", 1.0e-01);
0229       set("sihih_EB", 1.0e-02);
0230       set("dphi_EB", 6.0e-02);
0231       set("deta_EB", 6.0e-03);
0232       set("hoe_EB", 4.0e-02);
0233       set("cIso_EB", 10000.);
0234 
0235       set("trackIso_EE", 5.0e-02);
0236       set("ecalIso_EE", 5.0e-02);
0237       set("hcalIso_EE", 2.5e-02);
0238       set("sihih_EE", 3.0e-02);
0239       set("dphi_EE", 4.0e-02);
0240       set("deta_EE", 7.0e-03);
0241       set("hoe_EE", 2.5e-02);
0242       set("cIso_EE", 10000.);
0243 
0244       set("conversionRejection", 1);
0245       set("maxNumberOfExpectedMissingHits", 1);
0246     } else if (version_ == cIso85) {
0247       set("trackIso_EB", 100000.);
0248       set("ecalIso_EB", 100000.);
0249       set("hcalIso_EB", 100000.);
0250       set("sihih_EB", 1.0e-02);
0251       set("dphi_EB", 6.0e-02);
0252       set("deta_EB", 6.0e-03);
0253       set("hoe_EB", 4.0e-02);
0254       set("cIso_EB", 9.0e-02);
0255 
0256       set("trackIso_EE", 100000.);
0257       set("ecalIso_EE", 100000.);
0258       set("hcalIso_EE", 100000.);
0259       set("sihih_EE", 3.0e-02);
0260       set("dphi_EE", 4.0e-02);
0261       set("deta_EE", 7.0e-03);
0262       set("hoe_EE", 2.5e-02);
0263       set("cIso_EE", 6.0e-02);
0264 
0265       set("conversionRejection", 1);
0266       set("maxNumberOfExpectedMissingHits", 1);
0267     } else if (version_ == relIso80) {
0268       set("trackIso_EB", 9.0e-02);
0269       set("ecalIso_EB", 7.0e-02);
0270       set("hcalIso_EB", 1.0e-01);
0271       set("sihih_EB", 1.0e-02);
0272       set("dphi_EB", 6.0e-02);
0273       set("deta_EB", 4.0e-03);
0274       set("hoe_EB", 4.0e-02);
0275       set("cIso_EB", 100000.);
0276 
0277       set("trackIso_EE", 4.0e-02);
0278       set("ecalIso_EE", 5.0e-02);
0279       set("hcalIso_EE", 2.5e-02);
0280       set("sihih_EE", 3.0e-02);
0281       set("dphi_EE", 3.0e-02);
0282       set("deta_EE", 7.0e-03);
0283       set("hoe_EE", 2.5e-02);
0284       set("cIso_EE", 100000.);
0285 
0286       set("conversionRejection", 1);
0287       set("maxNumberOfExpectedMissingHits", 0);
0288     } else if (version_ == cIso80) {
0289       set("trackIso_EB", 100000.);
0290       set("ecalIso_EB", 100000.);
0291       set("hcalIso_EB", 100000.);
0292       set("sihih_EB", 1.0e-02);
0293       set("dphi_EB", 6.0e-02);
0294       set("deta_EB", 4.0e-03);
0295       set("hoe_EB", 4.0e-02);
0296       set("cIso_EB", 7.0e-02);
0297 
0298       set("trackIso_EE", 100000.);
0299       set("ecalIso_EE", 100000.);
0300       set("hcalIso_EE", 100000.);
0301       set("sihih_EE", 3.0e-02);
0302       set("dphi_EE", 3.0e-02);
0303       set("deta_EE", 7.0e-03);
0304       set("hoe_EE", 2.5e-02);
0305       set("cIso_EE", 6.0e-02);
0306 
0307       set("conversionRejection", 1);
0308       set("maxNumberOfExpectedMissingHits", 0);
0309     } else if (version_ == relIso70) {
0310       set("trackIso_EB", 5.0e-02);
0311       set("ecalIso_EB", 6.0e-02);
0312       set("hcalIso_EB", 3.0e-02);
0313       set("sihih_EB", 1.0e-02);
0314       set("dphi_EB", 3.0e-02);
0315       set("deta_EB", 4.0e-03);
0316       set("hoe_EB", 2.5e-02);
0317       set("cIso_EB", 100000.);
0318 
0319       set("trackIso_EE", 2.5e-02);
0320       set("ecalIso_EE", 2.5e-02);
0321       set("hcalIso_EE", 2.0e-02);
0322       set("sihih_EE", 3.0e-02);
0323       set("dphi_EE", 2.0e-02);
0324       set("deta_EE", 5.0e-03);
0325       set("hoe_EE", 2.5e-02);
0326       set("cIso_EE", 100000.);
0327 
0328       set("conversionRejection", 1);
0329       set("maxNumberOfExpectedMissingHits", 0);
0330     } else if (version_ == cIso70) {
0331       set("trackIso_EB", 100000.);
0332       set("ecalIso_EB", 100000.);
0333       set("hcalIso_EB", 100000.);
0334       set("sihih_EB", 1.0e-02);
0335       set("dphi_EB", 3.0e-02);
0336       set("deta_EB", 4.0e-03);
0337       set("hoe_EB", 2.5e-02);
0338       set("cIso_EB", 4.0e-02);
0339 
0340       set("trackIso_EE", 100000.);
0341       set("ecalIso_EE", 100000.);
0342       set("hcalIso_EE", 100000.);
0343       set("sihih_EE", 3.0e-02);
0344       set("dphi_EE", 2.0e-02);
0345       set("deta_EE", 5.0e-03);
0346       set("hoe_EE", 2.5e-02);
0347       set("cIso_EE", 3.0e-02);
0348 
0349       set("conversionRejection", 1);
0350       set("maxNumberOfExpectedMissingHits", 0);
0351     } else if (version_ == relIso60) {
0352       set("trackIso_EB", 4.0e-02);
0353       set("ecalIso_EB", 4.0e-02);
0354       set("hcalIso_EB", 3.0e-02);
0355       set("sihih_EB", 1.0e-02);
0356       set("dphi_EB", 2.5e-02);
0357       set("deta_EB", 4.0e-03);
0358       set("hoe_EB", 2.5e-02);
0359       set("cIso_EB", 100000.);
0360 
0361       set("trackIso_EE", 2.5e-02);
0362       set("ecalIso_EE", 2.0e-02);
0363       set("hcalIso_EE", 2.0e-02);
0364       set("sihih_EE", 3.0e-02);
0365       set("dphi_EE", 2.0e-02);
0366       set("deta_EE", 5.0e-03);
0367       set("hoe_EE", 2.5e-02);
0368       set("cIso_EE", 100000.);
0369 
0370       set("conversionRejection", 1);
0371       set("maxNumberOfExpectedMissingHits", 0);
0372     } else if (version_ == cIso60) {
0373       set("trackIso_EB", 100000.);
0374       set("ecalIso_EB", 100000.);
0375       set("hcalIso_EB", 100000.);
0376       set("sihih_EB", 1.0e-02);
0377       set("dphi_EB", 2.5e-02);
0378       set("deta_EB", 4.0e-03);
0379       set("hoe_EB", 2.5e-02);
0380       set("cIso_EB", 3.0e-02);
0381 
0382       set("trackIso_EE", 100000.);
0383       set("ecalIso_EE", 100000.);
0384       set("hcalIso_EE", 100000.);
0385       set("sihih_EE", 3.0e-02);
0386       set("dphi_EE", 2.0e-02);
0387       set("deta_EE", 5.0e-03);
0388       set("hoe_EE", 2.5e-02);
0389       set("cIso_EE", 2.0e-02);
0390 
0391       set("conversionRejection", 1);
0392       set("maxNumberOfExpectedMissingHits", 0);
0393     }
0394   }
0395 
0396   void initialize(Double_t trackIso_EB,
0397                   Double_t ecalIso_EB,
0398                   Double_t hcalIso_EB,
0399                   Double_t sihih_EB,
0400                   Double_t dphi_EB,
0401                   Double_t deta_EB,
0402                   Double_t hoe_EB,
0403                   Double_t cIso_EB,
0404                   Double_t trackIso_EE,
0405                   Double_t ecalIso_EE,
0406                   Double_t hcalIso_EE,
0407                   Double_t sihih_EE,
0408                   Double_t dphi_EE,
0409                   Double_t deta_EE,
0410                   Double_t hoe_EE,
0411                   Double_t cIso_EE,
0412                   Int_t conversionRejection,
0413                   Int_t maxNumberOfExpectedMissingHits) {
0414     version_ = NONE;
0415     push_back("trackIso_EB");
0416     push_back("ecalIso_EB");
0417     push_back("hcalIso_EB");
0418     push_back("sihih_EB");
0419     push_back("dphi_EB");
0420     push_back("deta_EB");
0421     push_back("hoe_EB");
0422     push_back("cIso_EB");
0423 
0424     push_back("trackIso_EE");
0425     push_back("ecalIso_EE");
0426     push_back("hcalIso_EE");
0427     push_back("sihih_EE");
0428     push_back("dphi_EE");
0429     push_back("deta_EE");
0430     push_back("hoe_EE");
0431     push_back("cIso_EE");
0432 
0433     push_back("conversionRejection");
0434     push_back("maxNumberOfExpectedMissingHits");
0435 
0436     set("trackIso_EB", trackIso_EB);
0437     set("ecalIso_EB", ecalIso_EB);
0438     set("hcalIso_EB", hcalIso_EB);
0439     set("sihih_EB", sihih_EB);
0440     set("dphi_EB", dphi_EB);
0441     set("deta_EB", deta_EB);
0442     set("hoe_EB", hoe_EB);
0443     set("cIso_EB", cIso_EB);
0444 
0445     set("trackIso_EE", trackIso_EE);
0446     set("ecalIso_EE", ecalIso_EE);
0447     set("hcalIso_EE", hcalIso_EE);
0448     set("sihih_EE", sihih_EE);
0449     set("dphi_EE", dphi_EE);
0450     set("deta_EE", deta_EE);
0451     set("hoe_EE", hoe_EE);
0452     set("cIso_EE", cIso_EE);
0453 
0454     set("conversionRejection", conversionRejection);
0455     set("maxNumberOfExpectedMissingHits", maxNumberOfExpectedMissingHits);
0456   }
0457 
0458   bool operator()(const pat::Electron& electron, pat::strbitset& ret) override {
0459     // for the time being only Spring10 variable definition
0460     return spring10Variables(electron, ret);
0461   }
0462   using Selector<pat::Electron>::operator();
0463   // function with the Spring10 variable definitions
0464   bool spring10Variables(const pat::Electron& electron, pat::strbitset& ret) {
0465     ret.set(false);
0466     //
0467     Double_t eleET = electron.p4().Pt();
0468     Double_t trackIso = electron.dr03TkSumPt() / eleET;
0469     Double_t ecalIso = electron.dr03EcalRecHitSumEt() / eleET;
0470     Double_t hcalIso = electron.dr03HcalTowerSumEt() / eleET;
0471     Double_t sihih = electron.sigmaIetaIeta();
0472     Double_t Dphi = electron.deltaPhiSuperClusterTrackAtVtx();
0473     Double_t Deta = electron.deltaEtaSuperClusterTrackAtVtx();
0474     Double_t HoE = electron.hadronicOverEm();
0475     Double_t cIso = 0;
0476     if (electron.isEB()) {
0477       cIso =
0478           (electron.dr03TkSumPt() + std::max(0., electron.dr03EcalRecHitSumEt() - 1.) + electron.dr03HcalTowerSumEt()) /
0479           eleET;
0480     } else {
0481       cIso = (electron.dr03TkSumPt() + electron.dr03EcalRecHitSumEt() + electron.dr03HcalTowerSumEt()) / eleET;
0482     }
0483     Int_t innerHits = electron.gsfTrack()->hitPattern().numberOfLostHits(reco::HitPattern::MISSING_INNER_HITS);
0484     // in 39 conversion rejection variables are accessible from Gsf electron
0485     Double_t dist = electron.convDist();  // default value is -9999 if conversion partner not found
0486     Double_t dcot = electron.convDcot();  // default value is -9999 if conversion partner not found
0487     Bool_t isConv = fabs(dist) < 0.02 && fabs(dcot) < 0.02;
0488     // now apply the cuts
0489     if (electron.isEB()) {  // BARREL case
0490       // check the EB cuts
0491       if (trackIso < cut("trackIso_EB", double()) || ignoreCut("trackIso_EB"))
0492         passCut(ret, "trackIso_EB");
0493       if (ecalIso < cut("ecalIso_EB", double()) || ignoreCut("ecalIso_EB"))
0494         passCut(ret, "ecalIso_EB");
0495       if (hcalIso < cut("hcalIso_EB", double()) || ignoreCut("hcalIso_EB"))
0496         passCut(ret, "hcalIso_EB");
0497       if (sihih < cut("sihih_EB", double()) || ignoreCut("sihih_EB"))
0498         passCut(ret, "sihih_EB");
0499       if (fabs(Dphi) < cut("dphi_EB", double()) || ignoreCut("dphi_EB"))
0500         passCut(ret, "dphi_EB");
0501       if (fabs(Deta) < cut("deta_EB", double()) || ignoreCut("deta_EB"))
0502         passCut(ret, "deta_EB");
0503       if (HoE < cut("hoe_EB", double()) || ignoreCut("hoe_EB"))
0504         passCut(ret, "hoe_EB");
0505       if (cIso < cut("cIso_EB", double()) || ignoreCut("cIso_EB"))
0506         passCut(ret, "cIso_EB");
0507       // pass all the EE cuts
0508       passCut(ret, "trackIso_EE");
0509       passCut(ret, "ecalIso_EE");
0510       passCut(ret, "hcalIso_EE");
0511       passCut(ret, "sihih_EE");
0512       passCut(ret, "dphi_EE");
0513       passCut(ret, "deta_EE");
0514       passCut(ret, "hoe_EE");
0515       passCut(ret, "cIso_EE");
0516     } else {  // ENDCAPS case
0517       // check the EE cuts
0518       if (trackIso < cut("trackIso_EE", double()) || ignoreCut("trackIso_EE"))
0519         passCut(ret, "trackIso_EE");
0520       if (ecalIso < cut("ecalIso_EE", double()) || ignoreCut("ecalIso_EE"))
0521         passCut(ret, "ecalIso_EE");
0522       if (hcalIso < cut("hcalIso_EE", double()) || ignoreCut("hcalIso_EE"))
0523         passCut(ret, "hcalIso_EE");
0524       if (sihih < cut("sihih_EE", double()) || ignoreCut("sihih_EE"))
0525         passCut(ret, "sihih_EE");
0526       if (fabs(Dphi) < cut("dphi_EE", double()) || ignoreCut("dphi_EE"))
0527         passCut(ret, "dphi_EE");
0528       if (fabs(Deta) < cut("deta_EE", double()) || ignoreCut("deta_EE"))
0529         passCut(ret, "deta_EE");
0530       if (HoE < cut("hoe_EE", double()) || ignoreCut("hoe_EE"))
0531         passCut(ret, "hoe_EE");
0532       if (cIso < cut("cIso_EE", double()) || ignoreCut("cIso_EE"))
0533         passCut(ret, "cIso_EE");
0534       // pass all the EB cuts
0535       passCut(ret, "trackIso_EB");
0536       passCut(ret, "ecalIso_EB");
0537       passCut(ret, "hcalIso_EB");
0538       passCut(ret, "sihih_EB");
0539       passCut(ret, "dphi_EB");
0540       passCut(ret, "deta_EB");
0541       passCut(ret, "hoe_EB");
0542       passCut(ret, "cIso_EB");
0543     }
0544 
0545     // conversion rejection common for EB and EE
0546     if (innerHits <= cut("maxNumberOfExpectedMissingHits", int()))
0547       passCut(ret, "maxNumberOfExpectedMissingHits");
0548     if (0 == cut("conversionRejection", int()) || isConv == false)
0549       passCut(ret, "conversionRejection");
0550     setIgnored(ret);
0551     return (bool)ret;
0552   }
0553 
0554 private:  // member variables
0555   // version of the cuts
0556   Version_t version_;
0557 };
0558 
0559 #endif