File indexing completed on 2024-09-07 04:37:47
0001 #ifndef MuonIsolation_PixelTrackExtractor_H
0002 #define MuonIsolation_PixelTrackExtractor_H
0003
0004 #include <string>
0005 #include <vector>
0006
0007 #include "FWCore/Framework/interface/ConsumesCollector.h"
0008
0009 #include "DataFormats/RecoCandidate/interface/IsoDeposit.h"
0010 #include "DataFormats/TrackReco/interface/Track.h"
0011 #include "DataFormats/TrackReco/interface/TrackFwd.h"
0012 #include "PhysicsTools/IsolationAlgos/interface/IsoDepositExtractor.h"
0013 #include "DataFormats/Common/interface/View.h"
0014 #include "DataFormats/TrackReco/interface/Track.h"
0015 #include "MagneticField/Engine/interface/MagneticField.h"
0016 #include "MagneticField/Records/interface/IdealMagneticFieldRecord.h"
0017
0018 namespace muonisolation {
0019
0020 class PixelTrackExtractor : public reco::isodeposit::IsoDepositExtractor {
0021 public:
0022 PixelTrackExtractor() {}
0023 PixelTrackExtractor(const edm::ParameterSet& par, edm::ConsumesCollector&& iC);
0024
0025 ~PixelTrackExtractor() override {}
0026
0027 void fillVetos(const edm::Event& ev, const edm::EventSetup& evSetup, const reco::TrackCollection& track) override {}
0028
0029 virtual reco::IsoDeposit::Vetos vetos(const edm::Event& ev,
0030 const edm::EventSetup& evSetup,
0031 const reco::Track& track) const;
0032
0033 reco::IsoDeposit deposit(const edm::Event& ev,
0034 const edm::EventSetup& evSetup,
0035 const reco::Track& muon) const override;
0036
0037 private:
0038 reco::IsoDeposit::Veto veto(const reco::IsoDeposit::Direction& dir) const;
0039
0040 reco::isodeposit::Direction directionAtPresetRadius(const reco::Track& tk, double bz) const;
0041
0042 private:
0043
0044 edm::ESGetToken<MagneticField, IdealMagneticFieldRecord> theFieldToken;
0045 edm::EDGetTokenT<reco::TrackCollection> theTrackCollectionToken;
0046 std::string theDepositLabel;
0047 double theDiff_r;
0048 double theDiff_z;
0049 double theDR_Max;
0050 double theDR_Veto;
0051 std::string theBeamlineOption;
0052 edm::EDGetTokenT<reco::BeamSpot> theBeamSpotToken;
0053 unsigned int theNHits_Min;
0054 double theChi2Ndof_Max;
0055 double theChi2Prob_Min;
0056 double thePt_Min;
0057
0058 bool thePropagateTracksToRadius;
0059 double theReferenceRadius;
0060
0061 bool theVetoLeadingTrack;
0062 double thePtVeto_Min;
0063 double theDR_VetoPt;
0064 };
0065
0066 }
0067
0068 #endif