CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Jet.cc
Go to the documentation of this file.
1 //
2 //
3 
8 
9 using namespace pat;
10 
13  PATObject<reco::Jet>(reco::Jet()),
14  embeddedCaloTowers_(false),
15  embeddedPFCandidates_(false),
16  partonFlavour_(0),
17  jetCharge_(0.)
18 {
19 }
20 
22 Jet::Jet(const reco::Jet & aJet) :
23  PATObject<reco::Jet>(aJet),
24  embeddedCaloTowers_(false),
25  embeddedPFCandidates_(false),
26  partonFlavour_(0),
27  jetCharge_(0.0)
28 {
29  tryImportSpecific(aJet);
30 }
31 
33 Jet::Jet(const edm::Ptr<reco::Jet> & aJetRef) :
34  PATObject<reco::Jet>(aJetRef),
35  embeddedCaloTowers_(false),
36  embeddedPFCandidates_(false),
37  partonFlavour_(0),
38  jetCharge_(0.0)
39 {
40  tryImportSpecific(*aJetRef);
41 }
42 
45  PATObject<reco::Jet>(aJetRef),
46  embeddedCaloTowers_(false),
47  embeddedPFCandidates_(false),
48  partonFlavour_(0),
49  jetCharge_(0.0)
50 {
51  tryImportSpecific(*aJetRef);
52 }
53 
54 std::ostream&
55 reco::operator<<(std::ostream& out, const pat::Jet& obj)
56 {
57  if(!out) return out;
58 
59  out << "\tpat::Jet: ";
60  out << std::setiosflags(std::ios::right);
61  out << std::setiosflags(std::ios::fixed);
62  out << std::setprecision(3);
63  out << " E/pT/eta/phi "
64  << obj.energy()<<"/"
65  << obj.pt()<<"/"
66  << obj.eta()<<"/"
67  << obj.phi();
68  return out;
69 }
70 
73 {
74  const std::type_info & type = typeid(source);
75  if( type == typeid(reco::CaloJet) ){
76  specificCalo_.push_back( (static_cast<const reco::CaloJet&>(source)).getSpecific() );
77  } else if( type == typeid(reco::JPTJet) ){
78  reco::JPTJet const & jptJet = static_cast<reco::JPTJet const &>(source);
79  specificJPT_.push_back( jptJet.getSpecific() );
80  reco::CaloJet const * caloJet = 0;
81  if ( jptJet.getCaloJetRef().isNonnull() && jptJet.getCaloJetRef().isAvailable() ) {
82  caloJet = dynamic_cast<reco::CaloJet const *>( jptJet.getCaloJetRef().get() );
83  }
84  if ( caloJet != 0 ) {
85  specificCalo_.push_back( caloJet->getSpecific() );
86  }
87  else {
88  edm::LogWarning("OptionalProductNotFound") << " in pat::Jet, Attempted to add Calo Specifics to JPT Jets, but failed."
89  << " Jet ID for JPT Jets will not be available for you." << std::endl;
90  }
91  } else if( type == typeid(reco::PFJet) ){
92  specificPF_.push_back( (static_cast<const reco::PFJet&>(source)).getSpecific() );
93  }
94 }
95 
98 }
99 
101 
102 CaloTowerPtr Jet::getCaloConstituent (unsigned fIndex) const {
103  if (embeddedCaloTowers_) {
104  // Refactorized PAT access
105  if ( caloTowersFwdPtr_.size() > 0 ) {
106  return (fIndex < caloTowersFwdPtr_.size() ?
107  caloTowersFwdPtr_[fIndex].ptr() : CaloTowerPtr());
108  }
109  // Compatibility PAT access
110  else {
111  if ( caloTowers_.size() > 0 ) {
112  return (fIndex < caloTowers_.size() ?
113  CaloTowerPtr(&caloTowers_, fIndex) : CaloTowerPtr());
114 
115  }
116  }
117  }
118  // Non-embedded access
119  else {
120  Constituent dau = daughterPtr (fIndex);
121  const CaloTower* caloTower = dynamic_cast <const CaloTower*> (dau.get());
122  if (caloTower != 0) {
123  return CaloTowerPtr(dau.id(), caloTower, dau.key() );
124  }
125  else {
126  throw cms::Exception("Invalid Constituent") << "CaloJet constituent is not of CaloTower type";
127  }
128 
129  }
130 
131  return CaloTowerPtr ();
132 }
133 
134 
135 
136 std::vector<CaloTowerPtr> const & Jet::getCaloConstituents () const {
137  if ( !caloTowersTemp_.isSet() || caloTowers_.size() > 0 ) cacheCaloTowers();
138  return *caloTowersTemp_;
139 }
140 
141 
143 
145  if (embeddedPFCandidates_) {
146  // Refactorized PAT access
147  if ( pfCandidatesFwdPtr_.size() > 0 ) {
148  return (fIndex < pfCandidatesFwdPtr_.size() ?
149  pfCandidatesFwdPtr_[fIndex].ptr() : reco::PFCandidatePtr());
150  }
151  // Compatibility PAT access
152  else {
153  if ( pfCandidates_.size() > 0 ) {
154  return (fIndex < pfCandidates_.size() ?
156 
157  }
158  }
159  }
160  // Non-embedded access
161  else {
162  Constituent dau = daughterPtr (fIndex);
163  const reco::PFCandidate* pfCandidate = dynamic_cast <const reco::PFCandidate*> (dau.get());
164  if (pfCandidate) {
165  return reco::PFCandidatePtr(dau.id(), pfCandidate, dau.key() );
166  }
167  else {
168  throw cms::Exception("Invalid Constituent") << "PFJet constituent is not of PFCandidate type";
169  }
170 
171  }
172 
173  return reco::PFCandidatePtr ();
174 }
175 
176 std::vector<reco::PFCandidatePtr> const & Jet::getPFConstituents () const {
177  if ( !pfCandidatesTemp_.isSet() || pfCandidates_.size() > 0 ) cachePFCandidates();
178  return *pfCandidatesTemp_;
179 }
180 
181 
182 
184 const reco::GenJet * Jet::genJet() const {
185  if (genJet_.size()) return &(genJet_.front());
186  else if ( genJetRef_.size() ) return genJetRef_[0].get();
187  else return genJetFwdRef_.get();
188 }
189 
191 int Jet::partonFlavour() const {
192  return partonFlavour_;
193 }
194 
196 
197 // initialize the jet to a given JEC level during creation starting from Uncorrected
198 void Jet::initializeJEC(unsigned int level, const JetCorrFactors::Flavor& flavor, unsigned int set)
199 {
200  currentJECSet(set);
201  currentJECLevel(level);
202  currentJECFlavor(flavor);
203  setP4(jec_[set].correction(level, flavor)*p4());
204 }
205 
207 int Jet::jecSet(const std::string& set) const
208 {
209  for(std::vector<pat::JetCorrFactors>::const_iterator corrFactor=jec_.begin(); corrFactor!=jec_.end(); ++corrFactor)
210  if( corrFactor->jecSet()==set ){ return (corrFactor-jec_.begin()); }
211  return -1;
212 }
213 
215 const std::vector<std::string> Jet::availableJECSets() const
216 {
217  std::vector<std::string> sets;
218  for(std::vector<pat::JetCorrFactors>::const_iterator corrFactor=jec_.begin(); corrFactor!=jec_.end(); ++corrFactor)
219  sets.push_back(corrFactor->jecSet());
220  return sets;
221 }
222 
223 const std::vector<std::string> Jet::availableJECLevels(const int& set) const
224 {
225  return set>=0 ? jec_.at(set).correctionLabels() : std::vector<std::string>();
226 }
227 
230 float Jet::jecFactor(const std::string& level, const std::string& flavor, const std::string& set) const
231 {
232  for(unsigned int idx=0; idx<jec_.size(); ++idx){
233  if(set.empty() || jec_.at(idx).jecSet()==set){
234  if(jec_[idx].jecLevel(level)>=0){
235  return jecFactor(jec_[idx].jecLevel(level), jec_[idx].jecFlavor(flavor), idx);
236  }
237  else{
238  throw cms::Exception("InvalidRequest") << "This JEC level " << level << " does not exist. \n";
239  }
240  }
241  }
242  throw cms::Exception("InvalidRequest") << "This jet does not carry any jet energy correction factor information \n"
243  << "for a jet energy correction set with label " << set << "\n";
244 }
245 
248 float Jet::jecFactor(const unsigned int& level, const JetCorrFactors::Flavor& flavor, const unsigned int& set) const
249 {
250  if(!jecSetsAvailable()){
251  throw cms::Exception("InvalidRequest") << "This jet does not carry any jet energy correction factor information \n";
252  }
253  if(!jecSetAvailable(set)){
254  throw cms::Exception("InvalidRequest") << "This jet does not carry any jet energy correction factor information \n"
255  << "for a jet energy correction set with index " << set << "\n";
256  }
257  return jec_.at(set).correction(level, flavor)/jec_.at(currentJECSet_).correction(currentJECLevel_, currentJECFlavor_);
258 }
259 
262 Jet Jet::correctedJet(const std::string& level, const std::string& flavor, const std::string& set) const
263 {
264  // rescale p4 of the jet; the update of current values is
265  // done within the called jecFactor function
266  for(unsigned int idx=0; idx<jec_.size(); ++idx){
267  if(set.empty() || jec_.at(idx).jecSet()==set){
268  if(jec_[idx].jecLevel(level)>=0){
269  return correctedJet(jec_[idx].jecLevel(level), jec_[idx].jecFlavor(flavor), idx);
270  }
271  else{
272  throw cms::Exception("InvalidRequest") << "This JEC level " << level << " does not exist. \n";
273  }
274  }
275  }
276  throw cms::Exception("InvalidRequest") << "This JEC set " << set << " does not exist. \n";
277 }
278 
281 Jet Jet::correctedJet(const unsigned int& level, const JetCorrFactors::Flavor& flavor, const unsigned int& set) const
282 {
283  Jet correctedJet(*this);
284  //rescale p4 of the jet
285  correctedJet.setP4(jecFactor(level, flavor, set)*p4());
286  // update current level, flavor and set
287  correctedJet.currentJECSet(set); correctedJet.currentJECLevel(level); correctedJet.currentJECFlavor(flavor);
288  return correctedJet;
289 }
290 
291 
293 
294 const std::vector<std::pair<std::string, float> > & Jet::getPairDiscri() const {
295  return pairDiscriVector_;
296 }
297 
299 float Jet::bDiscriminator(const std::string & aLabel) const {
300  float discriminator = -1000.;
301  const std::string & theLabel = ((aLabel == "" || aLabel == "default")) ? "trackCountingHighEffBJetTags" : aLabel;
302  for(unsigned int i=0; i!=pairDiscriVector_.size(); i++){
303  if(pairDiscriVector_[i].first == theLabel){
304  discriminator = pairDiscriVector_[i].second;
305  }
306  }
307  return discriminator;
308 }
309 
311  std::vector<std::string>::const_iterator it = std::find(tagInfoLabels_.begin(), tagInfoLabels_.end(), label);
312  if (it != tagInfoLabels_.end()) {
313  if ( tagInfosFwdPtr_.size() > 0 ) return tagInfosFwdPtr_[it - tagInfoLabels_.begin()].get();
314  else if ( tagInfos_.size() > 0 ) return & tagInfos_[it - tagInfoLabels_.begin()];
315  return 0;
316  }
317  return 0;
318 }
319 
320 
321 template<typename T>
322 const T * Jet::tagInfoByType() const {
323  // First check the factorized PAT version
324  for (size_t i = 0, n = tagInfosFwdPtr_.size(); i < n; ++i) {
326  reco::BaseTagInfo const * baseTagInfo = val.get();
327  if ( typeid(*baseTagInfo) == typeid(T) ) {
328  return static_cast<const T *>( baseTagInfo );
329  }
330  }
331  // Then check compatibility version
332  for (size_t i = 0, n = tagInfos_.size(); i < n; ++i) {
334  reco::BaseTagInfo const * baseTagInfo = &val;
335  if ( typeid(*baseTagInfo) == typeid(T) ) {
336  return static_cast<const T *>( baseTagInfo );
337  }
338  }
339  return 0;
340 }
341 
342 
343 
344 const reco::TrackIPTagInfo *
346  return (label.empty() ? tagInfoByType<reco::TrackIPTagInfo>()
347  : dynamic_cast<const reco::TrackIPTagInfo *>(tagInfo(label)) );
348 }
349 
352  return (label.empty() ? tagInfoByType<reco::SoftLeptonTagInfo>()
353  : dynamic_cast<const reco::SoftLeptonTagInfo *>(tagInfo(label)) );
354 }
355 
358  return (label.empty() ? tagInfoByType<reco::SecondaryVertexTagInfo>()
359  : dynamic_cast<const reco::SecondaryVertexTagInfo *>(tagInfo(label)) );
360 }
361 
362 void
365  std::string::size_type idx = label.find("TagInfos");
366  if (idx == std::string::npos) {
367  tagInfoLabels_.push_back(label);
368  } else {
369  tagInfoLabels_.push_back(label.substr(0,idx));
370  }
371  tagInfosFwdPtr_.push_back(info);
372 }
373 
374 
375 
377 float Jet::jetCharge() const {
378  return jetCharge_;
379 }
380 
383  return associatedTracks_;
384 }
385 
389 }
390 
393  caloTowersFwdPtr_.reserve(caloTowers.size());
394  for(auto const& tower : caloTowers) {
395  caloTowersFwdPtr_.push_back( tower );
396  }
397  embeddedCaloTowers_ = true;
398  caloTowersTemp_.reset();
399 }
400 
401 
404  pfCandidatesFwdPtr_.reserve(pfCandidates.size());
405  for(auto const& cand : pfCandidates) {
406  pfCandidatesFwdPtr_.push_back(cand);
407  }
408  embeddedPFCandidates_ = true;
410 }
411 
412 
415 {
416  genJetFwdRef_ = gj;
417 }
418 
419 
420 
422 void Jet::setPartonFlavour(int partonFl) {
423  partonFlavour_ = partonFl;
424 }
425 
427 void Jet::addBDiscriminatorPair(const std::pair<std::string, float> & thePair) {
428  pairDiscriVector_.push_back(thePair);
429 }
430 
432 void Jet::setJetCharge(float jetCharge) {
434 }
435 
436 
437 
439 void Jet::cacheCaloTowers() const {
440  // Clear the cache
441  // Here is where we've embedded constituents
442  std::unique_ptr<std::vector<CaloTowerPtr>> caloTowersTemp{ new std::vector<CaloTowerPtr>{}};
443  if ( embeddedCaloTowers_ ) {
444  // Refactorized PAT access
445  if ( caloTowersFwdPtr_.size() > 0 ) {
446  caloTowersTemp->reserve(caloTowersFwdPtr_.size());
447  for ( CaloTowerFwdPtrVector::const_iterator ibegin=caloTowersFwdPtr_.begin(),
448  iend = caloTowersFwdPtr_.end(),
449  icalo = ibegin;
450  icalo != iend; ++icalo ) {
451  caloTowersTemp->emplace_back( icalo->ptr() );
452  }
453  }
454  // Compatibility access
455  else if ( caloTowers_.size() > 0 ) {
456  caloTowersTemp->reserve(caloTowers_.size());
458  iend = caloTowers_.end(),
459  icalo = ibegin;
460  icalo != iend; ++icalo ) {
461  caloTowersTemp->emplace_back( &caloTowers_, icalo - ibegin );
462  }
463  }
464  }
465  // Non-embedded access
466  else {
467  const auto nDaughters = numberOfDaughters();
468  caloTowersTemp->reserve(nDaughters);
469  for ( unsigned fIndex = 0; fIndex < nDaughters; ++fIndex ) {
470  Constituent const & dau = daughterPtr (fIndex);
471  const CaloTower* caloTower = dynamic_cast <const CaloTower*> (dau.get());
472  if (caloTower) {
473  caloTowersTemp->emplace_back( dau.id(), caloTower,dau.key() );
474  }
475  else {
476  throw cms::Exception("Invalid Constituent") << "CaloJet constituent is not of CaloTower type";
477  }
478  }
479  }
480  caloTowersTemp_.set(std::move(caloTowersTemp));
481 }
482 
485 
486  std::unique_ptr<std::vector<reco::PFCandidatePtr>> pfCandidatesTemp{ new std::vector<reco::PFCandidatePtr>{}};
487  // Here is where we've embedded constituents
488  if ( embeddedPFCandidates_ ) {
489  // Refactorized PAT access
490  if ( pfCandidatesFwdPtr_.size() > 0 ) {
491  pfCandidatesTemp->reserve(pfCandidatesFwdPtr_.size());
492  for ( PFCandidateFwdPtrCollection::const_iterator ibegin=pfCandidatesFwdPtr_.begin(),
493  iend = pfCandidatesFwdPtr_.end(),
494  ipf = ibegin;
495  ipf != iend; ++ipf ) {
496  pfCandidatesTemp->emplace_back( ipf->ptr() );
497  }
498  }
499  // Compatibility access
500  else if ( pfCandidates_.size() > 0 ) {
501  pfCandidatesTemp->reserve(pfCandidates_.size());
502  for ( reco::PFCandidateCollection::const_iterator ibegin=pfCandidates_.begin(),
503  iend = pfCandidates_.end(),
504  ipf = ibegin;
505  ipf != iend; ++ipf ) {
506  pfCandidatesTemp->emplace_back( &pfCandidates_, ipf - ibegin );
507  }
508  }
509  }
510  // Non-embedded access
511  else {
512  const auto nDaughters = numberOfDaughters();
513  pfCandidatesTemp->reserve(nDaughters);
514  for ( unsigned fIndex = 0; fIndex < nDaughters; ++fIndex ) {
515  Constituent const & dau = daughterPtr (fIndex);
516  const reco::PFCandidate* pfCandidate = dynamic_cast <const reco::PFCandidate*> (dau.get());
517  if (pfCandidate) {
518  pfCandidatesTemp->emplace_back( dau.id(), pfCandidate,dau.key() );
519  }
520  else {
521  throw cms::Exception("Invalid Constituent") << "PFJet constituent is not of PFCandidate type";
522  }
523  }
524  }
525  // Set the cache
526  pfCandidatesTemp_.set(std::move(pfCandidatesTemp));
527 }
type
Definition: HCALResponse.h:21
virtual double energy() const GCC11_FINAL
energy
void setGenJetRef(const edm::FwdRef< reco::GenJetCollection > &gj)
method to set the matched generated jet reference, embedding if requested
Definition: Jet.cc:414
float jecFactor(const std::string &level, const std::string &flavor="none", const std::string &set="") const
Definition: Jet.cc:230
int i
Definition: DBlmapReader.cc:9
const reco::SecondaryVertexTagInfo * tagInfoSecondaryVertex(const std::string &label="") const
Definition: Jet.cc:357
reco::GenJetRefVector genJetRef_
Definition: Jet.h:510
CaloTowerFwdPtrVector caloTowersFwdPtr_
Definition: Jet.h:498
const std::vector< std::string > availableJECLevels(const int &set=0) const
Definition: Jet.cc:223
static const TGPicture * info(bool iBackgroundIsBlack)
bool jecSetsAvailable() const
Definition: Jet.h:111
Jets made from CaloTowers.
Definition: CaloJet.h:29
reco::TrackRefVector associatedTracks_
Definition: Jet.h:540
reco::PFCandidateCollection pfCandidates_
Definition: Jet.h:503
virtual const LorentzVector & p4() const GCC11_FINAL
four-momentum Lorentz vector
int partonFlavour_
Definition: Jet.h:512
std::vector< std::pair< std::string, float > > pairDiscriVector_
Definition: Jet.h:531
const reco::GenJet * genJet() const
return the matched generated jet
Definition: Jet.cc:184
CandidatePtr daughterPtr(size_type i) const
reference to daughter at given position
const Specific & getSpecific() const
block accessors
Definition: JPTJet.h:133
Base class for all types of Jets.
Definition: Jet.h:20
Jet correctedJet(const std::string &level, const std::string &flavor="none", const std::string &set="") const
Definition: Jet.cc:262
TagInfoFwdPtrCollection tagInfosFwdPtr_
Definition: Jet.h:534
edm::FwdRef< reco::GenJetCollection > genJetFwdRef_
Definition: Jet.h:511
size_type size() const
Definition: OwnVector.h:247
std::vector< CaloTower >::const_iterator const_iterator
void cacheCaloTowers() const
cache calo towers
Definition: Jet.cc:439
void tryImportSpecific(const reco::Jet &source)
constructor helper that tries to import the specific info from the source jet
Definition: Jet.cc:72
const edm::RefToBase< reco::Jet > & getCaloJetRef() const
Definition: JPTJet.h:130
virtual ~Jet()
destructor
Definition: Jet.cc:97
void setCaloTowers(const CaloTowerFwdPtrCollection &caloTowers)
method to store the CaloJet constituents internally
Definition: Jet.cc:392
const reco::TrackIPTagInfo * tagInfoTrackIP(const std::string &label="") const
Definition: Jet.cc:345
const reco::TrackRefVector & associatedTracks() const
method to return a vector of refs to the tracks associated to this jet
Definition: Jet.cc:382
edm::AtomicPtrCache< std::vector< CaloTowerPtr > > caloTowersTemp_
Definition: Jet.h:496
void find(edm::Handle< EcalRecHitCollection > &hits, DetId thisDet, std::vector< EcalRecHitCollection::const_iterator > &hit, bool debug=false)
Definition: FindCaloHit.cc:7
void reset()
unsets the value and deletes the memory
uint16_t size_type
const T * tagInfoByType() const
Definition: Jet.cc:322
Jets made from PFObjects.
Definition: PFJet.h:21
bool isSet() const
std::vector< reco::PFCandidatePtr > const & getPFConstituents() const
Definition: Jet.cc:176
void addTagInfo(const std::string &label, const TagInfoFwdPtrCollection::value_type &info)
Definition: Jet.cc:363
bool isAvailable() const
Definition: RefToBase.h:112
std::vector< PFSpecific > specificPF_
Definition: Jet.h:546
std::vector< PFCandidatePtr > pfCandidates(const PFJet &jet, int particleId, bool sort=true)
daughters dau
collection of references to daughters
edm::OwnVector< reco::BaseTagInfo > tagInfos_
Definition: Jet.h:533
void setAssociatedTracks(const reco::TrackRefVector &tracks)
method to set the vector of refs to the tracks associated to this jet
Definition: Jet.cc:387
virtual float phi() const GCC11_FINAL
momentum azimuthal angle
std::ostream & operator<<(std::ostream &, BeamSpot beam)
Definition: BeamSpot.cc:71
std::vector< CaloSpecific > specificCalo_
Definition: Jet.h:544
T const * get() const
Returns C++ pointer to the item.
Definition: Ptr.h:143
void initializeJEC(unsigned int level, const JetCorrFactors::Flavor &flavor=JetCorrFactors::NONE, unsigned int set=0)
initialize the jet to a given JEC level during creation starting from Uncorrected ...
Definition: Jet.cc:198
CaloTowerPtr getCaloConstituent(unsigned fIndex) const
convert generic constituent to specific type
Definition: Jet.cc:102
Jets made from CaloJets corrected for ZSP and tracks.
Definition: JPTJet.h:29
unsigned int currentJECLevel_
Definition: Jet.h:524
edm::Ptr< CaloTower > CaloTowerPtr
Definition: CaloTowerFwd.h:12
ProductID id() const
Accessor for product ID.
Definition: Ptr.h:164
T const * get() const
Returns C++ pointer to the item.
Definition: FwdRef.h:157
float bDiscriminator(const std::string &theLabel) const
-— methods for accessing b-tagging info -—
Definition: Jet.cc:299
int jecSet(const std::string &label) const
return true if this jet carries the jet correction factors of a different set, for systematic studies...
Definition: Jet.cc:207
bool embeddedCaloTowers_
Definition: Jet.h:495
Jets made from MC generator particles.
Definition: GenJet.h:24
const reco::BaseTagInfo * tagInfo(const std::string &label) const
Definition: Jet.cc:310
void setPartonFlavour(int partonFl)
method to set the flavour of the parton underlying the jet
Definition: Jet.cc:422
bool first
Definition: L1TdeRCT.cc:79
Container::value_type value_type
int partonFlavour() const
return the flavour of the parton underlying the jet
Definition: Jet.cc:191
JetCorrFactors::Flavor currentJECFlavor() const
return flavour of the current step of jet energy corrections
Definition: Jet.h:123
std::vector< CaloTowerPtr > const & getCaloConstituents() const
Definition: Jet.cc:136
std::vector< pat::JetCorrFactors > jec_
Definition: Jet.h:519
Jet()
default constructor
Definition: Jet.cc:12
virtual float eta() const GCC11_FINAL
momentum pseudorapidity
std::vector< std::string > tagInfoLabels_
Definition: Jet.h:532
float jetCharge_
Definition: Jet.h:539
tuple out
Definition: dbtoconf.py:99
const_iterator end() const
const reco::SoftLeptonTagInfo * tagInfoSoftLepton(const std::string &label="") const
Definition: Jet.cc:351
key_type key() const
Definition: Ptr.h:169
void setJetCharge(float jetCharge)
method to set the jet charge
Definition: Jet.cc:432
virtual size_t numberOfDaughters() const
Definition: Jet.h:429
bool set(std::unique_ptr< T > iNewValue) const
tuple tracks
Definition: testEve_cfg.py:39
tuple idx
DEBUGGING if hasattr(process,&quot;trackMonIterativeTracking2012&quot;): print &quot;trackMonIterativeTracking2012 D...
std::vector< edm::FwdPtr< CaloTower > > CaloTowerFwdPtrCollection
Definition: Jet.h:67
std::vector< JPTSpecific > specificJPT_
Definition: Jet.h:545
std::vector< edm::FwdPtr< reco::PFCandidate > > PFCandidateFwdPtrCollection
Definition: Jet.h:66
void addBDiscriminatorPair(const std::pair< std::string, float > &thePair)
method to add a algolabel-discriminator pair
Definition: Jet.cc:427
std::string currentJECLevel() const
return the name of the current step of jet energy corrections
Definition: Jet.h:121
Analysis-level calorimeter jet class.
Definition: Jet.h:70
CaloTowerCollection caloTowers_
Definition: Jet.h:497
const std::vector< std::string > availableJECSets() const
-— methods for jet corrections -—
Definition: Jet.cc:215
void cachePFCandidates() const
method to cache the constituents to allow &quot;user-friendly&quot; access
Definition: Jet.cc:484
Particle reconstructed by the particle flow algorithm.
Definition: PFCandidate.h:38
reco::PFCandidateFwdPtrVector pfCandidatesFwdPtr_
Definition: Jet.h:504
size_type size() const
virtual void setP4(const LorentzVector &p4) GCC11_FINAL
set 4-momentum
void setPFCandidates(const PFCandidateFwdPtrCollection &pfCandidates)
method to store the PFCandidate constituents internally
Definition: Jet.cc:403
size_type size() const
Size of the RefVector.
Definition: RefVector.h:89
Templated PAT object container.
Definition: PATObject.h:41
reco::PFCandidatePtr getPFConstituent(unsigned fIndex) const
convert generic constituent to specific type
Definition: Jet.cc:144
tuple level
Definition: testEve_cfg.py:34
volatile std::atomic< bool > shutdown_flag false
unsigned int currentJECSet_
Definition: Jet.h:522
std::vector< reco::GenJet > genJet_
Definition: Jet.h:509
edm::AtomicPtrCache< std::vector< reco::PFCandidatePtr > > pfCandidatesTemp_
Definition: Jet.h:502
virtual float pt() const GCC11_FINAL
transverse momentum
long double T
edm::Ptr< PFCandidate > PFCandidatePtr
persistent Ptr to a PFCandidate
bool isNonnull() const
Checks for non-null.
Definition: RefToBase.h:279
JetCorrFactors::Flavor currentJECFlavor_
Definition: Jet.h:527
bool embeddedPFCandidates_
Definition: Jet.h:501
static std::string const source
Definition: EdmProvDump.cc:43
value_type const * get() const
Definition: RefToBase.h:212
std::string currentJECSet() const
returns the label of the current set of jet energy corrections
Definition: Jet.h:119
const_iterator begin() const
const std::vector< std::pair< std::string, float > > & getPairDiscri() const
get vector of paire labelname-disciValue
Definition: Jet.cc:294
float jetCharge() const
method to return the JetCharge computed when creating the Jet
Definition: Jet.cc:377
bool jecSetAvailable(const std::string &set) const
Definition: Jet.h:114
const Specific & getSpecific() const
Definition: CaloJet.h:149