CMS 3D CMS Logo

IPProducer.h
Go to the documentation of this file.
1 #ifndef RecoBTag_IPProducer
2 #define RecoBTag_IPProducer
3 
4 // system include files
5 #include <algorithm>
6 #include <cmath>
7 #include <functional>
8 #include <iostream>
9 #include <memory>
10 
11 // user include files
22 
28 
32 
41 
47 
48 // system include files
49 #include <memory>
50 
51 // user include files
56 
58 
59 namespace IPProducerHelpers {
60  class FromJTA {
61  public:
64  iC.consumes<reco::JetTracksAssociationCollection>(iConfig.getParameter<edm::InputTag>("jetTracks"))) {}
65  reco::TrackRefVector tracks(const reco::JTATagInfo& it) { return it.tracks(); }
66  std::vector<reco::JTATagInfo> makeBaseVector(const edm::Event& iEvent) {
68  iEvent.getByToken(token_associator, jetTracksAssociation);
69  std::vector<reco::JTATagInfo> bases;
70  size_t i = 0;
71  for (reco::JetTracksAssociationCollection::const_iterator it = jetTracksAssociation->begin();
72  it != jetTracksAssociation->end();
73  it++, i++) {
74  edm::Ref<reco::JetTracksAssociationCollection> jtaRef(jetTracksAssociation, i);
75  bases.push_back(reco::JTATagInfo(jtaRef));
76  }
77  return bases;
78  }
79 
81  };
83  public:
85  : token_jets(iC.consumes<edm::View<reco::Jet> >(iConfig.getParameter<edm::InputTag>(jets))),
86  token_cands(iC.consumes<edm::View<reco::Candidate> >(iConfig.getParameter<edm::InputTag>("candidates"))),
87  maxDeltaR(iConfig.getParameter<double>("maxDeltaR")),
88  explicitJTA(iConfig.existsAs<bool>("explicitJTA") ? iConfig.getParameter<bool>("explicitJTA") : false) {}
89 
90  const std::vector<reco::CandidatePtr>& tracks(const reco::JetTagInfo& it) { return m_map[it.jet().key()]; }
91  std::vector<reco::JetTagInfo> makeBaseVector(const edm::Event& iEvent) {
93  iEvent.getByToken(token_jets, jets);
94  std::vector<reco::JetTagInfo> bases;
95 
97  iEvent.getByToken(token_cands, cands);
98  m_map.clear();
99  m_map.resize(jets->size());
100  double maxDeltaR2 = maxDeltaR * maxDeltaR;
101  size_t i = 0;
102  for (edm::View<reco::Jet>::const_iterator it = jets->begin(); it != jets->end(); it++, i++) {
104  bases.push_back(reco::JetTagInfo(jRef));
105  if (explicitJTA) {
106  for (size_t j = 0; j < it->numberOfDaughters(); ++j) {
107  if (it->daughterPtr(j)->bestTrack() != nullptr && it->daughterPtr(j)->charge() != 0) {
108  m_map[i].push_back(it->daughterPtr(j));
109  }
110  }
111  } else {
112  for (size_t j = 0; j < cands->size(); ++j) {
113  if ((*cands)[j].bestTrack() != nullptr && (*cands)[j].charge() != 0 && (*cands)[j].pt() > 0 &&
114  Geom::deltaR2((*cands)[j], (*jets)[i]) < maxDeltaR2) {
115  m_map[i].push_back(cands->ptrAt(j));
116  }
117  }
118  }
119  }
120  return bases;
121  }
122  std::vector<std::vector<reco::CandidatePtr> > m_map;
125  double maxDeltaR;
127  };
128 } // namespace IPProducerHelpers
129 template <class Container, class Base, class Helper>
131 public:
132  typedef std::vector<reco::IPTagInfo<Container, Base> > Product;
133 
134  explicit IPProducer(const edm::ParameterSet&);
135  ~IPProducer() override;
136  static void fillDescriptions(edm::ConfigurationDescriptions& descriptions);
137 
138  void produce(edm::Event&, const edm::EventSetup&) override;
139 
140 private:
141  void checkEventSetup(const edm::EventSetup& iSetup);
142 
148 
152  std::unique_ptr<HistogramProbabilityEstimator> m_probabilityEstimator;
153  unsigned long long m_calibrationCacheId2D;
154  unsigned long long m_calibrationCacheId3D;
155  bool m_useDB;
156 
159  double m_cutMaxTIP;
160  double m_cutMinPt;
162  double m_cutMaxLIP;
166  Helper m_helper;
167 };
168 
169 // -*- C++ -*-
170 //
171 // Package: IPProducer
172 // Class: IPProducer
173 //
181 //
182 // Original Author: Andrea Rizzi
183 // Created: Thu Apr 6 09:56:23 CEST 2006
184 //
185 //
186 
187 //
188 // constructors and destructor
189 //
190 template <class Container, class Base, class Helper>
192  : m_config(iConfig), m_helper(iConfig, consumesCollector()) {
195 
196  token_primaryVertex = consumes<reco::VertexCollection>(m_config.getParameter<edm::InputTag>("primaryVertex"));
198  esConsumes<TransientTrackBuilder, TransientTrackRecord>(edm::ESInputTag("", "TransientTrackBuilder"));
199  token_calib2D = esConsumes<TrackProbabilityCalibration, BTagTrackProbability2DRcd>();
200  token_calib3D = esConsumes<TrackProbabilityCalibration, BTagTrackProbability3DRcd>();
201 
202  m_computeProbabilities = m_config.getParameter<bool>("computeProbabilities");
203  m_computeGhostTrack = m_config.getParameter<bool>("computeGhostTrack");
204  m_ghostTrackPriorDeltaR = m_config.getParameter<double>("ghostTrackPriorDeltaR");
205  m_cutPixelHits = m_config.getParameter<int>("minimumNumberOfPixelHits");
206  m_cutTotalHits = m_config.getParameter<int>("minimumNumberOfHits");
207  m_cutMaxTIP = m_config.getParameter<double>("maximumTransverseImpactParameter");
208  m_cutMinPt = m_config.getParameter<double>("minimumTransverseMomentum");
209  m_cutMaxChiSquared = m_config.getParameter<double>("maximumChiSquared");
210  m_cutMaxLIP = m_config.getParameter<double>("maximumLongitudinalImpactParameter");
211  m_directionWithTracks = m_config.getParameter<bool>("jetDirectionUsingTracks");
212  m_directionWithGhostTrack = m_config.getParameter<bool>("jetDirectionUsingGhostTrack");
213  m_useTrackQuality = m_config.getParameter<bool>("useTrackQuality");
214 
216  produces<reco::TrackCollection>("ghostTracks");
217  produces<Product>();
218 }
219 
220 template <class Container, class Base, class Helper>
222 
223 //
224 // member functions
225 //
226 // ------------ method called to produce the data ------------
227 template <class Container, class Base, class Helper>
229  // Update probability estimator if event setup is changed
230  if (m_computeProbabilities)
231  checkEventSetup(iSetup);
232 
234  iEvent.getByToken(token_primaryVertex, primaryVertex);
235 
236  edm::ESHandle<TransientTrackBuilder> builder = iSetup.getHandle(token_trackBuilder);
237  // m_algo.setTransientTrackBuilder(builder.product());
238 
239  // output collections
240  auto result = std::make_unique<Product>();
241 
242  std::unique_ptr<reco::TrackCollection> ghostTracks;
243  reco::TrackRefProd ghostTrackRefProd;
244  if (m_computeGhostTrack) {
245  ghostTracks = std::make_unique<reco::TrackCollection>();
246  ghostTrackRefProd = iEvent.getRefBeforePut<reco::TrackCollection>("ghostTracks");
247  }
248 
249  // use first pv of the collection
251  const reco::Vertex* pv = &dummy;
253  if (!primaryVertex->empty()) {
254  pv = &*primaryVertex->begin();
255  // we always use the first vertex (at the moment)
257  } else { // create a dummy PV
259  e(0, 0) = 0.0015 * 0.0015;
260  e(1, 1) = 0.0015 * 0.0015;
261  e(2, 2) = 15. * 15.;
262  reco::Vertex::Point p(0, 0, 0);
263  dummy = reco::Vertex(p, e, 0, 0, 0);
264  }
265 
266  std::vector<Base> baseTagInfos = m_helper.makeBaseVector(iEvent);
267  for (typename std::vector<Base>::const_iterator it = baseTagInfos.begin(); it != baseTagInfos.end(); it++) {
268  Container tracks = m_helper.tracks(*it);
269  math::XYZVector jetMomentum = it->jet()->momentum();
270 
271  if (m_directionWithTracks) {
272  jetMomentum *= 0.5;
273  for (typename Container::const_iterator itTrack = tracks.begin(); itTrack != tracks.end(); ++itTrack)
274  if (reco::btag::toTrack(*itTrack)->numberOfValidHits() >= m_cutTotalHits) //minimal quality cuts
275  jetMomentum += (*itTrack)->momentum();
276  }
277 
279  std::vector<reco::TransientTrack> transientTracks;
280 
281  for (typename Container::const_iterator itTrack = tracks.begin(); itTrack != tracks.end(); ++itTrack) {
282  reco::TransientTrack transientTrack = builder->build(*itTrack);
283  const reco::Track& track = transientTrack.track(); //**itTrack;
284  /* cout << " pt " << track.pt() <<
285  " d0 " << fabs(track.d0()) <<
286  " #hit " << track.hitPattern().numberOfValidHits()<<
287  " ipZ " << fabs(track.dz()-pv->z())<<
288  " chi2 " << track.normalizedChi2()<<
289  " #pixel " << track.hitPattern().numberOfValidPixelHits()<< endl;
290 */
291  if (track.pt() > m_cutMinPt &&
292  track.hitPattern().numberOfValidHits() >= m_cutTotalHits && // min num tracker hits
293  track.hitPattern().numberOfValidPixelHits() >= m_cutPixelHits &&
294  track.normalizedChi2() < m_cutMaxChiSquared && std::abs(track.dxy(pv->position())) < m_cutMaxTIP &&
295  std::abs(track.dz(pv->position())) < m_cutMaxLIP) {
296  // std::cout << "selected" << std::endl;
297  selectedTracks.push_back(*itTrack);
298  transientTracks.push_back(transientTrack);
299  }
300  }
301  // std::cout <<"SIZE: " << transientTracks.size() << std::endl;
302  GlobalVector direction(jetMomentum.x(), jetMomentum.y(), jetMomentum.z());
303 
304  std::unique_ptr<reco::GhostTrack> ghostTrack;
305  reco::TrackRef ghostTrackRef;
306  if (m_computeGhostTrack) {
307  reco::GhostTrackFitter fitter;
308  GlobalPoint origin = RecoVertex::convertPos(pv->position());
310  ghostTrack.reset(
311  new reco::GhostTrack(fitter.fit(origin, error, direction, m_ghostTrackPriorDeltaR, transientTracks)));
312 
313  /*
314  if (std::sqrt(jetMomentum.Perp2()) > 30) {
315  double offset = ghostTrack->prediction().lambda(origin);
316  std::cout << "------------------ jet pt " << std::sqrt(jetMomentum.Perp2()) << std::endl;
317  const std::vector<GhostTrackState> *states = &ghostTrack->states();
318  for(std::vector<GhostTrackState>::const_iterator state = states->begin();
319  state != states->end(); ++state) {
320  double dist = state->lambda() - offset;
321  double err = state->lambdaError(ghostTrack->prediction(), error);
322  double ipSig = IPTools::signedImpactParameter3D(state->track(), direction, *pv).second.significance();
323  double axisDist = state->axisDistance(ghostTrack->prediction());
324  std::cout << state->track().impactPointState().freeState()->momentum().perp()
325  << ": " << dist << "/" << err << " [" << (dist / err) << "], ipsig = " << ipSig << ", dist = " << axisDist << ", w = " << state->weight() << std::endl;
326  }
327  }
328 */
329  ghostTrackRef = reco::TrackRef(ghostTrackRefProd, ghostTracks->size());
330  ghostTracks->push_back(*ghostTrack);
331 
332  if (m_directionWithGhostTrack) {
333  const reco::GhostTrackPrediction& pred = ghostTrack->prediction();
334  double lambda = pred.lambda(origin);
337  0,
338  0,
339  0);
340  pv = &dummy;
341  direction = pred.direction();
342  }
343  }
344 
345  std::vector<float> prob2D, prob3D;
346  std::vector<reco::btag::TrackIPData> ipData;
347 
348  for (unsigned int ind = 0; ind < transientTracks.size(); ind++) {
349  const reco::TransientTrack& transientTrack = transientTracks[ind];
350  const reco::Track& track = transientTrack.track();
351 
352  reco::btag::TrackIPData trackIP;
353  trackIP.ip3d = IPTools::signedImpactParameter3D(transientTrack, direction, *pv).second;
354  trackIP.ip2d = IPTools::signedTransverseImpactParameter(transientTrack, direction, *pv).second;
355 
356  TrajectoryStateOnSurface closest =
357  IPTools::closestApproachToJet(transientTrack.impactPointState(), *pv, direction, transientTrack.field());
358  if (closest.isValid())
359  trackIP.closestToJetAxis = closest.globalPosition();
360 
361  // TODO: cross check if it is the same using other methods
362  trackIP.distanceToJetAxis = IPTools::jetTrackDistance(transientTrack, direction, *pv).second;
363 
364  if (ghostTrack.get()) {
365  const std::vector<reco::GhostTrackState>& states = ghostTrack->states();
366  std::vector<reco::GhostTrackState>::const_iterator pos =
367  std::find_if(states.begin(), states.end(), [&](auto& arg) { return arg.track() == transientTrack; });
368 
369  if (pos != states.end() && pos->isValid()) {
370  VertexDistance3D dist;
371  const reco::GhostTrackPrediction& pred = ghostTrack->prediction();
372  GlobalPoint p1 = pos->tsos().globalPosition();
373  GlobalError e1 = pos->tsos().cartesianError().position();
374  GlobalPoint p2 = pred.position(pos->lambda());
375  GlobalError e2 = pred.positionError(pos->lambda());
376  trackIP.closestToGhostTrack = p1;
377  trackIP.distanceToGhostTrack = dist.distance(VertexState(p1, e1), VertexState(p2, e2));
378  trackIP.ghostTrackWeight = pos->weight();
379  } else {
380  trackIP.distanceToGhostTrack = Measurement1D(0., -1.);
381  trackIP.ghostTrackWeight = 0.;
382  }
383  } else {
384  trackIP.distanceToGhostTrack = Measurement1D(0., -1.);
385  trackIP.ghostTrackWeight = 1.;
386  }
387 
388  ipData.push_back(trackIP);
389 
390  if (m_computeProbabilities) {
391  //probability with 3D ip
392  std::pair<bool, double> probability = m_probabilityEstimator->probability(
393  m_useTrackQuality, 0, ipData.back().ip3d.significance(), track, *(it->jet()), *pv);
394  prob3D.push_back(probability.first ? probability.second : -1.);
395 
396  //probability with 2D ip
397  probability = m_probabilityEstimator->probability(
398  m_useTrackQuality, 1, ipData.back().ip2d.significance(), track, *(it->jet()), *pv);
399  prob2D.push_back(probability.first ? probability.second : -1.);
400  }
401  }
402 
403  result->push_back(
404  typename Product::value_type(ipData, prob2D, prob3D, selectedTracks, *it, pvRef, direction, ghostTrackRef));
405  }
406 
407  if (m_computeGhostTrack)
408  iEvent.put(std::move(ghostTracks), "ghostTracks");
409  iEvent.put(std::move(result));
410 }
411 
418 
419 template <class Container, class Base, class Helper>
423  unsigned long long cacheId2D = re2D.cacheIdentifier();
424  unsigned long long cacheId3D = re3D.cacheIdentifier();
425 
426  if (cacheId2D != m_calibrationCacheId2D || cacheId3D != m_calibrationCacheId3D) //Calibration changed
427  {
428  //iSetup.get<BTagTrackProbabilityRcd>().get(calib);
429  edm::ESHandle<TrackProbabilityCalibration> calib2DHandle = iSetup.getHandle(token_calib2D);
430  edm::ESHandle<TrackProbabilityCalibration> calib3DHandle = iSetup.getHandle(token_calib3D);
431 
432  const TrackProbabilityCalibration* ca2D = calib2DHandle.product();
433  const TrackProbabilityCalibration* ca3D = calib3DHandle.product();
434 
435  m_probabilityEstimator.reset(new HistogramProbabilityEstimator(ca3D, ca2D));
436  }
437  m_calibrationCacheId3D = cacheId3D;
438  m_calibrationCacheId2D = cacheId2D;
439 }
440 
441 // Specialized templates used to fill 'descriptions'
442 // ------------ method fills 'descriptions' with the allowed parameters for the module ------------
443 template <>
445  edm::ConfigurationDescriptions& descriptions) {
447  desc.add<double>("maximumTransverseImpactParameter", 0.2);
448  desc.add<int>("minimumNumberOfHits", 8);
449  desc.add<double>("minimumTransverseMomentum", 1.0);
450  desc.add<edm::InputTag>("primaryVertex", edm::InputTag("offlinePrimaryVertices"));
451  desc.add<double>("maximumLongitudinalImpactParameter", 17.0);
452  desc.add<bool>("computeGhostTrack", true);
453  desc.add<double>("ghostTrackPriorDeltaR", 0.03);
454  desc.add<edm::InputTag>("jetTracks", edm::InputTag("ak4JetTracksAssociatorAtVertexPF"));
455  desc.add<bool>("jetDirectionUsingGhostTrack", false);
456  desc.add<int>("minimumNumberOfPixelHits", 2);
457  desc.add<bool>("jetDirectionUsingTracks", false);
458  desc.add<bool>("computeProbabilities", true);
459  desc.add<bool>("useTrackQuality", false);
460  desc.add<double>("maximumChiSquared", 5.0);
461  descriptions.addDefault(desc);
462 }
463 
464 template <>
466  edm::ConfigurationDescriptions& descriptions) {
468  desc.add<double>("maximumTransverseImpactParameter", 0.2);
469  desc.add<int>("minimumNumberOfHits", 8);
470  desc.add<double>("minimumTransverseMomentum", 1.0);
471  desc.add<edm::InputTag>("primaryVertex", edm::InputTag("offlinePrimaryVertices"));
472  desc.add<double>("maximumLongitudinalImpactParameter", 17.0);
473  desc.add<bool>("computeGhostTrack", true);
474  desc.add<double>("maxDeltaR", 0.4);
475  desc.add<edm::InputTag>("candidates", edm::InputTag("particleFlow"));
476  desc.add<bool>("jetDirectionUsingGhostTrack", false);
477  desc.add<int>("minimumNumberOfPixelHits", 2);
478  desc.add<bool>("jetDirectionUsingTracks", false);
479  desc.add<bool>("computeProbabilities", true);
480  desc.add<bool>("useTrackQuality", false);
481  desc.add<edm::InputTag>("jets", edm::InputTag("ak4PFJetsCHS"));
482  desc.add<double>("ghostTrackPriorDeltaR", 0.03);
483  desc.add<double>("maximumChiSquared", 5.0);
484  desc.addOptional<bool>("explicitJTA", false);
485  descriptions.addDefault(desc);
486 }
487 
488 #endif
Vector3DBase
Definition: Vector3DBase.h:8
reco::JTATagInfo::tracks
TrackRefVector tracks(void) const override
returns a list of tracks associated to the jet
Definition: JTATagInfo.h:20
ConfigurationDescriptions.h
edm::RefProd< TrackCollection >
reco::btag::TrackIPData::distanceToJetAxis
Measurement1D distanceToJetAxis
Definition: IPTagInfo.h:33
edm::ESHandle::product
T const * product() const
Definition: ESHandle.h:86
GhostTrackPrediction.h
JetTracksAssociation.h
TrackProbabilityCalibration.h
JetTag.h
Measurement1D
Definition: Measurement1D.h:11
electrons_cff.bool
bool
Definition: electrons_cff.py:366
mps_fire.i
i
Definition: mps_fire.py:428
edm::ESInputTag
Definition: ESInputTag.h:87
BTagTrackProbability3DRcd.h
HLT_FULL_cff.track
track
Definition: HLT_FULL_cff.py:11713
edm::eventsetup::EventSetupRecord
Definition: EventSetupRecord.h:83
funct::false
false
Definition: Factorize.h:29
IPProducerHelpers
Definition: IPProducer.h:59
TrackProbabilityCalibration
Definition: TrackProbabilityCalibration.h:11
configurableAnalysis::Candidate
char Candidate[]
Definition: modules.cc:20
reco::GhostTrackPrediction::positionError
GlobalError positionError(double lambda=0.) const
Definition: GhostTrackPrediction.cc:131
ESHandle.h
IPProducer::m_cutPixelHits
int m_cutPixelHits
Definition: IPProducer.h:157
edm::RefToBase::key
size_t key() const
Definition: RefToBase.h:219
sistrip::View
View
Definition: ConstantsForView.h:26
reco::btag::toTrack
const reco::Track * toTrack(const reco::TrackBaseRef &t)
Definition: IPTagInfo.h:24
edm::EDGetTokenT
Definition: EDGetToken.h:33
edm
HLT enums.
Definition: AlignableModifier.h:19
reco::Vertex::Error
math::Error< dimension >::type Error
covariance error matrix (3x3)
Definition: Vertex.h:44
AlCaHLTBitMon_ParallelJobs.p
p
Definition: AlCaHLTBitMon_ParallelJobs.py:153
GhostTrackFitter.h
TrajectoryStateOnSurface::globalPosition
GlobalPoint globalPosition() const
Definition: TrajectoryStateOnSurface.h:65
VertexDistance3D::distance
Measurement1D distance(const GlobalPoint &vtx1Position, const GlobalError &vtx1PositionError, const GlobalPoint &vtx2Position, const GlobalError &vtx2PositionError) const override
Definition: VertexDistance3D.cc:17
pos
Definition: PixelAliasList.h:18
HLT_FULL_cff.InputTag
InputTag
Definition: HLT_FULL_cff.py:89281
ConvertError.h
edm::ParameterSetDescription
Definition: ParameterSetDescription.h:52
IPProducer::token_trackBuilder
edm::ESGetToken< TransientTrackBuilder, TransientTrackRecord > token_trackBuilder
Definition: IPProducer.h:145
reco::btag::TrackIPData::closestToGhostTrack
GlobalPoint closestToGhostTrack
Definition: IPTagInfo.h:30
IPProducerHelpers::FromJTA
Definition: IPProducer.h:60
IPProducer::m_useDB
bool m_useDB
Definition: IPProducer.h:155
IPProducer::m_config
const edm::ParameterSet & m_config
Definition: IPProducer.h:143
IPProducer
Definition: IPProducer.h:130
EDProducer.h
IPTools::closestApproachToJet
TrajectoryStateOnSurface closestApproachToJet(const TrajectoryStateOnSurface &state, const reco::Vertex &vertex, const GlobalVector &aJetDirection, const MagneticField *field)
Definition: IPTools.cc:182
ConvertToFromReco.h
IPProducerHelpers::FromJTA::makeBaseVector
std::vector< reco::JTATagInfo > makeBaseVector(const edm::Event &iEvent)
Definition: IPProducer.h:66
IPProducer::m_directionWithTracks
bool m_directionWithTracks
Definition: IPProducer.h:163
singleTopDQM_cfi.jets
jets
Definition: singleTopDQM_cfi.py:42
VertexDistance3D.h
edm::RefVector< TrackCollection >
GhostTrackState.h
reco
fixed size matrix
Definition: AlignmentAlgorithmBase.h:45
IPTools::signedTransverseImpactParameter
std::pair< bool, Measurement1D > signedTransverseImpactParameter(const reco::TransientTrack &track, const GlobalVector &direction, const reco::Vertex &vertex)
Definition: IPTools.cc:57
IPProducerHelpers::FromJetAndCands::maxDeltaR
double maxDeltaR
Definition: IPProducer.h:125
IPProducer::IPProducer
IPProducer(const edm::ParameterSet &)
Definition: IPProducer.h:191
edm::Handle
Definition: AssociativeIterator.h:50
IPProducerHelpers::FromJTA::FromJTA
FromJTA(const edm::ParameterSet &iConfig, edm::ConsumesCollector &&iC)
Definition: IPProducer.h:62
relativeConstraints.error
error
Definition: relativeConstraints.py:53
reco::TrackBase::numberOfValidHits
unsigned short numberOfValidHits() const
number of valid hits found
Definition: TrackBase.h:798
reco::JetTagInfo::jet
edm::RefToBase< Jet > jet(void) const override
returns a polymorphic reference to the tagged jet
Definition: JetTagInfo.h:22
IPProducer::m_computeGhostTrack
bool m_computeGhostTrack
Definition: IPProducer.h:150
ESGetToken.h
IPProducerHelpers::FromJTA::tracks
reco::TrackRefVector tracks(const reco::JTATagInfo &it)
Definition: IPProducer.h:65
reco::JetExtendedAssociation::Container
edm::AssociationVector< reco::JetRefBaseProd, Values > Container
Definition: JetExtendedAssociation.h:29
edm::Ref
Definition: AssociativeIterator.h:58
EventSetupRecord.h
IPProducer::produce
void produce(edm::Event &, const edm::EventSetup &) override
Definition: IPProducer.h:228
BeamMonitor_cff.primaryVertex
primaryVertex
hltOfflineBeamSpot for HLTMON
Definition: BeamMonitor_cff.py:7
IPProducerHelpers::FromJetAndCands::FromJetAndCands
FromJetAndCands(const edm::ParameterSet &iConfig, edm::ConsumesCollector &&iC, const std::string &jets="jets")
Definition: IPProducer.h:84
TrajectoryStateOnSurface
Definition: TrajectoryStateOnSurface.h:16
MakerMacros.h
BTagTrackProbability3DRcd
Definition: BTagTrackProbability3DRcd.h:24
IPProducer::~IPProducer
~IPProducer() override
Definition: IPProducer.h:221
reco::GhostTrackPrediction::prediction
const Vector & prediction() const
Definition: GhostTrackPrediction.h:59
Track.h
reco::btag::TrackIPData::ghostTrackWeight
float ghostTrackWeight
Definition: IPTagInfo.h:35
edm::EventSetup::get
T get() const
Definition: EventSetup.h:87
Jet
Definition: Jet.py:1
IPTools::signedImpactParameter3D
std::pair< bool, Measurement1D > signedImpactParameter3D(const reco::TransientTrack &track, const GlobalVector &direction, const reco::Vertex &vertex)
Definition: IPTools.cc:81
IPProducer::fillDescriptions
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
edm::AssociationVector::begin
const_iterator begin() const
Definition: AssociationVector.h:108
fillDescriptions
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
IPProducerHelpers::FromJetAndCands::m_map
std::vector< std::vector< reco::CandidatePtr > > m_map
Definition: IPProducer.h:122
reco::JetTagInfo
Definition: JetTagInfo.h:9
TrackIPTagInfo.h
reco::Track
Definition: Track.h:27
edm::ESHandle< TransientTrackBuilder >
p2
double p2[4]
Definition: TauolaWrapper.h:90
HistogramProbabilityEstimator.h
reco::btag::TrackIPData::closestToJetAxis
GlobalPoint closestToJetAxis
Definition: IPTagInfo.h:29
IPProducerHelpers::FromJTA::token_associator
edm::EDGetTokenT< reco::JetTracksAssociationCollection > token_associator
Definition: IPProducer.h:80
VertexState.h
VertexDistance3D
Definition: VertexDistance3D.h:13
edm::AssociationVector::end
const_iterator end() const
Definition: AssociationVector.h:109
Point3DBase< float, GlobalTag >
ParameterSetDescription.h
EventSetupRecordImplementation.h
edm::ConfigurationDescriptions
Definition: ConfigurationDescriptions.h:28
reco::TrackRef
edm::Ref< TrackCollection > TrackRef
persistent reference to a Track
Definition: TrackFwd.h:20
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
IPTools::jetTrackDistance
std::pair< double, Measurement1D > jetTrackDistance(const reco::TransientTrack &track, const GlobalVector &direction, const reco::Vertex &vertex)
Definition: IPTools.cc:206
IPProducer::m_computeProbabilities
bool m_computeProbabilities
Definition: IPProducer.h:149
reco::GhostTrackFitter::fit
GhostTrack fit(const GlobalPoint &priorPosition, const GlobalError &priorError, const GlobalVector &direction, double coneRadius, const std::vector< TransientTrack > &tracks) const
Definition: GhostTrackFitter.cc:30
reco::JetTracksAssociationCollection
JetTracksAssociation::Container JetTracksAssociationCollection
typedefs for backward compatibility
Definition: JetTracksAssociation.h:60
HLT_FULL_cff.cands
cands
Definition: HLT_FULL_cff.py:15144
TransientTrackBuilder.h
edm::ParameterSet
Definition: ParameterSet.h:47
IPProducerHelpers::FromJetAndCands::token_cands
edm::EDGetTokenT< edm::View< reco::Candidate > > token_cands
Definition: IPProducer.h:124
RecoVertex::convertError
reco::Vertex::Error convertError(const GlobalError &ge)
Definition: ConvertError.h:8
IPProducer::m_calibrationCacheId2D
unsigned long long m_calibrationCacheId2D
Definition: IPProducer.h:153
reco::GhostTrackPrediction::direction
const GlobalVector direction() const
Definition: GhostTrackPrediction.h:63
Event.h
tracks
const uint32_t *__restrict__ const HitContainer *__restrict__ TkSoA *__restrict__ tracks
Definition: CAHitNtupletGeneratorKernelsImpl.h:159
reco::GhostTrackPrediction::position
GlobalPoint position(double lambda=0.) const
Definition: GhostTrackPrediction.h:67
IPProducer::token_calib2D
edm::ESGetToken< TrackProbabilityCalibration, BTagTrackProbability2DRcd > token_calib2D
Definition: IPProducer.h:146
StorageManager_cfg.e1
e1
Definition: StorageManager_cfg.py:16
math::XYZVector
XYZVectorD XYZVector
spatial vector with cartesian internal representation
Definition: Vector3D.h:31
IPProducerHelpers::FromJetAndCands::makeBaseVector
std::vector< reco::JetTagInfo > makeBaseVector(const edm::Event &iEvent)
Definition: IPProducer.h:91
IPProducer::m_cutMaxLIP
double m_cutMaxLIP
Definition: IPProducer.h:162
BTagTrackProbability2DRcd.h
reco::GhostTrack
Definition: GhostTrack.h:16
reco::TransientTrack::impactPointState
TrajectoryStateOnSurface impactPointState() const
Definition: TransientTrack.h:98
IPProducer::m_directionWithGhostTrack
bool m_directionWithGhostTrack
Definition: IPProducer.h:164
MetAnalyzer.pv
def pv(vc)
Definition: MetAnalyzer.py:7
iEvent
int iEvent
Definition: GenABIO.cc:224
IPProducer::token_calib3D
edm::ESGetToken< TrackProbabilityCalibration, BTagTrackProbability3DRcd > token_calib3D
Definition: IPProducer.h:147
edm::AssociationVector::const_iterator
transient_vector_type::const_iterator const_iterator
Definition: AssociationVector.h:106
edm::EventSetup::getHandle
ESHandle< T > getHandle(const ESGetToken< T, R > &iToken) const
Definition: EventSetup.h:155
edm::stream::EDProducer
Definition: EDProducer.h:38
p1
double p1[4]
Definition: TauolaWrapper.h:89
GlobalErrorBase< double, ErrorMatrixTag >
HistogramProbabilityEstimator
Definition: HistogramProbabilityEstimator.h:18
edm::EventSetup
Definition: EventSetup.h:58
reco::JetExtendedAssociation::value_type
Container::value_type value_type
Definition: JetExtendedAssociation.h:30
IPProducer::m_cutMinPt
double m_cutMinPt
Definition: IPProducer.h:160
TransientTrackRecord.h
IPProducer::m_calibrationCacheId3D
unsigned long long m_calibrationCacheId3D
Definition: IPProducer.h:154
IPProducer::m_cutMaxChiSquared
double m_cutMaxChiSquared
Definition: IPProducer.h:161
IPProducerHelpers::FromJetAndCands::tracks
const std::vector< reco::CandidatePtr > & tracks(const reco::JetTagInfo &it)
Definition: IPProducer.h:90
IPProducerHelpers::FromJetAndCands::token_jets
edm::EDGetTokenT< edm::View< reco::Jet > > token_jets
Definition: IPProducer.h:123
reco::TransientTrack::field
const MagneticField * field() const
Definition: TransientTrack.h:110
edm::ESGetToken< TransientTrackBuilder, TransientTrackRecord >
reco::btag::TrackIPData::distanceToGhostTrack
Measurement1D distanceToGhostTrack
Definition: IPTagInfo.h:34
InputTag.h
reco::GhostTrackFitter
Definition: GhostTrackFitter.h:19
IPProducer::m_cutMaxTIP
double m_cutMaxTIP
Definition: IPProducer.h:159
submitPVResolutionJobs.desc
string desc
Definition: submitPVResolutionJobs.py:251
reco::Vertex::Point
math::XYZPoint Point
point in the space
Definition: Vertex.h:40
eostools.move
def move(src, dest)
Definition: eostools.py:511
IPTools.h
HltBtagValidation_cff.Vertex
Vertex
Definition: HltBtagValidation_cff.py:32
reco::TransientTrack
Definition: TransientTrack.h:19
reco::TransientTrack::track
const Track & track() const
Definition: TransientTrack.h:117
HLTMuonOfflineAnalyzer_cfi.deltaR2
deltaR2
Definition: HLTMuonOfflineAnalyzer_cfi.py:105
Frameworkfwd.h
VertexState
Definition: VertexState.h:13
reco::JTATagInfo
Definition: JTATagInfo.h:10
IPProducer::m_helper
Helper m_helper
Definition: IPProducer.h:166
reco::btag::TrackIPData::ip2d
Measurement1D ip2d
Definition: IPTagInfo.h:31
EventSetup.h
edm::ParameterSet::getParameter
T getParameter(std::string const &) const
Definition: ParameterSet.h:303
edm::RefToBase< reco::Jet >
reco::btag::TrackIPData::ip3d
Measurement1D ip3d
Definition: IPTagInfo.h:32
IPProducer::m_cutTotalHits
int m_cutTotalHits
Definition: IPProducer.h:158
edm::View::const_iterator
boost::indirect_iterator< typename seq_t::const_iterator > const_iterator
Definition: View.h:86
IPProducer::checkEventSetup
void checkEventSetup(const edm::EventSetup &iSetup)
Definition: IPProducer.h:420
GhostTrack.h
RecoVertex::convertPos
reco::Vertex::Point convertPos(const GlobalPoint &p)
Definition: ConvertToFromReco.h:7
funct::arg
A arg
Definition: Factorize.h:31
TransientTrackBuilder::build
reco::TransientTrack build(const reco::Track *p) const
Definition: TransientTrackBuilder.cc:20
reco::GhostTrackPrediction
Definition: GhostTrackPrediction.h:21
IPProducer::Product
std::vector< reco::IPTagInfo< Container, Base > > Product
Definition: IPProducer.h:132
IPProducer::m_useTrackQuality
bool m_useTrackQuality
Definition: IPProducer.h:165
mps_fire.result
result
Definition: mps_fire.py:311
ConsumesCollector.h
Candidate.h
funct::abs
Abs< T >::type abs(const T &t)
Definition: Abs.h:22
edm::eventsetup::EventSetupRecord::cacheIdentifier
unsigned long long cacheIdentifier() const
Definition: EventSetupRecord.h:187
View.h
ParameterSet.h
IPProducerHelpers::FromJetAndCands::explicitJTA
bool explicitJTA
Definition: IPProducer.h:126
dummy
Definition: DummySelector.h:38
EventSetupRecordKey.h
dqmiolumiharvest.j
j
Definition: dqmiolumiharvest.py:66
edm::Event
Definition: Event.h:73
edm::ConfigurationDescriptions::addDefault
void addDefault(ParameterSetDescription const &psetDescription)
Definition: ConfigurationDescriptions.cc:99
JTATagInfo.h
IPProducer::m_probabilityEstimator
std::unique_ptr< HistogramProbabilityEstimator > m_probabilityEstimator
Definition: IPProducer.h:152
BTagTrackProbability2DRcd
Definition: BTagTrackProbability2DRcd.h:24
edm::InputTag
Definition: InputTag.h:15
reco::TrackCollection
std::vector< Track > TrackCollection
collection of Tracks
Definition: TrackFwd.h:14
edm::ConsumesCollector
Definition: ConsumesCollector.h:45
JetTagInfo.h
reco::Vertex
Definition: Vertex.h:35
TrajectoryStateOnSurface::isValid
bool isValid() const
Definition: TrajectoryStateOnSurface.h:54
IPProducer::token_primaryVertex
edm::EDGetTokenT< reco::VertexCollection > token_primaryVertex
Definition: IPProducer.h:144
IPProducerHelpers::FromJetAndCands
Definition: IPProducer.h:82
TrackCollections2monitor_cff.selectedTracks
selectedTracks
Definition: TrackCollections2monitor_cff.py:32
IPProducer::m_ghostTrackPriorDeltaR
double m_ghostTrackPriorDeltaR
Definition: IPProducer.h:151
reco::btag::TrackIPData
Definition: IPTagInfo.h:28
MillePedeFileConverter_cfg.e
e
Definition: MillePedeFileConverter_cfg.py:37
reco::GhostTrackPrediction::lambda
double lambda(const GlobalPoint &point) const
Definition: GhostTrackPrediction.h:65