CMS 3D CMS Logo

SimpleJetTrackAssociator.cc
Go to the documentation of this file.
4 
8  for (size_t i = 0, n = in.size(); i < n; i++) {
9  const reco::Track &t = in[i];
10  if ((t.numberOfValidHits() < nHits_) || (t.normalizedChi2() > chi2nMax_))
11  continue;
12  if (deltaR2(dir, t) < deltaR2_) {
13  reco::TrackRef tr(&in, i); // note: transient ref
14  out.push_back(tr);
15  }
16  }
17 }
18 
22  for (size_t i = 0, n = in.size(); i < n; i++) {
23  const reco::Track &t = in[i];
24  if ((t.numberOfValidHits() < nHits_) || (t.normalizedChi2() > chi2nMax_))
25  continue;
26  if (deltaR2(dir, t) < deltaR2_) {
27  reco::TrackRef tr = in.refAt(i).castTo<reco::TrackRef>();
28  out.push_back(tr);
29  }
30  }
31 }
mps_fire.i
i
Definition: mps_fire.py:355
dqmiodumpmetadata.n
n
Definition: dqmiodumpmetadata.py:28
edm::RefVector< TrackCollection >
edm::Ref< TrackCollection >
deltaR.h
helper::SimpleJetTrackAssociator::associate
void associate(const math::XYZVector &dir, const edm::View< reco::Track > &in, reco::TrackRefVector &out)
Definition: SimpleJetTrackAssociator.cc:19
Track.h
reco::Track
Definition: Track.h:27
OrderedSet.t
t
Definition: OrderedSet.py:90
edm::View
Definition: CaloClusterFwd.h:14
SimpleJetTrackAssociator.h
helper::SimpleJetTrackAssociator::nHits_
int32_t nHits_
Definition: SimpleJetTrackAssociator.h:20
recoMuon::in
Definition: RecoMuonEnumerators.h:6
math::XYZVector
XYZVectorD XYZVector
spatial vector with cartesian internal representation
Definition: Vector3D.h:31
helper::SimpleJetTrackAssociator::chi2nMax_
double chi2nMax_
Definition: SimpleJetTrackAssociator.h:21
HLTMuonOfflineAnalyzer_cfi.deltaR2
deltaR2
Definition: HLTMuonOfflineAnalyzer_cfi.py:105
helper::SimpleJetTrackAssociator::associateTransient
void associateTransient(const math::XYZVector &dir, const reco::TrackCollection &in, reco::TrackRefVector &out)
Definition: SimpleJetTrackAssociator.cc:5
MillePedeFileConverter_cfg.out
out
Definition: MillePedeFileConverter_cfg.py:31
reco::TrackCollection
std::vector< Track > TrackCollection
collection of Tracks
Definition: TrackFwd.h:14
helper::SimpleJetTrackAssociator::deltaR2_
double deltaR2_
Definition: SimpleJetTrackAssociator.h:19
DeadROC_duringRun.dir
dir
Definition: DeadROC_duringRun.py:23