Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2022-03-23 12:04:25

0001 #ifndef HLTMuonL3PreFilter_h
0002 #define HLTMuonL3PreFilter_h
0003 
0004 /** \class HLTMuonL3PreFilter
0005  *
0006  *
0007  *  This class is an HLTFilter (-> EDFilter) implementing a first
0008  *  filtering for HLT muons
0009  *
0010  *  \author J. Alcaraz, J-R Vlimant
0011  *
0012  */
0013 
0014 #include "HLTrigger/HLTcore/interface/HLTFilter.h"
0015 #include "DataFormats/L1Trigger/interface/L1MuonParticleFwd.h"
0016 #include "DataFormats/RecoCandidate/interface/RecoChargedCandidateFwd.h"
0017 #include "DataFormats/TrackReco/interface/TrackFwd.h"
0018 #include "DataFormats/MuonReco/interface/MuonFwd.h"
0019 #include "DataFormats/BeamSpot/interface/BeamSpot.h"
0020 #include "DataFormats/MuonReco/interface/MuonSelectors.h"
0021 #include "DataFormats/MuonReco/interface/MuonTrackLinks.h"
0022 #include "DataFormats/Math/interface/deltaR.h"
0023 #include "DataFormats/RecoCandidate/interface/RecoChargedCandidate.h"
0024 #include "DataFormats/RecoCandidate/interface/RecoChargedCandidateFwd.h"
0025 #include "FWCore/ParameterSet/interface/ConfigurationDescriptions.h"
0026 #include "FWCore/ParameterSet/interface/ParameterSetDescription.h"
0027 #include "MuonAnalysis/MuonAssociators/interface/PropagateToMuonSetup.h"
0028 
0029 class HLTMuonL3PreFilter : public HLTFilter {
0030 public:
0031   explicit HLTMuonL3PreFilter(const edm::ParameterSet&);
0032   ~HLTMuonL3PreFilter() override;
0033   static void fillDescriptions(edm::ConfigurationDescriptions& descriptions);
0034   bool hltFilter(edm::Event&,
0035                  const edm::EventSetup&,
0036                  trigger::TriggerFilterObjectWithRefs& filterproduct) const override;
0037 
0038 private:
0039   bool triggeredByLevel2(const reco::TrackRef& track, std::vector<reco::RecoChargedCandidateRef>& vcands) const;
0040   bool applySelection(const reco::RecoChargedCandidateRef&, const reco::BeamSpot&) const;
0041 
0042   const PropagateToMuonSetup propSetup_;
0043   const edm::InputTag beamspotTag_;
0044   const edm::EDGetTokenT<reco::BeamSpot> beamspotToken_;
0045   const edm::InputTag candTag_;  // input tag identifying product contains muons
0046   const edm::EDGetTokenT<reco::RecoChargedCandidateCollection> candToken_;  // token identifying product contains muons
0047   const edm::InputTag previousCandTag_;  // input tag identifying product contains muons passing the previous level
0048   const edm::EDGetTokenT<trigger::TriggerFilterObjectWithRefs>
0049       previousCandToken_;          // token identifying product contains muons passing the previous level
0050   const edm::InputTag l1CandTag_;  // input tag identifying product contains muons passing the L1 level
0051   const edm::EDGetTokenT<trigger::TriggerFilterObjectWithRefs>
0052       l1CandToken_;                // token identifying product contains muons passing the L1 level
0053   const edm::InputTag recoMuTag_;  // input tag identifying reco muons
0054   const edm::EDGetTokenT<reco::MuonCollection> recoMuToken_;  // token identifying product contains reco muons
0055   const int min_N_;                                           // minimum number of muons to fire the trigger
0056   const double max_Eta_;                                      // Eta cut
0057   const int min_Nhits_;                                       // threshold on number of hits on muon
0058   const double max_Dr_;                                       // maximum impact parameter cut
0059   const double min_Dr_;                                       // minimum impact parameter cut
0060   const double max_Dz_;                                       // dz cut
0061   const double min_DxySig_;                                   // dxy significance cut
0062   const double min_Pt_;                                       // pt threshold in GeV
0063   const double nsigma_Pt_;                                    // pt uncertainty margin (in number of sigmas)
0064   const double max_NormalizedChi2_;                           // cutoff in normalized chi2
0065   const double max_DXYBeamSpot_;                              // cutoff in dxy from the beamspot
0066   const double min_DXYBeamSpot_;                              // minimum cut on dxy from the beamspot
0067   const int min_NmuonHits_;                                   // cutoff in minumum number of chi2 hits
0068   const double max_PtDifference_;  // cutoff in maximum different between global track and tracker track
0069   const double min_TrackPt_;       // cutoff in tracker track pt
0070 
0071   // cuts for L3FromL1
0072   const int min_MuonStations_L3fromL1_;  // cut on min number of stations - for L3FromL1
0073   const unsigned int allowedTypeMask_L3fromL1_;
0074   const unsigned int requiredTypeMask_L3fromL1_;
0075   double maxNormalizedChi2_L3fromL1_;
0076   muon::SelectionType trkMuonId_;
0077   const double L1MatchingdR_;
0078   const double L1MatchingdR2_;
0079   const bool matchPreviousCand_;
0080 
0081   const bool devDebug_;
0082   const edm::InputTag theL3LinksLabel;
0083   const edm::EDGetTokenT<reco::MuonTrackLinksCollection> linkToken_;
0084 };
0085 
0086 #endif  //HLTMuonL3PreFilter_h