87 using namespace susybsm;
108 std::auto_ptr<susybsm::HSCParticleCollection>
result(hscp);
111 std::auto_ptr<susybsm::HSCPCaloInfoCollection> caloInfoCollaptr(caloInfoColl);
118 for(susybsm::HSCParticleCollection::iterator hscpcandidate = hscp->begin(); hscpcandidate != hscp->end(); ++hscpcandidate) {
121 if(track.
isNull())
continue;
122 float dRMin=1000;
int found = -1;
123 for(
unsigned int t=0;
t<trackIsoCollectionHandle->size();
t++) {
125 if( fabs( (1.0/track->pt())-(1.0/Isotrack->pt())) >
maxInvPtDiff)
continue;
126 float dR =
deltaR(track->momentum(), Isotrack->momentum());
127 if(dR <=
minDR && dR < dRMin){ dRMin=
dR; found =
t;}
129 if(found>=0)hscpcandidate->setTrackIso(
reco::TrackRef( trackIsoCollectionHandle, found ));
134 for(susybsm::HSCParticleCollection::iterator hscpcandidate = hscp->begin(); hscpcandidate != hscp->end(); ++hscpcandidate) {
140 for(susybsm::HSCParticleCollection::iterator hscpcandidate = hscp->begin(); hscpcandidate != hscp->end(); ++hscpcandidate) {
146 for(susybsm::HSCParticleCollection::iterator hscpcandidate = hscp->begin(); hscpcandidate != hscp->end(); ++hscpcandidate) {
153 caloInfoColl->resize(hscp->size());
154 for(susybsm::HSCParticleCollection::iterator hscpcandidate = hscp->begin(); hscpcandidate != hscp->end(); ++hscpcandidate, Index++) {
159 for(
int i=0;
i<(int)hscp->size();
i++) {
160 susybsm::HSCParticleCollection::iterator hscpcandidate = hscp->begin() +
i;
161 bool decision =
false;
164 hscp->erase(hscpcandidate);
178 for(
int i=0;
i<(int)hscp->size();
i++) {
179 susybsm::HSCParticleCollection::iterator hscpcandidate = hscp->begin() +
i;
std::vector< HSCPCaloInfo > HSCPCaloInfoCollection
edm::EDGetTokenT< reco::MuonCollection > m_muonsToken
bool getByToken(EDGetToken token, Handle< PROD > &result) const
void addInfoToCandidate(susybsm::HSCParticle &candidate, const edm::Event &iEvent, const edm::EventSetup &iSetup)
BetaCalculatorMUON * beta_calculator_MUON
void addInfoToCandidate(susybsm::HSCParticle &candidate, edm::Handle< reco::TrackCollection > &tracks, edm::Event &iEvent, const edm::EventSetup &iSetup, susybsm::HSCPCaloInfo &caloInfo)
BetaCalculatorTK * beta_calculator_TK
void addInfoToCandidate(susybsm::HSCParticle &candidate, edm::Event &iEvent, const edm::EventSetup &iSetup)
BetaCalculatorECAL * beta_calculator_ECAL
edm::Ref< HSCPCaloInfoCollection > HSCPCaloInfoRef
std::vector< HSCParticle > HSCParticleCollection
OrphanHandle< PROD > put(std::auto_ptr< PROD > product)
Put a new product.
edm::EDGetTokenT< reco::MuonCollection > m_MTmuonsToken
void addInfoToCandidate(susybsm::HSCParticle &candidate, edm::Event &iEvent, const edm::EventSetup &iSetup)
bool isNull() const
Checks for null.
double deltaR(double eta1, double eta2, double phi1, double phi2)
edm::EDGetTokenT< reco::TrackCollection > m_trackToken
edm::Ref< TrackCollection > TrackRef
persistent reference to a Track
BetaCalculatorRPC * beta_calculator_RPC
std::vector< CandidateSelector * > Selectors
std::vector< susybsm::HSCParticle > getHSCPSeedCollection(edm::Handle< reco::TrackCollection > &trackCollectionHandle, edm::Handle< reco::MuonCollection > &muonCollectionHandle, edm::Handle< reco::MuonCollection > &MTmuonCollectionHandle)
edm::EDGetTokenT< reco::TrackCollection > m_trackIsoToken