68 using namespace susybsm;
105 TKIsolationPtcut_ = iConfig.
getParameter<
double > (
"TkIsolationPtCut");
106 IsolationConeDR_ = iConfig.
getParameter<
double > (
"IsolationConeDR");
111 parameters_.loadParameters( parameters );
112 trackAssociator_.useDefaultPropagator();
115 produces<ValueMap<HSCPIsolation> >();
133 if(!TKHandle.isValid() ){
edm::LogError(
"ProduceIsolationMap") <<
"TK Tracks collection not found";
return; }
142 std::vector<HSCPIsolation> IsolationInfoColl(tkTracks->size());
145 for(TrackCollection::const_iterator itTrack = tkTracks->begin(); itTrack != tkTracks->end(); ++itTrack, TkIndex++) {
156 double CountHighPt = 0;
157 for(TrackCollection::const_iterator itTrack2 = TKHandle->begin(); itTrack2 != TKHandle->end(); ++itTrack2){
158 if(fabs(itTrack->pt()-itTrack2->pt())<0.1 && fabs(itTrack->eta()-itTrack2->eta())<0.05)
continue;
159 float dR =
deltaR(itTrack->momentum(), itTrack2->momentum());
160 if(dR>IsolationConeDR_)
continue;
161 SumPt+= itTrack2->pt();
163 if(itTrack2->pt()<TKIsolationPtcut_)
continue;
166 IsolationInfoColl[TkIndex].Set_TK_CountHighPt(CountHighPt);
167 IsolationInfoColl[TkIndex].Set_TK_Count (Count);
168 IsolationInfoColl[TkIndex].Set_TK_SumEt (SumPt);
171 filler.
insert(tkTracks, IsolationInfoColl.begin(), IsolationInfoColl.end());
173 iEvent.
put(trackHSCPIsolMap);
T getParameter(std::string const &) const
double coneEnergy(double dR, EnergyType)
edm::InputTag inputCollection_
#define DEFINE_FWK_MODULE(type)
std::vector< const EcalRecHit * > ecalRecHits
hits in the cone
void insert(const H &h, I begin, I end)
std::vector< Track > TrackCollection
collection of Tracks
edm::InputTag EErecHitsLabel_
ProduceIsolationMap(const edm::ParameterSet &)
OrphanHandle< PROD > put(std::auto_ptr< PROD > product)
Put a new product.
TrackDetectorAssociator trackAssociator_
TrackAssociatorParameters parameters_
std::vector< const HBHERecHit * > hcalRecHits
edm::InputTag EBrecHitsLabel_
bool getByLabel(InputTag const &tag, Handle< PROD > &result) const
double deltaR(double eta1, double eta2, double phi1, double phi2)
virtual void produce(edm::Event &, const edm::EventSetup &) override
edm::InputTag HCALrecHitsLabel_