134 if(!TKHandle.isValid() ){
edm::LogError(
"ProduceIsolationMap") <<
"TK Tracks collection not found";
return; }
143 std::vector<HSCPIsolation> IsolationInfoColl(tkTracks->size());
146 for(TrackCollection::const_iterator itTrack = tkTracks->begin(); itTrack != tkTracks->end(); ++itTrack, TkIndex++) {
157 double CountHighPt = 0;
158 for(TrackCollection::const_iterator itTrack2 = TKHandle->begin(); itTrack2 != TKHandle->end(); ++itTrack2){
159 if(fabs(itTrack->pt()-itTrack2->pt())<0.1 && fabs(itTrack->eta()-itTrack2->eta())<0.05)
continue;
160 float dR =
deltaR(itTrack->momentum(), itTrack2->momentum());
162 SumPt+= itTrack2->pt();
167 IsolationInfoColl[TkIndex].Set_TK_CountHighPt(CountHighPt);
168 IsolationInfoColl[TkIndex].Set_TK_Count (Count);
169 IsolationInfoColl[TkIndex].Set_TK_SumEt (SumPt);
172 filler.insert(tkTracks, IsolationInfoColl.begin(), IsolationInfoColl.end());
174 iEvent.
put(trackHSCPIsolMap);
double coneEnergy(double dR, EnergyType)
edm::InputTag inputCollection_
std::vector< const EcalRecHit * > ecalRecHits
hits in the cone
std::vector< Track > TrackCollection
collection of Tracks
OrphanHandle< PROD > put(std::auto_ptr< PROD > product)
Put a new product.
TrackDetectorAssociator trackAssociator_
TrackAssociatorParameters parameters_
std::vector< const HBHERecHit * > hcalRecHits
bool getByLabel(InputTag const &tag, Handle< PROD > &result) const
double deltaR(double eta1, double eta2, double phi1, double phi2)
TrackDetMatchInfo associate(const edm::Event &, const edm::EventSetup &, const FreeTrajectoryState &, const AssociatorParameters &)