CMS 3D CMS Logo

PFElectronTranslator.cc
Go to the documentation of this file.
20 
21 class DetId;
22 namespace edm {
23  class EventSetup;
24 } // namespace edm
25 
27 public:
28  explicit PFElectronTranslator(const edm::ParameterSet&);
29  ~PFElectronTranslator() override;
30 
31  void produce(edm::Event&, const edm::EventSetup&) override;
32 
33  typedef std::vector<edm::Handle<edm::ValueMap<double>>> IsolationValueMaps;
34 
35 private:
36  // to retrieve the collection from the event
38  const edm::InputTag& tag,
39  const edm::Event& iEvent) const;
40  // to retrieve the collection from the event
42  const edm::InputTag& tag,
43  const edm::Event& iEvent) const;
44 
45  // makes a basic cluster from PFBlockElement and add it to the collection ; the corrected energy is taken
46  // from the PFCandidate
48  reco::BasicClusterCollection& basicClusters,
49  std::vector<const reco::PFCluster*>&,
50  const reco::PFCandidate& coCandidate) const;
51  // makes a preshower cluster from of PFBlockElement and add it to the collection
53  reco::PreshowerClusterCollection& preshowerClusters,
54  unsigned plane) const;
55 
56  // make a super cluster from its ingredients and add it to the collection
58 
59  // make GsfElectronCores from ingredients
61 
62  // create the basic cluster Ptr
64 
65  // create the preshower cluster Refs
67 
68  // create the super cluster Refs
70 
71  // create the GsfElectronCore Refs
73 
74  // create the GsfElectrons
78 
79  // The following methods are used to fill the value maps
83  void getAmbiguousGsfTracks(const reco::PFBlockElement& PFBE, std::vector<reco::GsfTrackRef>&) const;
84 
86  const reco::PFBlockElement& pfbe) const;
87 
88 private:
92  std::vector<edm::InputTag> inputTagIsoVals_;
100  double MVACut_;
102 
103  // The following vectors correspond to a GSF track, but the order is not
104  // the order of the tracks in the GSF track collection
105  std::vector<reco::GsfTrackRef> GsfTrackRef_;
106  // the list of candidatePtr
107  std::vector<reco::CandidatePtr> CandidatePtr_;
108  //the list of KfTrackRef
109  std::vector<reco::TrackRef> kfTrackRef_;
110  // the list of ambiguous tracks
111  std::vector<std::vector<reco::GsfTrackRef>> ambiguousGsfTracks_;
112  // the collection of basic clusters associated to a GSF track
113  std::vector<reco::BasicClusterCollection> basicClusters_;
114  // the correcsponding PFCluster ref
115  std::vector<std::vector<const reco::PFCluster*>> pfClusters_;
116  // the collection of preshower clusters associated to a GSF track
117  std::vector<reco::PreshowerClusterCollection> preshowerClusters_;
118  // the super cluster collection (actually only one) associated to a GSF track
119  std::vector<reco::SuperClusterCollection> superClusters_;
120  // the references to the basic clusters associated to a GSF track
121  std::vector<reco::CaloClusterPtrVector> basicClusterPtr_;
122  // the references to the basic clusters associated to a GSF track
123  std::vector<reco::CaloClusterPtrVector> preshowerClusterPtr_;
124  // the references to the GsfElectonCore associated to a GSF track
125  std::vector<reco::GsfElectronCoreRef> gsfElectronCoreRefs_;
126  // keep track of the index of the PF Candidate
127  std::vector<int> gsfPFCandidateIndex_;
128  // maps to ease the creation of the Value Maps
129  std::map<reco::GsfTrackRef, reco::SuperClusterRef> scMap_;
130  std::map<reco::GsfTrackRef, float> gsfMvaMap_;
131 
133 };
134 
136 
138  inputTagPFCandidates_ = iConfig.getParameter<edm::InputTag>("PFCandidate");
139  inputTagPFCandidateElectrons_ = iConfig.getParameter<edm::InputTag>("PFCandidateElectron");
140  inputTagGSFTracks_ = iConfig.getParameter<edm::InputTag>("GSFTracks");
141 
142  bool useIsolationValues = iConfig.getParameter<bool>("useIsolationValues");
143  if (useIsolationValues) {
144  if (!iConfig.exists("isolationValues"))
145  throw cms::Exception("PFElectronTranslator|InternalError") << "Missing ParameterSet isolationValues";
146  else {
147  edm::ParameterSet isoVals = iConfig.getParameter<edm::ParameterSet>("isolationValues");
148  inputTagIsoVals_.push_back(isoVals.getParameter<edm::InputTag>("pfSumChargedHadronPt"));
149  inputTagIsoVals_.push_back(isoVals.getParameter<edm::InputTag>("pfSumPhotonEt"));
150  inputTagIsoVals_.push_back(isoVals.getParameter<edm::InputTag>("pfSumNeutralHadronEt"));
151  inputTagIsoVals_.push_back(isoVals.getParameter<edm::InputTag>("pfSumPUPt"));
152  }
153  }
154 
155  PFBasicClusterCollection_ = iConfig.getParameter<std::string>("PFBasicClusters");
156  PFPreshowerClusterCollection_ = iConfig.getParameter<std::string>("PFPreshowerClusters");
157  PFSuperClusterCollection_ = iConfig.getParameter<std::string>("PFSuperClusters");
158  GsfElectronCoreCollection_ = iConfig.getParameter<std::string>("PFGsfElectronCore");
159  GsfElectronCollection_ = iConfig.getParameter<std::string>("PFGsfElectron");
160 
161  PFMVAValueMap_ = iConfig.getParameter<std::string>("ElectronMVA");
162  PFSCValueMap_ = iConfig.getParameter<std::string>("ElectronSC");
163  MVACut_ = (iConfig.getParameter<edm::ParameterSet>("MVACutBlock")).getParameter<double>("MVACut");
164  checkStatusFlag_ = iConfig.getParameter<bool>("CheckStatusFlag");
165 
166  if (iConfig.exists("emptyIsOk"))
167  emptyIsOk_ = iConfig.getParameter<bool>("emptyIsOk");
168  else
169  emptyIsOk_ = false;
170 
171  produces<reco::BasicClusterCollection>(PFBasicClusterCollection_);
172  produces<reco::PreshowerClusterCollection>(PFPreshowerClusterCollection_);
173  produces<reco::SuperClusterCollection>(PFSuperClusterCollection_);
174  produces<reco::GsfElectronCoreCollection>(GsfElectronCoreCollection_);
175  produces<reco::GsfElectronCollection>(GsfElectronCollection_);
176  produces<edm::ValueMap<float>>(PFMVAValueMap_);
177  produces<edm::ValueMap<reco::SuperClusterRef>>(PFSCValueMap_);
178 }
179 
181 
183  auto gsfElectronCores_p = std::make_unique<reco::GsfElectronCoreCollection>();
184 
185  auto gsfElectrons_p = std::make_unique<reco::GsfElectronCollection>();
186 
187  auto superClusters_p = std::make_unique<reco::SuperClusterCollection>();
188 
189  auto basicClusters_p = std::make_unique<reco::BasicClusterCollection>();
190 
191  auto psClusters_p = std::make_unique<reco::PreshowerClusterCollection>();
192 
193  auto mvaMap_p = std::make_unique<edm::ValueMap<float>>();
194  edm::ValueMap<float>::Filler mvaFiller(*mvaMap_p);
195 
196  auto scMap_p = std::make_unique<edm::ValueMap<reco::SuperClusterRef>>();
197  edm::ValueMap<reco::SuperClusterRef>::Filler scRefFiller(*scMap_p);
198 
201 
203  for (size_t j = 0; j < inputTagIsoVals_.size(); ++j) {
204  iEvent.getByLabel(inputTagIsoVals_[j], isolationValues[j]);
205  }
206 
207  // clear the vectors
208  GsfTrackRef_.clear();
209  CandidatePtr_.clear();
210  ambiguousGsfTracks_.clear();
211  kfTrackRef_.clear();
212  basicClusters_.clear();
213  pfClusters_.clear();
214  preshowerClusters_.clear();
215  superClusters_.clear();
216  basicClusterPtr_.clear();
217  preshowerClusterPtr_.clear();
218  gsfPFCandidateIndex_.clear();
219  gsfElectronCoreRefs_.clear();
220  scMap_.clear();
221 
222  // loop on the candidates
223  //CC@@
224  // we need first to create AND put the SuperCluster,
225  // basic clusters and presh clusters collection
226  // in order to get a working Handle
227  unsigned ncand = (status) ? pfCandidates->size() : 0;
228  unsigned iGSF = 0;
229  for (unsigned i = 0; i < ncand; ++i) {
230  const reco::PFCandidate& cand = (*pfCandidates)[i];
231  if (cand.particleId() != reco::PFCandidate::e)
232  continue;
233  if (cand.gsfTrackRef().isNull())
234  continue;
235  // Note that -1 will still cut some total garbage candidates
236  // Fill the MVA map
237  if (cand.mva_e_pi() < MVACut_)
238  continue;
239 
240  // Check the status flag
241  if (checkStatusFlag_ && !cand.electronExtraRef()->electronStatus(reco::PFCandidateElectronExtra::Selected)) {
242  continue;
243  }
244 
245  GsfTrackRef_.push_back(cand.gsfTrackRef());
246  kfTrackRef_.push_back(cand.trackRef());
247  gsfPFCandidateIndex_.push_back(i);
248 
249  reco::PFCandidatePtr ptrToPFElectron(pfCandidates, i);
250  //CandidatePtr_.push_back(ptrToPFElectron->sourceCandidatePtr(0));
251  CandidatePtr_.push_back(ptrToPFElectron);
252 
254  pfClusters_.push_back(std::vector<const reco::PFCluster*>());
256  ambiguousGsfTracks_.push_back(std::vector<reco::GsfTrackRef>());
257 
258  for (unsigned iele = 0; iele < cand.elementsInBlocks().size(); ++iele) {
259  // first get the block
260  reco::PFBlockRef blockRef = cand.elementsInBlocks()[iele].first;
261  //
262  unsigned elementIndex = cand.elementsInBlocks()[iele].second;
263  // check it actually exists
264  if (blockRef.isNull())
265  continue;
266 
267  // then get the elements of the block
268  const edm::OwnVector<reco::PFBlockElement>& elements = (*blockRef).elements();
269 
270  const reco::PFBlockElement& pfbe(elements[elementIndex]);
271  // The first ECAL element should be the cluster associated to the GSF; defined as the seed
272  if (pfbe.type() == reco::PFBlockElement::ECAL) {
273  // const reco::PFCandidate * coCandidate = &cand;
274  // the Brem photons are saved as daughter PFCandidate; this
275  // is convenient to access the corrected energy
276  // std::cout << " Found candidate " << correspondingDaughterCandidate(coCandidate,pfbe) << " " << coCandidate << std::endl;
278  }
279  if (pfbe.type() == reco::PFBlockElement::PS1) {
281  }
282  if (pfbe.type() == reco::PFBlockElement::PS2) {
284  }
285  if (pfbe.type() == reco::PFBlockElement::GSF) {
287  }
288 
289  } // loop on the elements
290 
291  // save the basic clusters
292  basicClusters_p->insert(basicClusters_p->end(), basicClusters_[iGSF].begin(), basicClusters_[iGSF].end());
293  // save the preshower clusters
294  psClusters_p->insert(psClusters_p->end(), preshowerClusters_[iGSF].begin(), preshowerClusters_[iGSF].end());
295 
296  ++iGSF;
297  } // loop on PFCandidates
298 
299  //Save the basic clusters and get an handle as to be able to create valid Refs (thanks to Claude)
300  // std::cout << " Number of basic clusters " << basicClusters_p->size() << std::endl;
302  iEvent.put(std::move(basicClusters_p), PFBasicClusterCollection_);
303 
304  //preshower clusters
306  iEvent.put(std::move(psClusters_p), PFPreshowerClusterCollection_);
307 
308  // now that the Basic clusters are in the event, the Ref can be created
309  createBasicClusterPtrs(bcRefProd);
310  // now that the preshower clusters are in the event, the Ref can be created
311  createPreshowerClusterPtrs(psRefProd);
312 
313  // and now the Super cluster can be created with valid references
314  if (status)
315  createSuperClusters(*pfCandidates, *superClusters_p);
316 
317  // Let's put the super clusters in the event
319  iEvent.put(std::move(superClusters_p), PFSuperClusterCollection_);
320  // create the super cluster Ref
321  createSuperClusterGsfMapRefs(scRefProd);
322 
323  // Now create the GsfElectronCoers
324  createGsfElectronCores(*gsfElectronCores_p);
325  // Put them in the as to get to be able to build a Ref
326  const edm::OrphanHandle<reco::GsfElectronCoreCollection> gsfElectronCoreRefProd =
327  iEvent.put(std::move(gsfElectronCores_p), GsfElectronCoreCollection_);
328 
329  // now create the Refs
330  createGsfElectronCoreRefs(gsfElectronCoreRefProd);
331 
332  // now make the GsfElectron
333  createGsfElectrons(*pfCandidates, isolationValues, *gsfElectrons_p);
334  iEvent.put(std::move(gsfElectrons_p), GsfElectronCollection_);
335 
336  fillMVAValueMap(iEvent, mvaFiller);
337  mvaFiller.fill();
338 
339  fillSCRefValueMap(iEvent, scRefFiller);
340  scRefFiller.fill();
341 
342  // MVA map
343  iEvent.put(std::move(mvaMap_p), PFMVAValueMap_);
344  // Gsf-SC map
345  iEvent.put(std::move(scMap_p), PFSCValueMap_);
346 }
347 
349  const edm::InputTag& tag,
350  const edm::Event& iEvent) const {
351  bool found = iEvent.getByLabel(tag, c);
352 
353  if (!found && !emptyIsOk_) {
354  std::ostringstream err;
355  err << " cannot get PFCandidates: " << tag << std::endl;
356  edm::LogError("PFElectronTranslator") << err.str();
357  }
358  return found;
359 }
360 
362  const edm::InputTag& tag,
363  const edm::Event& iEvent) const {
364  bool found = iEvent.getByLabel(tag, c);
365 
366  if (!found) {
367  std::ostringstream err;
368  err << " cannot get GSFTracks: " << tag << std::endl;
369  edm::LogError("PFElectronTranslator") << err.str();
370  throw cms::Exception("MissingProduct", err.str());
371  }
372 }
373 
374 // The basic cluster is a copy of the PFCluster -> the energy is not corrected
375 // It should be possible to get the corrected energy (including the associated PS energy)
376 // from the PFCandidate daugthers ; Needs some work
378  reco::BasicClusterCollection& basicClusters,
379  std::vector<const reco::PFCluster*>& pfClusters,
380  const reco::PFCandidate& coCandidate) const {
381  const reco::PFClusterRef& myPFClusterRef = PFBE.clusterRef();
382  if (myPFClusterRef.isNull())
383  return;
384 
385  const reco::PFCluster& myPFCluster(*myPFClusterRef);
386  pfClusters.push_back(&myPFCluster);
387  // std::cout << " Creating BC " << myPFCluster.energy() << " " << coCandidate.ecalEnergy() <<" "<< coCandidate.rawEcalEnergy() <<std::endl;
388  // std::cout << " # hits " << myPFCluster.hitsAndFractions().size() << std::endl;
389 
390  // basicClusters.push_back(reco::CaloCluster(myPFCluster.energy(),
391  basicClusters.push_back(reco::CaloCluster(
392  // myPFCluster.energy(),
393  coCandidate.rawEcalEnergy(),
394  myPFCluster.position(),
395  myPFCluster.caloID(),
396  myPFCluster.hitsAndFractions(),
397  myPFCluster.algo(),
398  myPFCluster.seed()));
399 }
400 
402  reco::PreshowerClusterCollection& preshowerClusters,
403  unsigned plane) const {
404  const reco::PFClusterRef& myPFClusterRef = PFBE.clusterRef();
405  preshowerClusters.push_back(reco::PreshowerCluster(
406  myPFClusterRef->energy(), myPFClusterRef->position(), myPFClusterRef->hitsAndFractions(), plane));
407 }
408 
410  const edm::OrphanHandle<reco::BasicClusterCollection>& basicClustersHandle) {
411  unsigned size = GsfTrackRef_.size();
412  unsigned basicClusterCounter = 0;
413  basicClusterPtr_.resize(size);
414 
415  for (unsigned iGSF = 0; iGSF < size; ++iGSF) // loop on tracks
416  {
417  unsigned nbc = basicClusters_[iGSF].size();
418  for (unsigned ibc = 0; ibc < nbc; ++ibc) // loop on basic clusters
419  {
420  // std::cout << "Track "<< iGSF << " ref " << basicClusterCounter << std::endl;
421  reco::CaloClusterPtr bcPtr(basicClustersHandle, basicClusterCounter);
422  basicClusterPtr_[iGSF].push_back(bcPtr);
423  ++basicClusterCounter;
424  }
425  }
426 }
427 
429  const edm::OrphanHandle<reco::PreshowerClusterCollection>& preshowerClustersHandle) {
430  unsigned size = GsfTrackRef_.size();
431  unsigned psClusterCounter = 0;
432  preshowerClusterPtr_.resize(size);
433 
434  for (unsigned iGSF = 0; iGSF < size; ++iGSF) // loop on tracks
435  {
436  unsigned nbc = preshowerClusters_[iGSF].size();
437  for (unsigned ibc = 0; ibc < nbc; ++ibc) // loop on basic clusters
438  {
439  // std::cout << "Track "<< iGSF << " ref " << basicClusterCounter << std::endl;
440  reco::CaloClusterPtr psPtr(preshowerClustersHandle, psClusterCounter);
441  preshowerClusterPtr_[iGSF].push_back(psPtr);
442  ++psClusterCounter;
443  }
444  }
445 }
446 
448  const edm::OrphanHandle<reco::SuperClusterCollection>& superClustersHandle) {
449  unsigned size = GsfTrackRef_.size();
450 
451  for (unsigned iGSF = 0; iGSF < size; ++iGSF) // loop on tracks
452  {
453  edm::Ref<reco::SuperClusterCollection> scRef(superClustersHandle, iGSF);
454  scMap_[GsfTrackRef_[iGSF]] = scRef;
455  }
456 }
457 
459  gsfMvaMap_.clear();
462 
463  unsigned ncand = (status) ? pfCandidates->size() : 0;
464  for (unsigned i = 0; i < ncand; ++i) {
465  const reco::PFCandidate& cand = (*pfCandidates)[i];
466  if (cand.particleId() != reco::PFCandidate::e)
467  continue;
468  if (cand.gsfTrackRef().isNull())
469  continue;
470  // Fill the MVA map
471  gsfMvaMap_[cand.gsfTrackRef()] = cand.mva_e_pi();
472  }
473 
476  unsigned ngsf = gsfTracks->size();
477  std::vector<float> values;
478  for (unsigned igsf = 0; igsf < ngsf; ++igsf) {
479  reco::GsfTrackRef theTrackRef(gsfTracks, igsf);
480  std::map<reco::GsfTrackRef, float>::const_iterator itcheck = gsfMvaMap_.find(theTrackRef);
481  if (itcheck == gsfMvaMap_.end()) {
482  // edm::LogWarning("PFElectronTranslator") << "MVA Map, missing GSF track ref " << std::endl;
483  values.push_back(-99.);
484  // std::cout << " Push_back -99. " << std::endl;
485  } else {
486  // std::cout << " Value " << itcheck->second << std::endl;
487  values.push_back(itcheck->second);
488  }
489  }
490  filler.insert(gsfTracks, values.begin(), values.end());
491 }
492 
497  unsigned ngsf = gsfTracks->size();
498  std::vector<reco::SuperClusterRef> values;
499  for (unsigned igsf = 0; igsf < ngsf; ++igsf) {
500  reco::GsfTrackRef theTrackRef(gsfTracks, igsf);
501  std::map<reco::GsfTrackRef, reco::SuperClusterRef>::const_iterator itcheck = scMap_.find(theTrackRef);
502  if (itcheck == scMap_.end()) {
503  // edm::LogWarning("PFElectronTranslator") << "SCRef Map, missing GSF track ref" << std::endl;
504  values.push_back(reco::SuperClusterRef());
505  } else {
506  values.push_back(itcheck->second);
507  }
508  }
509  filler.insert(gsfTracks, values.begin(), values.end());
510 }
511 
514  unsigned nGSF = GsfTrackRef_.size();
515  for (unsigned iGSF = 0; iGSF < nGSF; ++iGSF) {
516  // Computes energy position a la e/gamma
517  double sclusterE = 0;
518  double posX = 0.;
519  double posY = 0.;
520  double posZ = 0.;
521 
522  unsigned nbasics = basicClusters_[iGSF].size();
523  for (unsigned ibc = 0; ibc < nbasics; ++ibc) {
524  double e = basicClusters_[iGSF][ibc].energy();
525  sclusterE += e;
526  posX += e * basicClusters_[iGSF][ibc].position().X();
527  posY += e * basicClusters_[iGSF][ibc].position().Y();
528  posZ += e * basicClusters_[iGSF][ibc].position().Z();
529  }
530  posX /= sclusterE;
531  posY /= sclusterE;
532  posZ /= sclusterE;
533 
534  if (pfCand[gsfPFCandidateIndex_[iGSF]].gsfTrackRef() != GsfTrackRef_[iGSF]) {
535  edm::LogError("PFElectronTranslator") << " Major problem in PFElectron Translator" << std::endl;
536  }
537 
538  // compute the width
539  PFClusterWidthAlgo pfwidth(pfClusters_[iGSF]);
540 
541  double correctedEnergy = pfCand[gsfPFCandidateIndex_[iGSF]].ecalEnergy();
542  reco::SuperCluster mySuperCluster(correctedEnergy, math::XYZPoint(posX, posY, posZ));
543  // protection against empty basic cluster collection ; the value is -2 in this case
544  if (nbasics) {
545  // std::cout << "SuperCluster creation; energy " << pfCand[gsfPFCandidateIndex_[iGSF]].ecalEnergy();
546  // std::cout << " " << pfCand[gsfPFCandidateIndex_[iGSF]].rawEcalEnergy() << std::endl;
547  // std::cout << "Seed energy from basic " << basicClusters_[iGSF][0].energy() << std::endl;
548  mySuperCluster.setSeed(basicClusterPtr_[iGSF][0]);
549  } else {
550  // std::cout << "SuperCluster creation ; seed energy " << 0 << std::endl;
551  // std::cout << "SuperCluster creation ; energy " << pfCand[gsfPFCandidateIndex_[iGSF]].ecalEnergy();
552  // std::cout << " " << pfCand[gsfPFCandidateIndex_[iGSF]].rawEcalEnergy() << std::endl;
553  // std::cout << " No seed found " << 0 << std::endl;
554  // std::cout << " MVA " << pfCand[gsfPFCandidateIndex_[iGSF]].mva_e_pi() << std::endl;
555  mySuperCluster.setSeed(reco::CaloClusterPtr());
556  }
557  // the seed should be the first basic cluster
558 
559  for (unsigned ibc = 0; ibc < nbasics; ++ibc) {
560  mySuperCluster.addCluster(basicClusterPtr_[iGSF][ibc]);
561  // std::cout <<"Adding Ref to SC " << basicClusterPtr_[iGSF][ibc].index() << std::endl;
562  const std::vector<std::pair<DetId, float>>& v1 = basicClusters_[iGSF][ibc].hitsAndFractions();
563  // std::cout << " Number of cells " << v1.size() << std::endl;
564  for (std::vector<std::pair<DetId, float>>::const_iterator diIt = v1.begin(); diIt != v1.end(); ++diIt) {
565  // std::cout << " Adding DetId " << (diIt->first).rawId() << " " << diIt->second << std::endl;
566  mySuperCluster.addHitAndFraction(diIt->first, diIt->second);
567  } // loop over rechits
568  }
569 
570  unsigned nps = preshowerClusterPtr_[iGSF].size();
571  for (unsigned ips = 0; ips < nps; ++ips) {
572  mySuperCluster.addPreshowerCluster(preshowerClusterPtr_[iGSF][ips]);
573  }
574 
575  // Set the preshower energy
576  mySuperCluster.setPreshowerEnergy(pfCand[gsfPFCandidateIndex_[iGSF]].pS1Energy() +
577  pfCand[gsfPFCandidateIndex_[iGSF]].pS2Energy());
578 
579  // Set the cluster width
580  mySuperCluster.setEtaWidth(pfwidth.pflowEtaWidth());
581  mySuperCluster.setPhiWidth(pfwidth.pflowPhiWidth());
582  // Force the computation of rawEnergy_ of the reco::SuperCluster
583  mySuperCluster.rawEnergy();
584  superClusters.push_back(mySuperCluster);
585  }
586 }
587 
589  const reco::PFBlockElement& pfbe) const {
590  unsigned refindex = pfbe.index();
591  // std::cout << " N daughters " << cand.numberOfDaughters() << std::endl;
592  reco::PFCandidate::const_iterator myDaughterCandidate = cand.begin();
594 
595  for (; myDaughterCandidate != itend; ++myDaughterCandidate) {
596  const reco::PFCandidate* myPFCandidate = (const reco::PFCandidate*)&*myDaughterCandidate;
597  if (myPFCandidate->elementsInBlocks().size() != 1) {
598  // std::cout << " Daughter with " << myPFCandidate.elementsInBlocks().size()<< " element in block " << std::endl;
599  return cand;
600  }
601  if (myPFCandidate->elementsInBlocks()[0].second == refindex) {
602  // std::cout << " Found it " << cand << std::endl;
603  return *myPFCandidate;
604  }
605  }
606  return cand;
607 }
608 
610  unsigned nGSF = GsfTrackRef_.size();
611  for (unsigned iGSF = 0; iGSF < nGSF; ++iGSF) {
612  reco::GsfElectronCore myElectronCore(GsfTrackRef_[iGSF]);
613  myElectronCore.setCtfTrack(kfTrackRef_[iGSF], -1.);
614  std::map<reco::GsfTrackRef, reco::SuperClusterRef>::const_iterator itcheck = scMap_.find(GsfTrackRef_[iGSF]);
615  if (itcheck != scMap_.end())
616  myElectronCore.setParentSuperCluster(itcheck->second);
617  gsfElectronCores.push_back(myElectronCore);
618  }
619 }
620 
622  const edm::OrphanHandle<reco::GsfElectronCoreCollection>& gsfElectronCoreHandle) {
623  unsigned size = GsfTrackRef_.size();
624 
625  for (unsigned iGSF = 0; iGSF < size; ++iGSF) // loop on tracks
626  {
627  edm::Ref<reco::GsfElectronCoreCollection> elecCoreRef(gsfElectronCoreHandle, iGSF);
628  gsfElectronCoreRefs_.push_back(elecCoreRef);
629  }
630 }
631 
633  std::vector<reco::GsfTrackRef>& tracks) const {
634  const reco::PFBlockElementGsfTrack* GsfEl = dynamic_cast<const reco::PFBlockElementGsfTrack*>(&PFBE);
635  if (GsfEl == nullptr)
636  return;
637  const std::vector<reco::GsfPFRecTrackRef>& ambPFRecTracks(GsfEl->GsftrackRefPF()->convBremGsfPFRecTrackRef());
638  unsigned ntracks = ambPFRecTracks.size();
639  for (unsigned it = 0; it < ntracks; ++it) {
640  tracks.push_back(ambPFRecTracks[it]->gsfTrackRef());
641  }
642 }
643 
646  reco::GsfElectronCollection& gsfelectrons) {
647  unsigned size = GsfTrackRef_.size();
648 
649  for (unsigned iGSF = 0; iGSF < size; ++iGSF) // loop on tracks
650  {
651  const reco::PFCandidate& pfCandidate(pfcand[gsfPFCandidateIndex_[iGSF]]);
652  // Electron
653  reco::GsfElectron myElectron(gsfElectronCoreRefs_[iGSF]);
654  // Warning set p4 error !
655  myElectron.setP4(reco::GsfElectron::P4_PFLOW_COMBINATION, pfCandidate.p4(), pfCandidate.deltaP(), true);
656 
657  // MVA inputs
658  reco::GsfElectron::MvaInput myMvaInput;
659  myMvaInput.earlyBrem = pfCandidate.electronExtraRef()->mvaVariable(reco::PFCandidateElectronExtra::MVA_FirstBrem);
660  myMvaInput.lateBrem = pfCandidate.electronExtraRef()->mvaVariable(reco::PFCandidateElectronExtra::MVA_LateBrem);
661  myMvaInput.deltaEta =
663  myMvaInput.sigmaEtaEta = pfCandidate.electronExtraRef()->sigmaEtaEta();
664  myMvaInput.hadEnergy = pfCandidate.electronExtraRef()->hadEnergy();
665 
666  // Mustache
667  reco::Mustache myMustache;
668  myMustache.MustacheID(
669  *(myElectron.parentSuperCluster()), myMvaInput.nClusterOutsideMustache, myMvaInput.etOutsideMustache);
670 
671  myElectron.setMvaInput(myMvaInput);
672 
673  // MVA output
674  reco::GsfElectron::MvaOutput myMvaOutput;
675  myMvaOutput.status = pfCandidate.electronExtraRef()->electronStatus();
676  myMvaOutput.mva_e_pi = pfCandidate.mva_e_pi();
677  myElectron.setMvaOutput(myMvaOutput);
678 
679  // ambiguous tracks
680  unsigned ntracks = ambiguousGsfTracks_[iGSF].size();
681  for (unsigned it = 0; it < ntracks; ++it) {
682  myElectron.addAmbiguousGsfTrack(ambiguousGsfTracks_[iGSF][it]);
683  }
684 
685  // isolation
686  if (!isolationValues.empty()) {
688  myPFIso.sumChargedHadronPt = (*isolationValues[0])[CandidatePtr_[iGSF]];
689  myPFIso.sumPhotonEt = (*isolationValues[1])[CandidatePtr_[iGSF]];
690  myPFIso.sumNeutralHadronEt = (*isolationValues[2])[CandidatePtr_[iGSF]];
691  myPFIso.sumPUPt = (*isolationValues[3])[CandidatePtr_[iGSF]];
692  myElectron.setPfIsolationVariables(myPFIso);
693  }
694 
695  gsfelectrons.push_back(myElectron);
696  }
697 }
reco::GsfElectron::MvaInput::etOutsideMustache
float etOutsideMustache
Definition: GsfElectron.h:638
GsfElectronCore.h
PFElectronTranslator::kfTrackRef_
std::vector< reco::TrackRef > kfTrackRef_
Definition: PFElectronTranslator.cc:109
zmumugammaAnalyzer_cfi.pfCandidates
pfCandidates
Definition: zmumugammaAnalyzer_cfi.py:11
reco::GsfElectron::MvaInput::hadEnergy
float hadEnergy
Definition: GsfElectron.h:635
PDWG_EXOHSCP_cff.tracks
tracks
Definition: PDWG_EXOHSCP_cff.py:28
mps_fire.i
i
Definition: mps_fire.py:355
PFClusterWidthAlgo::pflowEtaWidth
double pflowEtaWidth() const
Definition: PFClusterWidthAlgo.h:15
MessageLogger.h
PFElectronTranslator::fillValueMap
void fillValueMap(edm::Event &iEvent, edm::ValueMap< float >::Filler &filler) const
PFElectronTranslator::PFSCValueMap_
std::string PFSCValueMap_
Definition: PFElectronTranslator.cc:97
PFElectronTranslator::fetchCandidateCollection
bool fetchCandidateCollection(edm::Handle< reco::PFCandidateCollection > &c, const edm::InputTag &tag, const edm::Event &iEvent) const
Definition: PFElectronTranslator.cc:348
electronProducer_cff.isolationValues
isolationValues
Definition: electronProducer_cff.py:26
reco::PFCandidate::e
Definition: PFCandidate.h:46
reco::GsfElectron::parentSuperCluster
virtual SuperClusterRef parentSuperCluster() const
Definition: GsfElectron.h:168
PFElectronTranslator::MVACut_
double MVACut_
Definition: PFElectronTranslator.cc:100
PFCandidate.h
reco::SuperCluster
Definition: SuperCluster.h:18
mps_update.status
status
Definition: mps_update.py:69
reco::PFCandidate::mva_e_pi
float mva_e_pi() const
mva for electron-pion discrimination
Definition: PFCandidate.h:316
BasicCluster.h
edm::Ref::isNull
bool isNull() const
Checks for null.
Definition: Ref.h:235
PFElectronTranslator::gsfElectronCoreRefs_
std::vector< reco::GsfElectronCoreRef > gsfElectronCoreRefs_
Definition: PFElectronTranslator.cc:125
edm
HLT enums.
Definition: AlignableModifier.h:19
reco::GsfElectron::MvaOutput::mva_e_pi
float mva_e_pi
Definition: GsfElectron.h:652
reco::GsfElectron::PflowIsolationVariables
Definition: GsfElectron.h:606
reco::SuperCluster::setEtaWidth
void setEtaWidth(double ew)
Definition: SuperCluster.h:74
PreshowerCluster.h
reco::PreshowerCluster
Definition: PreshowerCluster.h:17
reco::candidate::const_iterator
Definition: const_iterator.h:14
PFElectronTranslator::scMap_
std::map< reco::GsfTrackRef, reco::SuperClusterRef > scMap_
Definition: PFElectronTranslator.cc:129
reco::PFCandidateElectronExtra::MVA_FirstBrem
Definition: PFCandidateElectronExtra.h:43
PFElectronTranslator::CandidatePtr_
std::vector< reco::CandidatePtr > CandidatePtr_
Definition: PFElectronTranslator.cc:107
EDProducer.h
PFElectronTranslator::emptyIsOk_
bool emptyIsOk_
Definition: PFElectronTranslator.cc:132
PFElectronTranslator::createGsfElectronCoreRefs
void createGsfElectronCoreRefs(const edm::OrphanHandle< reco::GsfElectronCoreCollection > &gsfElectronCoreHandle)
Definition: PFElectronTranslator.cc:621
PFElectronTranslator::inputTagGSFTracks_
edm::InputTag inputTagGSFTracks_
Definition: PFElectronTranslator.cc:91
reco::GsfElectronCollection
std::vector< GsfElectron > GsfElectronCollection
collection of GsfElectron objects
Definition: GsfElectronFwd.h:14
PFElectronTranslator::gsfMvaMap_
std::map< reco::GsfTrackRef, float > gsfMvaMap_
Definition: PFElectronTranslator.cc:130
PFElectronTranslator::IsolationValueMaps
std::vector< edm::Handle< edm::ValueMap< double > > > IsolationValueMaps
Definition: PFElectronTranslator.cc:33
reco::SuperCluster::setPreshowerEnergy
void setPreshowerEnergy(double preshowerEnergy)
Definition: SuperCluster.h:70
reco::PFCandidate::elementsInBlocks
const ElementsInBlocks & elementsInBlocks() const
Definition: PFCandidate.cc:636
PFElectronTranslator::createBasicClusterPtrs
void createBasicClusterPtrs(const edm::OrphanHandle< reco::BasicClusterCollection > &basicClustersHandle)
Definition: PFElectronTranslator.cc:409
newFWLiteAna.found
found
Definition: newFWLiteAna.py:118
edm::Handle
Definition: AssociativeIterator.h:50
PFElectronTranslator::PFMVAValueMap_
std::string PFMVAValueMap_
Definition: PFElectronTranslator.cc:96
Mustache.h
edm::Ref< PFBlockCollection >
PFClusterWidthAlgo::pflowPhiWidth
double pflowPhiWidth() const
Definition: PFClusterWidthAlgo.h:14
pfDeepBoostedJetPreprocessParams_cfi.pfcand
pfcand
Definition: pfDeepBoostedJetPreprocessParams_cfi.py:8
reco::GsfElectron::MvaInput::sigmaEtaEta
float sigmaEtaEta
Definition: GsfElectron.h:634
reco::SuperCluster::addCluster
void addCluster(const CaloClusterPtr &r)
add reference to constituent BasicCluster
Definition: SuperCluster.h:122
reco::Mustache
Definition: Mustache.h:18
reco::SuperCluster::setSeed
void setSeed(const CaloClusterPtr &r)
list of used xtals by DetId // now inherited by CaloCluster
Definition: SuperCluster.h:107
reco::SuperClusterCollection
std::vector< SuperCluster > SuperClusterCollection
collection of SuperCluser objectr
Definition: SuperClusterFwd.h:9
DetId
Definition: DetId.h:17
MakerMacros.h
reco::GsfElectron::setP4
void setP4(P4Kind kind, const LorentzVector &p4, float p4Error, bool setCandidate)
Definition: GsfElectron.cc:188
reco::GsfElectron::PflowIsolationVariables::sumPhotonEt
float sumPhotonEt
sum pt of PF photons // old float photonIso ;
Definition: GsfElectron.h:610
reco::PFCandidate::deltaP
double deltaP() const
uncertainty on 3-momentum
Definition: PFCandidate.h:300
PFElectronTranslator::gsfPFCandidateIndex_
std::vector< int > gsfPFCandidateIndex_
Definition: PFElectronTranslator.cc:127
reco::GsfElectron::PflowIsolationVariables::sumPUPt
float sumPUPt
sum pt of charged Particles not from PV (for Pu corrections)
Definition: GsfElectron.h:615
reco::GsfElectron::MvaInput::deltaEta
float deltaEta
Definition: GsfElectron.h:636
DEFINE_FWK_MODULE
#define DEFINE_FWK_MODULE(type)
Definition: MakerMacros.h:16
GlobalPosition_Frontier_DevDB_cff.tag
tag
Definition: GlobalPosition_Frontier_DevDB_cff.py:11
PFElectronTranslator::~PFElectronTranslator
~PFElectronTranslator() override
Definition: PFElectronTranslator.cc:180
contentValuesCheck.values
values
Definition: contentValuesCheck.py:38
pfElectronTranslator_cfi.useIsolationValues
useIsolationValues
Definition: pfElectronTranslator_cfi.py:19
reco::GsfElectronCoreCollection
std::vector< GsfElectronCore > GsfElectronCoreCollection
Definition: GsfElectronCoreFwd.h:12
reco::CaloCluster
Definition: CaloCluster.h:31
PFElectronTranslator::correspondingDaughterCandidate
const reco::PFCandidate & correspondingDaughterCandidate(const reco::PFCandidate &cand, const reco::PFBlockElement &pfbe) const
Definition: PFElectronTranslator.cc:588
PFBlockElement.h
PFElectronTranslator::getAmbiguousGsfTracks
void getAmbiguousGsfTracks(const reco::PFBlockElement &PFBE, std::vector< reco::GsfTrackRef > &) const
Definition: PFElectronTranslator.cc:632
PFElectronTranslator::createGsfElectrons
void createGsfElectrons(const reco::PFCandidateCollection &, const IsolationValueMaps &isolationValues, reco::GsfElectronCollection &)
Definition: PFElectronTranslator.cc:644
PFCluster.h
reco::PFCandidate::rawEcalEnergy
double rawEcalEnergy() const
return corrected Ecal energy
Definition: PFCandidate.h:223
PFElectronTranslator::PFBasicClusterCollection_
std::string PFBasicClusterCollection_
Definition: PFElectronTranslator.cc:93
reco::PreshowerClusterCollection
std::vector< PreshowerCluster > PreshowerClusterCollection
collection of PreshowerCluster objects
Definition: PreshowerClusterFwd.h:12
RecoTauValidation_cfi.posX
posX
Definition: RecoTauValidation_cfi.py:288
reco::GsfElectron
Definition: GsfElectron.h:35
ecalDrivenGsfElectronCoresFromMultiCl_cff.gsfTracks
gsfTracks
Definition: ecalDrivenGsfElectronCoresFromMultiCl_cff.py:4
PFElectronTranslator
Definition: PFElectronTranslator.cc:26
GsfElectron.h
PFClusterWidthAlgo.h
PFElectronTranslator::createBasicCluster
void createBasicCluster(const reco::PFBlockElement &, reco::BasicClusterCollection &basicClusters, std::vector< const reco::PFCluster * > &, const reco::PFCandidate &coCandidate) const
Definition: PFElectronTranslator.cc:377
reco::BasicClusterCollection
std::vector< BasicCluster > BasicClusterCollection
collection of BasicCluster objects
Definition: BasicClusterFwd.h:16
reco::GsfElectron::MvaInput
Definition: GsfElectron.h:631
PFElectronTranslator::createPreshowerCluster
void createPreshowerCluster(const reco::PFBlockElement &PFBE, reco::PreshowerClusterCollection &preshowerClusters, unsigned plane) const
Definition: PFElectronTranslator.cc:401
HLT_2018_cff.superClusters
superClusters
Definition: HLT_2018_cff.py:13791
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
PFElectronTranslator::GsfTrackRef_
std::vector< reco::GsfTrackRef > GsfTrackRef_
Definition: PFElectronTranslator.cc:105
PFElectronTranslator::produce
void produce(edm::Event &, const edm::EventSetup &) override
Definition: PFElectronTranslator.cc:182
edm::ParameterSet::exists
bool exists(std::string const &parameterName) const
checks if a parameter exists
Definition: ParameterSet.cc:674
PFElectronTranslator::pfClusters_
std::vector< std::vector< const reco::PFCluster * > > pfClusters_
Definition: PFElectronTranslator.cc:115
PFElectronTranslator::basicClusterPtr_
std::vector< reco::CaloClusterPtrVector > basicClusterPtr_
Definition: PFElectronTranslator.cc:121
PFElectronTranslator::preshowerClusterPtr_
std::vector< reco::CaloClusterPtrVector > preshowerClusterPtr_
Definition: PFElectronTranslator.cc:123
PFElectronTranslator::createSuperClusters
void createSuperClusters(const reco::PFCandidateCollection &, reco::SuperClusterCollection &superClusters) const
Definition: PFElectronTranslator.cc:512
reco::GsfElectron::MvaInput::lateBrem
int lateBrem
Definition: GsfElectron.h:633
PFElectronTranslator::fetchGsfCollection
void fetchGsfCollection(edm::Handle< reco::GsfTrackCollection > &c, const edm::InputTag &tag, const edm::Event &iEvent) const
Definition: PFElectronTranslator.cc:361
edm::ParameterSet
Definition: ParameterSet.h:36
math::XYZPoint
XYZPointD XYZPoint
point in space with cartesian internal representation
Definition: Point3D.h:12
edm::LogError
Definition: MessageLogger.h:183
PFElectronTranslator::createPreshowerClusterPtrs
void createPreshowerClusterPtrs(const edm::OrphanHandle< reco::PreshowerClusterCollection > &preshowerClustersHandle)
Definition: PFElectronTranslator.cc:428
reco::PFBlockElement::GSF
Definition: PFBlockElement.h:37
Event.h
PFElectronTranslator::ambiguousGsfTracks_
std::vector< std::vector< reco::GsfTrackRef > > ambiguousGsfTracks_
Definition: PFElectronTranslator.cc:111
reco::CaloCluster::hitsAndFractions
const std::vector< std::pair< DetId, float > > & hitsAndFractions() const
Definition: CaloCluster.h:210
reco::PFCandidateElectronExtra::MVA_DeltaEtaTrackCluster
Definition: PFCandidateElectronExtra.h:39
runTheMatrix.err
err
Definition: runTheMatrix.py:288
reco::GsfElectronCore::setParentSuperCluster
void setParentSuperCluster(const SuperClusterRef &scl)
Definition: GsfElectronCore.h:81
trigObjTnPSource_cfi.filler
filler
Definition: trigObjTnPSource_cfi.py:21
reco::CaloCluster::addHitAndFraction
void addHitAndFraction(DetId id, float fraction)
Definition: CaloCluster.h:203
reco::GsfElectron::setPfIsolationVariables
void setPfIsolationVariables(const PflowIsolationVariables &iso)
Definition: GsfElectron.h:667
reco::PFCandidate::electronExtraRef
reco::PFCandidateElectronExtraRef electronExtraRef() const
return a reference to the electron extra
Definition: PFCandidate.cc:544
reco::PFBlockElement::ECAL
Definition: PFBlockElement.h:35
cand
Definition: decayParser.h:34
reco::GsfElectron::addAmbiguousGsfTrack
void addAmbiguousGsfTrack(const reco::GsfTrackRef &t)
Definition: GsfElectron.h:699
reco::GsfElectronCore
Definition: GsfElectronCore.h:32
reco::Mustache::MustacheID
void MustacheID(const CaloClusterPtrVector &clusters, int &nclusters, float &EoutsideMustache)
Definition: Mustache.cc:148
iEvent
int iEvent
Definition: GenABIO.cc:224
reco::LeafCandidate::p4
const LorentzVector & p4() const final
four-momentum Lorentz vector
Definition: LeafCandidate.h:114
reco::GsfElectron::MvaInput::earlyBrem
int earlyBrem
Definition: GsfElectron.h:632
PFElectronTranslator::fillSCRefValueMap
void fillSCRefValueMap(edm::Event &iEvent, edm::ValueMap< reco::SuperClusterRef >::Filler &filler) const
Definition: PFElectronTranslator.cc:493
reco::GsfElectron::setMvaOutput
void setMvaOutput(const MvaOutput &mo)
Definition: GsfElectron.h:669
edm::stream::EDProducer
Definition: EDProducer.h:38
edm::EventSetup
Definition: EventSetup.h:57
PFElectronTranslator::GsfElectronCollection_
std::string GsfElectronCollection_
Definition: PFElectronTranslator.cc:99
HltBtagPostValidation_cff.c
c
Definition: HltBtagPostValidation_cff.py:31
reco::SuperCluster::addPreshowerCluster
void addPreshowerCluster(const CaloClusterPtr &r)
add reference to constituent BasicCluster
Definition: SuperCluster.h:128
reco::GsfElectron::setMvaInput
void setMvaInput(const MvaInput &mi)
Definition: GsfElectron.h:668
reco::CaloCluster::seed
DetId seed() const
return DetId of seed
Definition: CaloCluster.h:219
reco::GsfElectron::PflowIsolationVariables::sumNeutralHadronEt
float sumNeutralHadronEt
sum pt of neutral hadrons // old float neutralHadronIso ;
Definition: GsfElectron.h:609
reco::PFBlockElement
Abstract base class for a PFBlock element (track, cluster...)
Definition: PFBlockElement.h:26
PFElectronTranslator::basicClusters_
std::vector< reco::BasicClusterCollection > basicClusters_
Definition: PFElectronTranslator.cc:113
reco::CaloCluster::position
const math::XYZPoint & position() const
cluster centroid position
Definition: CaloCluster.h:154
edm::Ptr< PFCandidate >
ValueMap.h
PFBlock.h
reco::GsfElectron::MvaOutput::status
int status
Definition: GsfElectron.h:650
edm::ParameterSet::getParameter
T getParameter(std::string const &) const
PFElectronTranslator::createGsfElectronCores
void createGsfElectronCores(reco::GsfElectronCoreCollection &) const
Definition: PFElectronTranslator.cc:609
PFElectronTranslator::PFElectronTranslator
PFElectronTranslator(const edm::ParameterSet &)
Definition: PFElectronTranslator.cc:137
reco::PFBlockElementGsfTrack
Track Element.
Definition: PFBlockElementGsfTrack.h:18
bookConverter.elements
elements
Definition: bookConverter.py:147
eostools.move
def move(src, dest)
Definition: eostools.py:511
edm::OrphanHandle
Definition: EDProductfwd.h:39
reco::PFCandidateElectronExtra::MVA_LateBrem
Definition: PFCandidateElectronExtra.h:42
reco::GsfElectron::P4_PFLOW_COMBINATION
Definition: GsfElectron.h:769
PFElectronTranslator::superClusters_
std::vector< reco::SuperClusterCollection > superClusters_
Definition: PFElectronTranslator.cc:119
reco::CaloCluster::algo
AlgoId algo() const
algorithm identifier
Definition: CaloCluster.h:190
reco::SuperCluster::rawEnergy
double rawEnergy() const
raw uncorrected energy (sum of energies of component BasicClusters)
Definition: SuperCluster.h:58
SuperCluster.h
Exception
Definition: hltDiff.cc:246
PFClusterWidthAlgo
Definition: PFClusterWidthAlgo.h:6
reco::PFCandidateElectronExtra::Selected
Definition: PFCandidateElectronExtra.h:20
reco::PFCandidateCollection
std::vector< reco::PFCandidate > PFCandidateCollection
collection of PFCandidates
Definition: PFCandidateFwd.h:12
reco::PFCluster
Particle flow cluster, see clustering algorithm in PFClusterAlgo.
Definition: PFCluster.h:46
PFElectronTranslator::PFSuperClusterCollection_
std::string PFSuperClusterCollection_
Definition: PFElectronTranslator.cc:95
reco::GsfElectron::MvaOutput
Definition: GsfElectron.h:649
reco::CaloCluster::caloID
const CaloID & caloID() const
Definition: CaloCluster.h:201
PFElectronTranslator::preshowerClusters_
std::vector< reco::PreshowerClusterCollection > preshowerClusters_
Definition: PFElectronTranslator.cc:117
PFElectronTranslator::GsfElectronCoreCollection_
std::string GsfElectronCoreCollection_
Definition: PFElectronTranslator.cc:98
reco::SuperCluster::setPhiWidth
void setPhiWidth(double pw)
Definition: SuperCluster.h:73
PFElectronTranslator::inputTagPFCandidates_
edm::InputTag inputTagPFCandidates_
Definition: PFElectronTranslator.cc:89
reco::GsfElectron::MvaInput::nClusterOutsideMustache
int nClusterOutsideMustache
Definition: GsfElectron.h:637
reco::PFBlockElementGsfTrack::GsftrackRefPF
const GsfPFRecTrackRef & GsftrackRefPF() const
Definition: PFBlockElementGsfTrack.h:44
reco::PFBlockElement::type
Type type() const
Definition: PFBlockElement.h:69
reco::PFCandidate
Particle reconstructed by the particle flow algorithm.
Definition: PFCandidate.h:40
PFElectronTranslator::checkStatusFlag_
bool checkStatusFlag_
Definition: PFElectronTranslator.cc:101
cms::Exception
Definition: Exception.h:70
edm::helper::Filler
Definition: ValueMap.h:22
reco::PFBlockElement::PS1
Definition: PFBlockElement.h:33
EventSetup
ParameterSet.h
dqmiolumiharvest.j
j
Definition: dqmiolumiharvest.py:66
reco::PFBlockElement::index
unsigned index() const
Definition: PFBlockElement.h:86
edm::Event
Definition: Event.h:73
PFElectronTranslator::PFPreshowerClusterCollection_
std::string PFPreshowerClusterCollection_
Definition: PFElectronTranslator.cc:94
PFElectronTranslator::fillMVAValueMap
void fillMVAValueMap(edm::Event &iEvent, edm::ValueMap< float >::Filler &filler)
Definition: PFElectronTranslator.cc:458
PFElectronTranslator::inputTagIsoVals_
std::vector< edm::InputTag > inputTagIsoVals_
Definition: PFElectronTranslator.cc:92
PFElectronTranslator::inputTagPFCandidateElectrons_
edm::InputTag inputTagPFCandidateElectrons_
Definition: PFElectronTranslator.cc:90
PFBlockElementGsfTrack.h
edm::InputTag
Definition: InputTag.h:15
RecoTauValidation_cfi.posY
posY
Definition: RecoTauValidation_cfi.py:289
PFCandidateElectronExtra.h
reco::PFBlockElement::PS2
Definition: PFBlockElement.h:34
reco::GsfElectron::PflowIsolationVariables::sumChargedHadronPt
float sumChargedHadronPt
sum-pt of charged Hadron // old float chargedHadronIso ;
Definition: GsfElectron.h:608
edm::OwnVector< reco::PFBlockElement >
reco::GsfElectronCore::setCtfTrack
void setCtfTrack(const TrackRef &closestCtfTrack, float ctfGsfOverlap)
Definition: GsfElectronCore.h:69
PFElectronTranslator::createSuperClusterGsfMapRefs
void createSuperClusterGsfMapRefs(const edm::OrphanHandle< reco::SuperClusterCollection > &superClustersHandle)
Definition: PFElectronTranslator.cc:447
findQualityFiles.size
size
Write out results.
Definition: findQualityFiles.py:443
reco::PFBlockElement::clusterRef
virtual const PFClusterRef & clusterRef() const
Definition: PFBlockElement.h:90
MillePedeFileConverter_cfg.e
e
Definition: MillePedeFileConverter_cfg.py:37