CMS 3D CMS Logo

ParticleNetFeatureEvaluator.cc
Go to the documentation of this file.
1 #include <TVector3.h>
2 #include <TTree.h>
3 
5 
14 
22 
27 
31 
32 using namespace btagbtvdeep;
33 
35 public:
36  explicit ParticleNetFeatureEvaluator(const edm::ParameterSet &);
37  ~ParticleNetFeatureEvaluator() override;
38 
39  static void fillDescriptions(edm::ConfigurationDescriptions &descriptions);
40 
41 private:
42  void beginStream(edm::StreamID) override {}
43  void produce(edm::Event &, const edm::EventSetup &) override;
44  void endStream() override {}
45  void fillParticleFeatures(DeepBoostedJetFeatures &fts,
46  const reco::Jet &jet,
47  const std::vector<math::XYZTLorentzVector> &tau_pfcandidates,
51  void fillSVFeatures(DeepBoostedJetFeatures &fts, const reco::Jet &jet);
52  void fillLostTrackFeatures(DeepBoostedJetFeatures &fts, const reco::Jet &jet);
53  bool useTrackProperties(const pat::PackedCandidate *cand);
54 
55  const double jet_radius_;
56  const double min_jet_pt_;
57  const double max_jet_eta_;
58  const double min_jet_eta_;
61  const double min_pt_for_losttrack_;
62  const double max_dr_for_losttrack_;
63  const double min_pt_for_taus_;
64  const double max_eta_for_taus_;
65  const bool include_neutrals_;
66  const bool flip_ip_sign_;
69  const double max_sip3dsig_for_flip_;
70 
82 
89 
90  const static std::vector<std::string> particle_features_;
91  const static std::vector<std::string> sv_features_;
92  const static std::vector<std::string> losttrack_features_;
93  const reco::Vertex *pv_ = nullptr;
94 
95  TTree *tree;
96  unsigned int event;
97  float jet_pt;
98  float jet_pt_raw;
99  float jet_eta;
100  float jet_phi;
101  float jet_mass;
102  unsigned int ijet;
103  std::vector<float> jet_pfcand_pt_log;
104  std::vector<float> jet_pfcand_energy_log;
105  std::vector<float> jet_pfcand_deta;
106  std::vector<float> jet_pfcand_dphi;
107  std::vector<float> jet_pfcand_eta;
108  std::vector<float> jet_pfcand_charge;
109  std::vector<float> jet_pfcand_frompv;
110  std::vector<float> jet_pfcand_nlostinnerhits;
111  std::vector<float> jet_pfcand_track_chi2;
112  std::vector<float> jet_pfcand_track_qual;
113  std::vector<float> jet_pfcand_dz;
114  std::vector<float> jet_pfcand_dzsig;
115  std::vector<float> jet_pfcand_dxy;
116  std::vector<float> jet_pfcand_dxysig;
117  std::vector<float> jet_pfcand_etarel;
118  std::vector<float> jet_pfcand_pperp_ratio;
119  std::vector<float> jet_pfcand_ppara_ratio;
120  std::vector<float> jet_pfcand_trackjet_d3d;
121  std::vector<float> jet_pfcand_trackjet_d3dsig;
122  std::vector<float> jet_pfcand_trackjet_dist;
123  std::vector<float> jet_pfcand_npixhits;
124  std::vector<float> jet_pfcand_nstriphits;
125  std::vector<float> jet_pfcand_trackjet_decayL;
126  std::vector<float> jet_pfcand_id;
127  std::vector<float> jet_pfcand_calofraction;
128  std::vector<float> jet_pfcand_hcalfraction;
129  std::vector<float> jet_pfcand_puppiw;
130  std::vector<float> jet_pfcand_muon_id;
131  std::vector<float> jet_pfcand_muon_isglobal;
132  std::vector<float> jet_pfcand_muon_chi2;
133  std::vector<float> jet_pfcand_muon_segcomp;
134  std::vector<float> jet_pfcand_muon_nvalidhit;
135  std::vector<float> jet_pfcand_muon_nstation;
136  std::vector<float> jet_pfcand_electron_detaIn;
137  std::vector<float> jet_pfcand_electron_dphiIn;
140  std::vector<float> jet_pfcand_electron_r9;
141  std::vector<float> jet_pfcand_electron_convProb;
142  std::vector<float> jet_pfcand_photon_sigIetaIeta;
143  std::vector<float> jet_pfcand_photon_r9;
144  std::vector<float> jet_pfcand_photon_eVeto;
145  std::vector<float> jet_pfcand_tau_signal;
146  std::vector<float> jet_sv_pt_log;
147  std::vector<float> jet_sv_mass;
148  std::vector<float> jet_sv_deta;
149  std::vector<float> jet_sv_dphi;
150  std::vector<float> jet_sv_eta;
151  std::vector<float> jet_sv_ntrack;
152  std::vector<float> jet_sv_chi2;
153  std::vector<float> jet_sv_dxy;
154  std::vector<float> jet_sv_dxysig;
155  std::vector<float> jet_sv_d3d;
156  std::vector<float> jet_sv_d3dsig;
157  std::vector<float> jet_losttrack_pt_log;
158  std::vector<float> jet_losttrack_eta;
159  std::vector<float> jet_losttrack_deta;
160  std::vector<float> jet_losttrack_dphi;
161  std::vector<float> jet_losttrack_charge;
162  std::vector<float> jet_losttrack_frompv;
163  std::vector<float> jet_losttrack_track_chi2;
164  std::vector<float> jet_losttrack_track_qual;
165  std::vector<float> jet_losttrack_dz;
166  std::vector<float> jet_losttrack_dxy;
167  std::vector<float> jet_losttrack_dzsig;
168  std::vector<float> jet_losttrack_dxysig;
169  std::vector<float> jet_losttrack_etarel;
170  std::vector<float> jet_losttrack_trackjet_d3d;
171  std::vector<float> jet_losttrack_trackjet_d3dsig;
172  std::vector<float> jet_losttrack_trackjet_dist;
173  std::vector<float> jet_losttrack_trackjet_decayL;
174  std::vector<float> jet_losttrack_npixhits;
175  std::vector<float> jet_losttrack_nstriphits;
176 };
177 
178 const std::vector<std::string> ParticleNetFeatureEvaluator::particle_features_{"jet_pfcand_pt_log",
179  "jet_pfcand_energy_log",
180  "jet_pfcand_deta",
181  "jet_pfcand_dphi",
182  "jet_pfcand_eta",
183  "jet_pfcand_charge",
184  "jet_pfcand_frompv",
185  "jet_pfcand_nlostinnerhits",
186  "jet_pfcand_track_chi2",
187  "jet_pfcand_track_qual",
188  "jet_pfcand_dz",
189  "jet_pfcand_dzsig",
190  "jet_pfcand_dxy",
191  "jet_pfcand_dxysig",
192  "jet_pfcand_etarel",
193  "jet_pfcand_pperp_ratio",
194  "jet_pfcand_ppara_ratio",
195  "jet_pfcand_trackjet_d3d",
196  "jet_pfcand_trackjet_d3dsig",
197  "jet_pfcand_trackjet_dist",
198  "jet_pfcand_nhits",
199  "jet_pfcand_npixhits",
200  "jet_pfcand_nstriphits",
201  "jet_pfcand_trackjet_decayL",
202  "jet_pfcand_id",
203  "jet_pfcand_calofraction",
204  "jet_pfcand_hcalfraction",
205  "jet_pfcand_puppiw",
206  "jet_pfcand_muon_id",
207  "jet_pfcand_muon_isglobal",
208  "jet_pfcand_muon_segcomp",
209  "jet_pfcand_muon_chi2",
210  "jet_pfcand_muon_nvalidhit",
211  "jet_pfcand_muon_nstation",
212  "jet_pfcand_electron_detaIn",
213  "jet_pfcand_electron_dphiIn",
214  "jet_pfcand_electron_sigIetaIeta",
215  "jet_pfcand_electron_sigIphiIphi",
216  "jet_pfcand_electron_r9",
217  "jet_pfcand_electron_convProb",
218  "jet_pfcand_photon_sigIetaIeta",
219  "jet_pfcand_photon_r9",
220  "jet_pfcand_photon_eVeto",
221  "jet_pfcand_tau_signal",
222  "pfcand_mask"};
223 
224 const std::vector<std::string> ParticleNetFeatureEvaluator::sv_features_{"jet_sv_pt_log",
225  "jet_sv_mass",
226  "jet_sv_deta",
227  "jet_sv_dphi",
228  "jet_sv_eta",
229  "jet_sv_ntrack",
230  "jet_sv_chi2",
231  "jet_sv_dxy",
232  "jet_sv_dxysig",
233  "jet_sv_d3d",
234  "jet_sv_d3dsig",
235  "sv_mask"};
236 
237 const std::vector<std::string> ParticleNetFeatureEvaluator::losttrack_features_{"jet_losttrack_pt_log",
238  "jet_losttrack_eta",
239  "jet_losttrack_deta",
240  "jet_losttrack_dphi",
241  "jet_losttrack_charge",
242  "jet_losttrack_frompv",
243  "jet_losttrack_track_chi2",
244  "jet_losttrack_track_qual",
245  "jet_losttrack_dz",
246  "jet_losttrack_dxy",
247  "jet_losttrack_dzsig",
248  "jet_losttrack_dxysig",
249  "jet_losttrack_etarel",
250  "jet_losttrack_trackjet_d3d",
251  "jet_losttrack_trackjet_d3dsig",
252  "jet_losttrack_trackjet_dist",
253  "jet_losttrack_trackjet_decayL",
254  "jet_losttrack_npixhits",
255  "jet_losttrack_nstriphits",
256  "lt_mask"};
257 
259  : jet_radius_(iConfig.getParameter<double>("jet_radius")),
260  min_jet_pt_(iConfig.getParameter<double>("min_jet_pt")),
261  max_jet_eta_(iConfig.getParameter<double>("max_jet_eta")),
262  min_jet_eta_(iConfig.getParameter<double>("min_jet_eta")),
263  min_pt_for_track_properties_(iConfig.getParameter<double>("min_pt_for_track_properties")),
264  min_pt_for_pfcandidates_(iConfig.getParameter<double>("min_pt_for_pfcandidates")),
265  min_pt_for_losttrack_(iConfig.getParameter<double>("min_pt_for_losttrack")),
266  max_dr_for_losttrack_(iConfig.getParameter<double>("max_dr_for_losttrack")),
267  min_pt_for_taus_(iConfig.getParameter<double>("min_pt_for_taus")),
268  max_eta_for_taus_(iConfig.getParameter<double>("max_eta_for_taus")),
269  include_neutrals_(iConfig.getParameter<bool>("include_neutrals")),
270  flip_ip_sign_(iConfig.getParameter<bool>("flip_ip_sign")),
271  fallback_puppi_weight_(iConfig.getParameter<bool>("fallback_puppi_weight")),
272  use_puppi_value_map_(false),
273  max_sip3dsig_for_flip_(iConfig.getParameter<double>("max_sip3dsig_for_flip")),
274  muon_token_(consumes<pat::MuonCollection>(iConfig.getParameter<edm::InputTag>("muons"))),
275  electron_token_(consumes<pat::ElectronCollection>(iConfig.getParameter<edm::InputTag>("electrons"))),
276  photon_token_(consumes<pat::PhotonCollection>(iConfig.getParameter<edm::InputTag>("photons"))),
277  tau_token_(consumes<pat::TauCollection>(iConfig.getParameter<edm::InputTag>("taus"))),
278  jet_token_(consumes<edm::View<reco::Jet>>(iConfig.getParameter<edm::InputTag>("jets"))),
279  losttrack_token_(consumes<pat::PackedCandidateCollection>(iConfig.getParameter<edm::InputTag>("losttracks"))),
280  vtx_token_(consumes<reco::VertexCollection>(iConfig.getParameter<edm::InputTag>("vertices"))),
281  sv_token_(consumes<reco::VertexCompositePtrCandidateCollection>(
282  iConfig.getParameter<edm::InputTag>("secondary_vertices"))),
283  pfcand_token_(consumes<edm::View<reco::Candidate>>(iConfig.getParameter<edm::InputTag>("pf_candidates"))),
284  track_builder_token_(
285  esConsumes<TransientTrackBuilder, TransientTrackRecord>(edm::ESInputTag("", "TransientTrackBuilder"))) {
286  const auto &puppi_value_map_tag = iConfig.getParameter<edm::InputTag>("puppi_value_map");
287  if (!puppi_value_map_tag.label().empty()) {
288  puppi_value_map_token_ = consumes<edm::ValueMap<float>>(puppi_value_map_tag);
289  use_puppi_value_map_ = true;
290  }
291  produces<std::vector<reco::DeepBoostedJetTagInfo>>();
292 }
293 
295 
297  // pfDeepBoostedJetTagInfos
299  desc.add<double>("jet_radius", 0.8);
300  desc.add<double>("min_jet_pt", 150);
301  desc.add<double>("max_jet_eta", 99);
302  desc.add<double>("min_jet_eta", 0.0);
303  desc.add<double>("min_pt_for_track_properties", -1);
304  desc.add<double>("min_pt_for_pfcandidates", -1);
305  desc.add<double>("min_pt_for_losttrack", 1);
306  desc.add<double>("max_dr_for_losttrack", 0.4);
307  desc.add<double>("min_pt_for_taus", 20.);
308  desc.add<double>("max_eta_for_taus", 2.5);
309  desc.add<bool>("include_neutrals", true);
310  desc.add<bool>("flip_ip_sign", false);
311  desc.add<bool>("fallback_puppi_weight", false);
312  desc.add<double>("max_sip3dsig_for_flip", 99999);
313  desc.add<edm::InputTag>("vertices", edm::InputTag("offlineSlimmedPrimaryVertices"));
314  desc.add<edm::InputTag>("secondary_vertices", edm::InputTag("slimmedSecondaryVertices"));
315  desc.add<edm::InputTag>("pf_candidates", edm::InputTag("packedPFCandidates"));
316  desc.add<edm::InputTag>("puppi_value_map", edm::InputTag("puppi"));
317  desc.add<edm::InputTag>("losttracks", edm::InputTag("lostTracks"));
318  desc.add<edm::InputTag>("jets", edm::InputTag("slimmedJetsAK8"));
319  desc.add<edm::InputTag>("muons", edm::InputTag("slimmedMuons"));
320  desc.add<edm::InputTag>("taus", edm::InputTag("slimmedTaus"));
321  desc.add<edm::InputTag>("electrons", edm::InputTag("slimmedElectrons"));
322  desc.add<edm::InputTag>("photons", edm::InputTag("slimmedPhotons"));
323  descriptions.add("ParticleNetFeatureEvaluator", desc);
324 }
325 
327  // output collection
328  auto output_tag_infos = std::make_unique<std::vector<reco::DeepBoostedJetTagInfo>>();
329  // Input jets
330  auto jets = iEvent.getHandle(jet_token_);
331  // Input muons
332  auto muons = iEvent.getHandle(muon_token_);
333  // Input taus
334  auto taus = iEvent.getHandle(tau_token_);
335  // Input electrons
336  auto electrons = iEvent.getHandle(electron_token_);
337  // Input photons
338  auto photons = iEvent.getHandle(photon_token_);
339  // Input lost tracks
340  iEvent.getByToken(losttrack_token_, losttracks_);
341  // Get puuppi value map
342  if (use_puppi_value_map_) {
343  iEvent.getByToken(puppi_value_map_token_, puppi_value_map_);
344  }
345 
346  // Primary vertexes
347  iEvent.getByToken(vtx_token_, vtxs_);
348  if (vtxs_->empty()) {
349  // produce empty TagInfos in case no primary vertex
350  iEvent.put(std::move(output_tag_infos));
351  return; // exit event
352  }
353  // Leading vertex
354  pv_ = &vtxs_->at(0);
355  // Secondary vertexs
356  iEvent.getByToken(sv_token_, svs_);
357  // PF candidates
358  iEvent.getByToken(pfcand_token_, pfcands_);
359  // Track builder
360  track_builder_ = iSetup.getHandle(track_builder_token_);
361 
362  // tau signal candidates
363  std::vector<math::XYZTLorentzVector> tau_pfcandidates;
364  for (size_t itau = 0; itau < taus->size(); itau++) {
365  if (taus->at(itau).pt() < min_pt_for_taus_)
366  continue;
367  if (fabs(taus->at(itau).eta()) > max_eta_for_taus_)
368  continue;
369  for (unsigned ipart = 0; ipart < taus->at(itau).signalCands().size(); ipart++) {
371  dynamic_cast<const pat::PackedCandidate *>(taus->at(itau).signalCands()[ipart].get());
372  tau_pfcandidates.push_back(pfcand->p4());
373  }
374  }
375 
376  // Loop over jet
377  for (std::size_t jet_n = 0; jet_n < jets->size(); jet_n++) {
378  const auto &jet = (*jets)[jet_n];
379  edm::RefToBase<reco::Jet> jet_ref(jets, jet_n);
380 
381  // create jet features
383  for (const auto &name : particle_features_)
384  features.add(name);
385  for (const auto &name : sv_features_)
386  features.add(name);
387 
388  // fill values only if above pt threshold and has daughters, otherwise left
389  bool fill_vars = true;
390  if ((jet.pt() < min_jet_pt_ and
391  dynamic_cast<const pat::Jet *>(&jet)->correctedJet("Uncorrected").pt() < min_jet_pt_) or
392  std::abs(jet.eta()) >= max_jet_eta_ or std::abs(jet.eta()) < min_jet_eta_)
393  fill_vars = false;
394  if (jet.numberOfDaughters() == 0)
395  fill_vars = false;
396 
397  // fill features
398  if (fill_vars) {
399  fillParticleFeatures(features, jet, tau_pfcandidates, *muons, *electrons, *photons);
400  fillSVFeatures(features, jet);
401  fillLostTrackFeatures(features, jet);
402  features.check_consistency(particle_features_);
403  features.check_consistency(sv_features_);
404  features.check_consistency(losttrack_features_);
405  }
406 
407  // this should always be done even if features are not filled
408  output_tag_infos->emplace_back(features, jet_ref);
409  }
410  // move output collection
411  iEvent.put(std::move(output_tag_infos));
412 }
413 
415  const auto *track = cand->bestTrack();
416  return track != nullptr and track->pt() > min_pt_for_track_properties_;
417 };
418 
420  const reco::Jet &jet,
421  const std::vector<math::XYZTLorentzVector> &tau_pfcandidates,
422  const pat::MuonCollection &muons,
425  // some jet properties
426  math::XYZVector jet_dir = jet.momentum().Unit();
427  TVector3 jet_direction(jet.momentum().Unit().x(), jet.momentum().Unit().y(), jet.momentum().Unit().z());
428  GlobalVector jet_ref_track_dir(jet.px(), jet.py(), jet.pz());
429  // vertexes
430  reco::VertexRefProd PVRefProd(vtxs_);
431  // track builder
432  TrackInfoBuilder trackinfo(track_builder_);
433 
434  //Save puppi weight for selected constituents in this map
435  std::map<const pat::PackedCandidate *, float> map_pc2puppiweight;
436 
437  // make list of pf-candidates to be considered
438  std::vector<const pat::PackedCandidate *> daughters;
439  for (const auto &dau : jet.daughterPtrVector()) {
440  // remove particles w/ extremely low puppi weights
441  const pat::PackedCandidate *cand = dynamic_cast<const pat::PackedCandidate *>(&(*dau));
442  if (not cand)
443  throw edm::Exception(edm::errors::InvalidReference) << "Cannot convert to either pat::PackedCandidate";
444  // base requirements on PF candidates
445  if (cand->pt() < min_pt_for_pfcandidates_)
446  continue;
447  // charged candidate selection (for Higgs Interaction Net)
448  if (!include_neutrals_ and (cand->charge() == 0 or cand->pt() < min_pt_for_track_properties_))
449  continue;
450  // filling daughters
451  daughters.push_back(cand);
452 
453  float puppiw = 1.;
454  if (use_puppi_value_map_) {
455  puppiw = (*puppi_value_map_)[dau];
456  } else if (!fallback_puppi_weight_) {
457  throw edm::Exception(edm::errors::InvalidReference, "PUPPI value map missing")
458  << "use fallback_puppi_weight option to use " << puppiw << " for cand as default";
459  }
460  map_pc2puppiweight[cand] = puppiw;
461  }
462 
463  // sort by original pt (not Puppi-weighted)
464  std::sort(daughters.begin(), daughters.end(), [](const auto &a, const auto &b) { return a->pt() > b->pt(); });
465 
466  // reserve space
467  for (const auto &name : particle_features_)
468  fts.reserve(name, daughters.size());
469 
470  // Build observables
471  for (const auto &cand : daughters) {
472  if (!include_neutrals_ and !useTrackProperties(cand))
473  continue;
474 
475  // input particle is a packed PF candidate
476  auto candP4 = cand->p4();
477  auto candP3 = cand->momentum();
478 
479  // candidate track
480  const reco::Track *track = nullptr;
481  if (useTrackProperties(cand))
482  track = cand->bestTrack();
483 
484  // reco-vertex association
485  reco::VertexRef pv_ass = reco::VertexRef(vtxs_, 0);
486  math::XYZPoint pv_ass_pos = pv_ass->position();
487 
488  TVector3 cand_direction(candP3.x(), candP3.y(), candP3.z());
489 
490  // only when computing the nagative tagger: remove charged candidates with high sip3d
491  if (flip_ip_sign_ && track) {
492  reco::TransientTrack transientTrack = track_builder_->build(*track);
493  Measurement1D meas_ip3d = IPTools::signedImpactParameter3D(transientTrack, jet_ref_track_dir, *pv_).second;
494  if (!std::isnan(meas_ip3d.significance()) && meas_ip3d.significance() > max_sip3dsig_for_flip_) {
495  continue;
496  }
497  }
498  float ip_sign = flip_ip_sign_ ? -1.f : 1.f;
499 
500  fts.fill("jet_pfcand_pt_log", std::isnan(std::log(candP4.pt())) ? 0 : std::log(candP4.pt()));
501  fts.fill("jet_pfcand_energy_log", std::isnan(std::log(candP4.energy())) ? 0 : std::log(candP4.energy()));
502  fts.fill("jet_pfcand_eta", candP4.eta());
503  fts.fill("jet_pfcand_deta", jet_direction.Eta() - cand_direction.Eta());
504  fts.fill("jet_pfcand_dphi", jet_direction.DeltaPhi(cand_direction));
505  fts.fill("jet_pfcand_charge", cand->charge());
506  fts.fill("jet_pfcand_etarel",
507  std::isnan(reco::btau::etaRel(jet_dir, candP3)) ? 0 : reco::btau::etaRel(jet_dir, candP3));
508  fts.fill("jet_pfcand_pperp_ratio",
509  std::isnan(jet_direction.Perp(cand_direction) / cand_direction.Mag())
510  ? 0
511  : jet_direction.Perp(cand_direction) / cand_direction.Mag());
512  fts.fill("jet_pfcand_ppara_ratio",
513  std::isnan(jet_direction.Dot(cand_direction) / cand_direction.Mag())
514  ? 0
515  : jet_direction.Dot(cand_direction) / cand_direction.Mag());
516  fts.fill("jet_pfcand_frompv", cand->fromPV());
517  fts.fill("jet_pfcand_dz", ip_sign * (std::isnan(cand->dz(pv_ass_pos)) ? 0 : cand->dz(pv_ass_pos)));
518  fts.fill("jet_pfcand_dxy", ip_sign * (std::isnan(cand->dxy(pv_ass_pos)) ? 0 : cand->dxy(pv_ass_pos)));
519  fts.fill("jet_pfcand_puppiw", map_pc2puppiweight[cand]);
520  fts.fill("jet_pfcand_nlostinnerhits", cand->lostInnerHits());
521  fts.fill("jet_pfcand_nhits", cand->numberOfHits());
522  fts.fill("jet_pfcand_npixhits", cand->numberOfPixelHits());
523  fts.fill("jet_pfcand_nstriphits", cand->stripLayersWithMeasurement());
524 
525  if (abs(cand->pdgId()) == 11 and cand->charge() != 0)
526  fts.fill("jet_pfcand_id", 0);
527  else if (abs(cand->pdgId()) == 13 and cand->charge() != 0)
528  fts.fill("jet_pfcand_id", 1);
529  else if (abs(cand->pdgId()) == 22 and cand->charge() == 0)
530  fts.fill("jet_pfcand_id", 2);
531  else if (abs(cand->pdgId()) != 22 and cand->charge() == 0 and abs(cand->pdgId()) != 1 and abs(cand->pdgId()) != 2)
532  fts.fill("jet_pfcand_id", 3);
533  else if (abs(cand->pdgId()) != 11 and abs(cand->pdgId()) != 13 and cand->charge() != 0)
534  fts.fill("jet_pfcand_id", 4);
535  else if (cand->charge() == 0 and abs(cand->pdgId()) == 1)
536  fts.fill("jet_pfcand_id", 5);
537  else if (cand->charge() == 0 and abs(cand->pdgId()) == 2)
538  fts.fill("jet_pfcand_id", 6);
539  else
540  fts.fill("jet_pfcand_id", -1);
541 
542  fts.fill("jet_pfcand_hcalfraction", std::isnan(cand->hcalFraction()) ? 0 : cand->hcalFraction());
543  fts.fill("jet_pfcand_calofraction", std::isnan(cand->caloFraction()) ? 0 : cand->caloFraction());
544  fts.fill("pfcand_mask", 1);
545 
546  if (track) {
547  fts.fill(
548  "jet_pfcand_dzsig",
549  std::isnan(fabs(cand->dz(pv_ass_pos)) / cand->dzError()) ? 0 : fabs(cand->dz(pv_ass_pos)) / cand->dzError());
550  fts.fill("jet_pfcand_dxysig",
551  std::isnan(fabs(cand->dxy(pv_ass_pos)) / cand->dxyError())
552  ? 0
553  : fabs(cand->dxy(pv_ass_pos)) / cand->dxyError());
554  fts.fill("jet_pfcand_track_chi2", track->normalizedChi2());
555  fts.fill("jet_pfcand_track_qual", track->qualityMask());
556 
557  reco::TransientTrack transientTrack = track_builder_->build(*track);
558  Measurement1D meas_ip2d =
559  IPTools::signedTransverseImpactParameter(transientTrack, jet_ref_track_dir, *pv_).second;
560  Measurement1D meas_ip3d = IPTools::signedImpactParameter3D(transientTrack, jet_ref_track_dir, *pv_).second;
561  Measurement1D meas_jetdist = IPTools::jetTrackDistance(transientTrack, jet_ref_track_dir, *pv_).second;
562  Measurement1D meas_decayl = IPTools::signedDecayLength3D(transientTrack, jet_ref_track_dir, *pv_).second;
563 
564  fts.fill("jet_pfcand_trackjet_d3d", ip_sign * (std::isnan(meas_ip3d.value()) ? 0 : meas_ip3d.value()));
565  fts.fill("jet_pfcand_trackjet_d3dsig",
566  std::isnan(fabs(meas_ip3d.significance())) ? 0 : fabs(meas_ip3d.significance()));
567  fts.fill("jet_pfcand_trackjet_dist", std::isnan(-meas_jetdist.value()) ? 0 : -meas_jetdist.value());
568  fts.fill("jet_pfcand_trackjet_decayL", std::isnan(meas_decayl.value()) ? 0 : meas_decayl.value());
569  } else {
570  fts.fill("jet_pfcand_dzsig", 0);
571  fts.fill("jet_pfcand_dxysig", 0);
572  fts.fill("jet_pfcand_track_chi2", 0);
573  fts.fill("jet_pfcand_track_qual", 0);
574  fts.fill("jet_pfcand_trackjet_d3d", 0);
575  fts.fill("jet_pfcand_trackjet_d3dsig", 0);
576  fts.fill("jet_pfcand_trackjet_dist", 0);
577  fts.fill("jet_pfcand_trackjet_decayL", 0);
578  }
579 
580  // muons specific
581  if (abs(cand->pdgId()) == 13) {
582  std::vector<unsigned int> muonsToSkip;
583  int ipos = -1;
584  float minDR = 1000;
585  for (size_t i = 0; i < muons.size(); i++) {
586  if (not muons[i].isPFMuon())
587  continue;
588  if (std::find(muonsToSkip.begin(), muonsToSkip.end(), i) != muonsToSkip.end())
589  continue;
590  float dR = reco::deltaR(muons[i].p4(), candP4);
591  if (dR < jet_radius_ and dR < minDR) {
592  minDR = dR;
593  ipos = i;
594  muonsToSkip.push_back(i);
595  }
596  }
597  if (ipos >= 0) {
598  int muonId = 0;
600  muonId++;
602  muonId++;
604  muonId++;
606  muonId++;
608  muonId++;
609  fts.fill("jet_pfcand_muon_id", muonId);
610  fts.fill("jet_pfcand_muon_isglobal", muons[ipos].isGlobalMuon());
611  fts.fill("jet_pfcand_muon_chi2",
612  (muons[ipos].isGlobalMuon()) ? muons[ipos].globalTrack()->normalizedChi2() : 0);
613  fts.fill("jet_pfcand_muon_nvalidhit",
614  (muons[ipos].isGlobalMuon()) ? muons[ipos].globalTrack()->hitPattern().numberOfValidMuonHits() : 0);
615  fts.fill("jet_pfcand_muon_nstation", muons[ipos].numberOfMatchedStations());
616  fts.fill("jet_pfcand_muon_segcomp", muon::segmentCompatibility(muons[ipos]));
617  } else {
618  fts.fill("jet_pfcand_muon_id", 0);
619  fts.fill("jet_pfcand_muon_isglobal", 0);
620  fts.fill("jet_pfcand_muon_chi2", 0);
621  fts.fill("jet_pfcand_muon_nvalidhit", 0);
622  fts.fill("jet_pfcand_muon_nstation", 0);
623  fts.fill("jet_pfcand_muon_segcomp", 0);
624  }
625  } else {
626  fts.fill("jet_pfcand_muon_id", 0);
627  fts.fill("jet_pfcand_muon_isglobal", 0);
628  fts.fill("jet_pfcand_muon_chi2", 0);
629  fts.fill("jet_pfcand_muon_nvalidhit", 0);
630  fts.fill("jet_pfcand_muon_nstation", 0);
631  fts.fill("jet_pfcand_muon_segcomp", 0);
632  }
633 
634  // electrons specific
635  if (abs(cand->pdgId()) == 11) {
636  int ipos = -1;
637  for (size_t i = 0; i < electrons.size(); i++) {
638  if (electrons[i].isPF()) {
639  for (const auto &element : electrons[i].associatedPackedPFCandidates()) {
640  if (abs(element->pdgId()) == 11 and element->p4() == candP4)
641  ipos = i;
642  }
643  }
644  }
645  if (ipos >= 0) {
646  fts.fill("jet_pfcand_electron_detaIn",
647  std::isnan(electrons[ipos].deltaEtaSuperClusterTrackAtVtx())
648  ? 0
649  : electrons[ipos].deltaEtaSuperClusterTrackAtVtx());
650  fts.fill("jet_pfcand_electron_dphiIn",
651  std::isnan(electrons[ipos].deltaPhiSuperClusterTrackAtVtx())
652  ? 0
653  : electrons[ipos].deltaPhiSuperClusterTrackAtVtx());
654  fts.fill("jet_pfcand_electron_sigIetaIeta",
656  fts.fill("jet_pfcand_electron_sigIphiIphi",
657  std::isnan(electrons[ipos].full5x5_sigmaIphiIphi()) ? 0 : electrons[ipos].full5x5_sigmaIphiIphi());
658  fts.fill("jet_pfcand_electron_r9", std::isnan(electrons[ipos].full5x5_r9()) ? 0 : electrons[ipos].full5x5_r9());
659  fts.fill("jet_pfcand_electron_convProb",
661  } else {
662  fts.fill("jet_pfcand_electron_detaIn", 0);
663  fts.fill("jet_pfcand_electron_dphiIn", 0);
664  fts.fill("jet_pfcand_electron_sigIetaIeta", 0);
665  fts.fill("jet_pfcand_electron_sigIphiIphi", 0);
666  fts.fill("jet_pfcand_electron_r9", 0);
667  fts.fill("jet_pfcand_electron_convProb", 0);
668  }
669  } else {
670  fts.fill("jet_pfcand_electron_detaIn", 0);
671  fts.fill("jet_pfcand_electron_dphiIn", 0);
672  fts.fill("jet_pfcand_electron_sigIetaIeta", 0);
673  fts.fill("jet_pfcand_electron_sigIphiIphi", 0);
674  fts.fill("jet_pfcand_electron_r9", 0);
675  fts.fill("jet_pfcand_electron_convProb", 0);
676  }
677 
678  // photons specific
679  if (abs(cand->pdgId()) == 22) {
680  int ipos = -1;
681  for (size_t i = 0; i < photons.size(); i++) {
682  for (const auto &element : photons[i].associatedPackedPFCandidates()) {
683  if (abs(element->pdgId()) == 22 and element->p4() == candP4)
684  ipos = i;
685  }
686  }
687  if (ipos >= 0) {
688  fts.fill("jet_pfcand_photon_sigIetaIeta",
690  fts.fill("jet_pfcand_photon_r9", std::isnan(photons[ipos].full5x5_r9()) ? 0 : photons[ipos].full5x5_r9());
691  fts.fill("jet_pfcand_photon_eVeto", photons[ipos].passElectronVeto());
692  } else {
693  fts.fill("jet_pfcand_photon_sigIetaIeta", 0);
694  fts.fill("jet_pfcand_photon_r9", 0);
695  fts.fill("jet_pfcand_photon_eVeto", 0);
696  }
697  } else {
698  fts.fill("jet_pfcand_photon_sigIetaIeta", 0);
699  fts.fill("jet_pfcand_photon_r9", 0);
700  fts.fill("jet_pfcand_photon_eVeto", 0);
701  }
702 
703  // tau specific prior to any puppi weight application
704  if (std::find(tau_pfcandidates.begin(), tau_pfcandidates.end(), cand->p4()) != tau_pfcandidates.end())
705  fts.fill("jet_pfcand_tau_signal", 1);
706  else
707  fts.fill("jet_pfcand_tau_signal", 0);
708  }
709 }
710 
712  // secondary vertexes matching jet
713  std::vector<const reco::VertexCompositePtrCandidate *> jetSVs;
714  for (const auto &sv : *svs_) {
715  if (reco::deltaR2(sv, jet) < jet_radius_ * jet_radius_) {
716  jetSVs.push_back(&sv);
717  }
718  }
719 
720  // sort by dxy significance
721  std::sort(jetSVs.begin(),
722  jetSVs.end(),
724  return sv_vertex_comparator(*sva, *svb, *pv_);
725  });
726 
727  // reserve space
728  for (const auto &name : sv_features_)
729  fts.reserve(name, jetSVs.size());
730 
731  GlobalVector jet_global_vec(jet.px(), jet.py(), jet.pz());
732 
733  float ip_sign = flip_ip_sign_ ? -1.f : 1.f;
734 
735  for (const auto *sv : jetSVs) {
736  fts.fill("sv_mask", 1);
737  fts.fill("jet_sv_pt_log", std::isnan(std::log(sv->pt())) ? 0 : std::log(sv->pt()));
738  fts.fill("jet_sv_eta", sv->eta());
739  fts.fill("jet_sv_mass", sv->mass());
740  fts.fill("jet_sv_deta", sv->eta() - jet.eta());
741  fts.fill("jet_sv_dphi", sv->phi() - jet.phi());
742  fts.fill("jet_sv_ntrack", sv->numberOfDaughters());
743  fts.fill("jet_sv_chi2", sv->vertexNormalizedChi2());
744 
746  sv->fillVertexCovariance(csv);
747  reco::Vertex svtx(sv->vertex(), csv);
748 
750  auto valxy = dxy.signedDistance(svtx, *pv_, jet_global_vec);
751  fts.fill("jet_sv_dxy", ip_sign * (std::isnan(valxy.value()) ? 0 : valxy.value()));
752  fts.fill("jet_sv_dxysig", std::isnan(fabs(valxy.significance())) ? 0 : fabs(valxy.significance()));
753 
754  VertexDistance3D d3d;
755  auto val3d = d3d.signedDistance(svtx, *pv_, jet_global_vec);
756  fts.fill("jet_sv_d3d", ip_sign * (std::isnan(val3d.value()) ? 0 : val3d.value()));
757  fts.fill("jet_sv_d3dsig", std::isnan(fabs(val3d.significance())) ? 0 : fabs(val3d.significance()));
758  }
759 }
760 
762  // some jet properties
763  TVector3 jet_direction(jet.momentum().Unit().x(), jet.momentum().Unit().y(), jet.momentum().Unit().z());
764  GlobalVector jet_ref_track_dir(jet.px(), jet.py(), jet.pz());
765  math::XYZVector jet_dir = jet.momentum().Unit();
766 
767  std::vector<pat::PackedCandidate> jet_lost_tracks;
768  for (size_t itrk = 0; itrk < losttracks_->size(); itrk++) {
769  if (reco::deltaR(losttracks_->at(itrk).p4(), jet.p4()) < max_dr_for_losttrack_ and
770  losttracks_->at(itrk).pt() > min_pt_for_losttrack_) {
771  jet_lost_tracks.push_back(losttracks_->at(itrk));
772  }
773  }
774  std::sort(
775  jet_lost_tracks.begin(), jet_lost_tracks.end(), [](const auto &a, const auto &b) { return a.pt() > b.pt(); });
776 
777  // reserve space
778  for (const auto &name : losttrack_features_)
779  fts.reserve(name, jet_lost_tracks.size());
780 
781  reco::VertexRef pv_ass = reco::VertexRef(vtxs_, 0);
782  math::XYZPoint pv_ass_pos = pv_ass->position();
783 
784  for (auto const &ltrack : jet_lost_tracks) {
785  const reco::Track *track = ltrack.bestTrack();
786 
787  // only when computing the nagative tagger: remove charged candidates with high sip3d
788  if (flip_ip_sign_) {
789  reco::TransientTrack transientTrack = track_builder_->build(*track);
790  Measurement1D meas_ip3d = IPTools::signedImpactParameter3D(transientTrack, jet_ref_track_dir, *pv_).second;
791  if (!std::isnan(meas_ip3d.significance()) && meas_ip3d.significance() > max_sip3dsig_for_flip_) {
792  continue;
793  }
794  }
795  float ip_sign = flip_ip_sign_ ? -1.f : 1.f;
796 
797  fts.fill("jet_losttrack_pt_log", std::isnan(std::log(ltrack.pt())) ? 0 : std::log(ltrack.pt()));
798  fts.fill("jet_losttrack_eta", ltrack.eta());
799  fts.fill("jet_losttrack_charge", ltrack.charge());
800  fts.fill("jet_losttrack_frompv", ltrack.fromPV());
801  fts.fill("jet_losttrack_dz", ip_sign * (std::isnan(ltrack.dz(pv_ass_pos)) ? 0 : ltrack.dz(pv_ass_pos)));
802  fts.fill("jet_losttrack_dxy", ip_sign * (std::isnan(ltrack.dxy(pv_ass_pos)) ? 0 : ltrack.dxy(pv_ass_pos)));
803  fts.fill("jet_losttrack_npixhits", ltrack.numberOfPixelHits());
804  fts.fill("jet_losttrack_nstriphits", ltrack.stripLayersWithMeasurement());
805 
806  TVector3 ltrack_momentum(ltrack.momentum().x(), ltrack.momentum().y(), ltrack.momentum().z());
807  fts.fill("jet_losttrack_deta", jet_direction.Eta() - ltrack_momentum.Eta());
808  fts.fill("jet_losttrack_dphi", jet_direction.DeltaPhi(ltrack_momentum));
809  fts.fill("jet_losttrack_etarel",
810  std::isnan(reco::btau::etaRel(jet_dir, ltrack.momentum()))
811  ? 0
812  : reco::btau::etaRel(jet_dir, ltrack.momentum()));
813 
814  if (track) {
815  fts.fill("jet_losttrack_track_chi2", track->normalizedChi2());
816  fts.fill("jet_losttrack_track_qual", track->qualityMask());
817  fts.fill("jet_losttrack_dxysig",
818  std::isnan(fabs(ltrack.dxy(pv_ass_pos)) / ltrack.dxyError())
819  ? 0
820  : fabs(ltrack.dxy(pv_ass_pos)) / ltrack.dxyError());
821  fts.fill("jet_losttrack_dzsig",
822  std::isnan(fabs(ltrack.dz(pv_ass_pos)) / ltrack.dzError())
823  ? 0
824  : fabs(ltrack.dz(pv_ass_pos)) / ltrack.dzError());
825 
826  reco::TransientTrack transientTrack = track_builder_->build(*track);
827  Measurement1D meas_ip3d = IPTools::signedImpactParameter3D(transientTrack, jet_ref_track_dir, *pv_).second;
828  Measurement1D meas_jetdist = IPTools::jetTrackDistance(transientTrack, jet_ref_track_dir, *pv_).second;
829  Measurement1D meas_decayl = IPTools::signedDecayLength3D(transientTrack, jet_ref_track_dir, *pv_).second;
830 
831  fts.fill("jet_losttrack_trackjet_d3d", ip_sign * (std::isnan(meas_ip3d.value()) ? 0 : meas_ip3d.value()));
832  fts.fill("jet_losttrack_trackjet_d3dsig",
833  std::isnan(fabs(meas_ip3d.significance())) ? 0 : fabs(meas_ip3d.significance()));
834  fts.fill("jet_losttrack_trackjet_dist", std::isnan(-meas_jetdist.value()) ? 0 : -meas_jetdist.value());
835  fts.fill("jet_losttrack_trackjet_decayL", std::isnan(meas_decayl.value()) ? 0 : meas_decayl.value());
836  } else {
837  fts.fill("jet_losttrack_track_chi2", 0);
838  fts.fill("jet_losttrack_track_qual", 0);
839  fts.fill("jet_losttrack_dxysig", 0);
840  fts.fill("jet_losttrack_dzsig", 0);
841  fts.fill("jet_losttrack_trackjet_d3d", 0);
842  fts.fill("jet_losttrack_trackjet_d3dsig", 0);
843  fts.fill("jet_losttrack_trackjet_dist", 0);
844  fts.fill("jet_losttrack_trackjet_decayL", 0);
845  }
846 
847  fts.fill("lt_mask", 1);
848  }
849 }
850 
851 // define this as a plug-in
852 DEFINE_FWK_MODULE(ParticleNetFeatureEvaluator);
edm::Handle< reco::VertexCompositePtrCandidateCollection > svs_
def isnan(num)
ESGetTokenH3DDVariant esConsumes(std::string const &Record, edm::ConsumesCollector &)
Definition: DeDxTools.cc:283
T getParameter(std::string const &) const
Definition: ParameterSet.h:307
std::vector< float > jet_losttrack_trackjet_dist
double pt() const final
transverse momentum
edm::Handle< reco::VertexCollection > vtxs_
Base class for all types of Jets.
Definition: Jet.h:20
double etaRel(const math::XYZVector &dir, const math::XYZVector &track)
void beginStream(edm::StreamID) override
edm::EDGetTokenT< pat::ElectronCollection > electron_token_
std::pair< bool, Measurement1D > signedTransverseImpactParameter(const reco::TransientTrack &track, const GlobalVector &direction, const reco::Vertex &vertex)
Definition: IPTools.cc:57
std::vector< float > jet_pfcand_electron_sigIetaIeta
std::vector< pat::PackedCandidate > PackedCandidateCollection
std::pair< bool, Measurement1D > signedDecayLength3D(const TrajectoryStateOnSurface &state, const GlobalVector &direction, const reco::Vertex &vertex)
Definition: IPTools.cc:105
edm::Handle< edm::View< reco::Candidate > > pfcands_
std::pair< bool, Measurement1D > signedImpactParameter3D(const reco::TransientTrack &track, const GlobalVector &direction, const reco::Vertex &vertex)
Definition: IPTools.cc:81
std::vector< Tau > TauCollection
Definition: Tau.h:35
std::vector< float > jet_losttrack_trackjet_d3dsig
edm::ESHandle< TransientTrackBuilder > track_builder_
void find(edm::Handle< EcalRecHitCollection > &hits, DetId thisDet, std::vector< EcalRecHitCollection::const_iterator > &hit, bool debug=false)
Definition: FindCaloHit.cc:19
std::vector< Vertex > VertexCollection
Definition: Vertex.h:31
muons
the two sets of parameters below are mutually exclusive, depending if RECO or ALCARECO is used the us...
Definition: DiMuonV_cfg.py:214
edm::EDGetTokenT< pat::TauCollection > tau_token_
math::Error< dimension >::type CovarianceMatrix
covariance error matrix (3x3)
Definition: Vertex.h:47
std::vector< VertexCompositePtrCandidate > VertexCompositePtrCandidateCollection
collection of Candidate objects
std::vector< Muon > MuonCollection
collection of Muon objects
Definition: MuonFwd.h:9
std::pair< double, Measurement1D > jetTrackDistance(const reco::TransientTrack &track, const GlobalVector &direction, const reco::Vertex &vertex)
Definition: IPTools.cc:206
Definition: HeavyIon.h:7
edm::EDGetTokenT< pat::MuonCollection > muon_token_
static const std::vector< std::string > particle_features_
int iEvent
Definition: GenABIO.cc:224
edm::Handle< edm::ValueMap< float > > puppi_value_map_
edm::EDGetTokenT< pat::PackedCandidateCollection > losttrack_token_
std::vector< Electron > ElectronCollection
Definition: Electron.h:36
void reserve(const std::string &name, unsigned capacity)
edm::Handle< pat::PackedCandidateCollection > losttracks_
Definition: Jet.py:1
std::vector< float > features(const reco::PreId &ecal, const reco::PreId &hcal, double rho, const reco::BeamSpot &spot, noZS::EcalClusterLazyTools &ecalTools)
std::vector< float > jet_losttrack_trackjet_decayL
std::vector< float > jet_pfcand_photon_sigIetaIeta
The Signals That Services Can Subscribe To This is based on ActivityRegistry and is current per Services can connect to the signals distributed by the ActivityRegistry in order to monitor the activity of the application Each possible callback has some defined which we here list in angle e< void, edm::EventID const &, edm::Timestamp const & > We also list in braces which AR_WATCH_USING_METHOD_ is used for those or
Definition: Activities.doc:12
edm::EDGetTokenT< edm::View< reco::Jet > > jet_token_
static const std::vector< std::string > losttrack_features_
Abs< T >::type abs(const T &t)
Definition: Abs.h:22
std::vector< float > jet_pfcand_electron_sigIphiIphi
void produce(edm::Event &, const edm::EventSetup &) override
ParticleNetFeatureEvaluator(const edm::ParameterSet &)
float segmentCompatibility(const reco::Muon &muon, reco::Muon::ArbitrationType arbitrationType=reco::Muon::SegmentAndTrackArbitration)
void fillLostTrackFeatures(DeepBoostedJetFeatures &fts, const reco::Jet &jet)
#define DEFINE_FWK_MODULE(type)
Definition: MakerMacros.h:16
Measurement1D signedDistance(const reco::Vertex &primVtx, const reco::Vertex &secVtx, const GlobalVector &momentum) const override
void fillParticleFeatures(DeepBoostedJetFeatures &fts, const reco::Jet &jet, const std::vector< math::XYZTLorentzVector > &tau_pfcandidates, const pat::MuonCollection &muons, const pat::ElectronCollection &electrons, const pat::PhotonCollection &photons)
edm::EDGetTokenT< reco::VertexCompositePtrCandidateCollection > sv_token_
edm::ESGetToken< TransientTrackBuilder, TransientTrackRecord > track_builder_token_
std::vector< Electron > ElectronCollection
collectin of Electron objects
Definition: ElectronFwd.h:9
edm::Ref< VertexCollection > VertexRef
persistent reference to a Vertex
Definition: VertexFwd.h:13
ESHandle< T > getHandle(const ESGetToken< T, R > &iToken) const
Definition: EventSetup.h:130
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
constexpr auto deltaR(const T1 &t1, const T2 &t2) -> decltype(t1.eta())
Definition: deltaR.h:30
std::vector< float > jet_pfcand_electron_convProb
constexpr auto deltaR2(const T1 &t1, const T2 &t2) -> decltype(t1.eta())
Definition: deltaR.h:16
edm::EDGetTokenT< pat::PhotonCollection > photon_token_
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
bool sv_vertex_comparator(const SVType &sva, const SVType &svb, const PVType &pv)
Definition: deep_helpers.h:54
XYZVectorD XYZVector
spatial vector with cartesian internal representation
Definition: Vector3D.h:31
XYZPointD XYZPoint
point in space with cartesian internal representation
Definition: Point3D.h:12
std::vector< Photon > PhotonCollection
collectin of Photon objects
Definition: PhotonFwd.h:9
double b
Definition: hdecay.h:120
Analysis-level calorimeter jet class.
Definition: Jet.h:77
void add(std::string const &label, ParameterSetDescription const &psetDescription)
bool useTrackProperties(const pat::PackedCandidate *cand)
void fill(const std::string &name, float value)
double value() const
Definition: Measurement1D.h:25
std::vector< Muon > MuonCollection
Definition: Muon.h:35
double significance() const
Definition: Measurement1D.h:29
fixed size matrix
HLT enums.
double a
Definition: hdecay.h:121
edm::EDGetTokenT< edm::ValueMap< float > > puppi_value_map_token_
static const std::vector< std::string > sv_features_
edm::EDGetTokenT< reco::VertexCollection > vtx_token_
std::vector< Photon > PhotonCollection
Definition: Photon.h:31
def move(src, dest)
Definition: eostools.py:511
void fillSVFeatures(DeepBoostedJetFeatures &fts, const reco::Jet &jet)
edm::EDGetTokenT< edm::View< reco::Candidate > > pfcand_token_