CMS 3D CMS Logo

List of all members | Public Member Functions | Public Attributes
lowptgsfeleseed::Features Class Reference

#include <LowPtGsfElectronSeedHeavyObjectCache.h>

Public Member Functions

std::vector< float > get ()
 
void set (const reco::PreId &ecal, const reco::PreId &hcal, double rho, const reco::BeamSpot &spot, noZS::EcalClusterLazyTools &ecalTools)
 

Public Attributes

float ktf_ecal_cluster_circularity_ = -0.1
 
float ktf_ecal_cluster_covEtaEta_ = -42.
 
float ktf_ecal_cluster_covEtaPhi_ = -42.
 
float ktf_ecal_cluster_covPhiPhi_ = -42.
 
float ktf_ecal_cluster_deta_ = -42.
 
float ktf_ecal_cluster_dphi_ = -42.
 
float ktf_ecal_cluster_e3x3_ = -1.
 
float ktf_ecal_cluster_e5x5_ = -1.
 
float ktf_ecal_cluster_e_ = -1.
 
float ktf_ecal_cluster_r9_ = -0.1
 
float ktf_hcal_cluster_deta_ = -42.
 
float ktf_hcal_cluster_dphi_ = -42.
 
float ktf_hcal_cluster_e_ = -1.
 
float preid_gsf_chi2red_ = -1.
 
float preid_gsf_dpt_ = -1.
 
float preid_trk_gsf_chiratio_ = -1.
 
float rho_ = -1.
 
float trk_chi2red_ = -1.
 
float trk_dxy_sig_ = -1.
 
float trk_eta_ = -1.
 
float trk_high_quality_ = -1.
 
float trk_nhits_ = -1.
 
float trk_p_ = -1.
 
float trk_phi_ = -1.
 
float trk_pt_ = -1.
 

Detailed Description

Definition at line 16 of file LowPtGsfElectronSeedHeavyObjectCache.h.

Member Function Documentation

◆ get()

std::vector< float > lowptgsfeleseed::Features::get ( )

Definition at line 18 of file LowPtGsfElectronSeedHeavyObjectCache.cc.

References ktf_ecal_cluster_circularity_, ktf_ecal_cluster_covEtaEta_, ktf_ecal_cluster_covEtaPhi_, ktf_ecal_cluster_covPhiPhi_, ktf_ecal_cluster_deta_, ktf_ecal_cluster_dphi_, ktf_ecal_cluster_e3x3_, ktf_ecal_cluster_e5x5_, ktf_ecal_cluster_e_, ktf_ecal_cluster_r9_, ktf_hcal_cluster_deta_, ktf_hcal_cluster_dphi_, ktf_hcal_cluster_e_, convertSQLitetoXML_cfg::output, preid_gsf_chi2red_, preid_gsf_dpt_, preid_trk_gsf_chiratio_, rho_, trk_chi2red_, trk_dxy_sig_, trk_eta_, trk_high_quality_, trk_nhits_, trk_p_, trk_phi_, and trk_pt_.

Referenced by Options.Options::__getitem__(), betterConfigParser.BetterConfigParser::__updateDict(), betterConfigParser.BetterConfigParser::getCompares(), betterConfigParser.BetterConfigParser::getGeneral(), and betterConfigParser.BetterConfigParser::getResultingSection().

◆ set()

void lowptgsfeleseed::Features::set ( const reco::PreId ecal,
const reco::PreId hcal,
double  rho,
const reco::BeamSpot spot,
noZS::EcalClusterLazyTools ecalTools 
)

Definition at line 49 of file LowPtGsfElectronSeedHeavyObjectCache.cc.

53  {
54  // Tracks
55  reco::TrackRef trk = ecal.trackRef();
56  if (trk.isNonnull()) {
57  trk_pt_ = trk->pt();
58  trk_eta_ = trk->eta();
59  trk_phi_ = trk->phi();
60  trk_p_ = trk->p();
61  trk_nhits_ = static_cast<float>(trk->found());
62  trk_high_quality_ = static_cast<float>(trk->quality(reco::TrackBase::qualityByName("highPurity")));
63  trk_chi2red_ = trk->normalizedChi2();
64  if (trk->dxy(spot) > 0.) {
65  trk_dxy_sig_ = trk->dxyError() / trk->dxy(spot); //@@ to be consistent with the training based on 94X MC
66  }
67  ktf_ecal_cluster_dphi_ *= trk->charge(); //@@ to be consistent with the training based on 94X MC
68  }
69 
70  // Rho
71  rho_ = static_cast<float>(rho);
72 
73  // ECAL clusters
74  reco::PFClusterRef ecal_clu = ecal.clusterRef();
75  if (ecal_clu.isNonnull()) {
76  ktf_ecal_cluster_e_ = ecal_clu->energy();
77  ktf_ecal_cluster_deta_ = ecal.geomMatching()[0];
78  ktf_ecal_cluster_dphi_ = ecal.geomMatching()[1];
79  ktf_ecal_cluster_e3x3_ = tools.e3x3(*ecal_clu);
80  ktf_ecal_cluster_e5x5_ = tools.e5x5(*ecal_clu);
81  auto covs = tools.localCovariances(*ecal_clu);
85  if (ktf_ecal_cluster_e_ > 0.) {
87  }
88  if (ktf_ecal_cluster_e5x5_ > 0.) {
90  } else {
92  }
93  }
94 
95  // HCAL clusters
96  reco::PFClusterRef hcal_clu = hcal.clusterRef();
97  if (hcal_clu.isNonnull()) {
98  ktf_hcal_cluster_e_ = hcal_clu->energy();
99  ktf_hcal_cluster_deta_ = hcal.geomMatching()[0];
100  ktf_hcal_cluster_dphi_ = hcal.geomMatching()[1];
101  }
102 
103  // PreId
104  preid_gsf_dpt_ = ecal.dpt();
105  preid_trk_gsf_chiratio_ = ecal.chi2Ratio();
106  preid_gsf_chi2red_ = ecal.gsfChi2();
107  };

References bsc_activity_cfg::ecal, edm::Ref< C, T, F >::isNonnull(), ktf_ecal_cluster_circularity_, ktf_ecal_cluster_covEtaEta_, ktf_ecal_cluster_covEtaPhi_, ktf_ecal_cluster_covPhiPhi_, ktf_ecal_cluster_deta_, ktf_ecal_cluster_dphi_, ktf_ecal_cluster_e3x3_, ktf_ecal_cluster_e5x5_, ktf_ecal_cluster_e_, ktf_ecal_cluster_r9_, ktf_hcal_cluster_deta_, ktf_hcal_cluster_dphi_, ktf_hcal_cluster_e_, preid_gsf_chi2red_, preid_gsf_dpt_, preid_trk_gsf_chiratio_, reco::TrackBase::qualityByName(), rho_, trk_chi2red_, trk_dxy_sig_, trk_eta_, trk_high_quality_, trk_nhits_, trk_p_, trk_phi_, and trk_pt_.

Member Data Documentation

◆ ktf_ecal_cluster_circularity_

float lowptgsfeleseed::Features::ktf_ecal_cluster_circularity_ = -0.1

Definition at line 35 of file LowPtGsfElectronSeedHeavyObjectCache.h.

Referenced by get(), and set().

◆ ktf_ecal_cluster_covEtaEta_

float lowptgsfeleseed::Features::ktf_ecal_cluster_covEtaEta_ = -42.

Definition at line 31 of file LowPtGsfElectronSeedHeavyObjectCache.h.

Referenced by get(), and set().

◆ ktf_ecal_cluster_covEtaPhi_

float lowptgsfeleseed::Features::ktf_ecal_cluster_covEtaPhi_ = -42.

Definition at line 32 of file LowPtGsfElectronSeedHeavyObjectCache.h.

Referenced by get(), and set().

◆ ktf_ecal_cluster_covPhiPhi_

float lowptgsfeleseed::Features::ktf_ecal_cluster_covPhiPhi_ = -42.

Definition at line 33 of file LowPtGsfElectronSeedHeavyObjectCache.h.

Referenced by get(), and set().

◆ ktf_ecal_cluster_deta_

float lowptgsfeleseed::Features::ktf_ecal_cluster_deta_ = -42.

Definition at line 27 of file LowPtGsfElectronSeedHeavyObjectCache.h.

Referenced by get(), and set().

◆ ktf_ecal_cluster_dphi_

float lowptgsfeleseed::Features::ktf_ecal_cluster_dphi_ = -42.

Definition at line 28 of file LowPtGsfElectronSeedHeavyObjectCache.h.

Referenced by get(), and set().

◆ ktf_ecal_cluster_e3x3_

float lowptgsfeleseed::Features::ktf_ecal_cluster_e3x3_ = -1.

Definition at line 29 of file LowPtGsfElectronSeedHeavyObjectCache.h.

Referenced by get(), and set().

◆ ktf_ecal_cluster_e5x5_

float lowptgsfeleseed::Features::ktf_ecal_cluster_e5x5_ = -1.

Definition at line 30 of file LowPtGsfElectronSeedHeavyObjectCache.h.

Referenced by get(), and set().

◆ ktf_ecal_cluster_e_

float lowptgsfeleseed::Features::ktf_ecal_cluster_e_ = -1.

Definition at line 26 of file LowPtGsfElectronSeedHeavyObjectCache.h.

Referenced by get(), and set().

◆ ktf_ecal_cluster_r9_

float lowptgsfeleseed::Features::ktf_ecal_cluster_r9_ = -0.1

Definition at line 34 of file LowPtGsfElectronSeedHeavyObjectCache.h.

Referenced by get(), and set().

◆ ktf_hcal_cluster_deta_

float lowptgsfeleseed::Features::ktf_hcal_cluster_deta_ = -42.

Definition at line 37 of file LowPtGsfElectronSeedHeavyObjectCache.h.

Referenced by get(), and set().

◆ ktf_hcal_cluster_dphi_

float lowptgsfeleseed::Features::ktf_hcal_cluster_dphi_ = -42.

Definition at line 38 of file LowPtGsfElectronSeedHeavyObjectCache.h.

Referenced by get(), and set().

◆ ktf_hcal_cluster_e_

float lowptgsfeleseed::Features::ktf_hcal_cluster_e_ = -1.

Definition at line 36 of file LowPtGsfElectronSeedHeavyObjectCache.h.

Referenced by get(), and set().

◆ preid_gsf_chi2red_

float lowptgsfeleseed::Features::preid_gsf_chi2red_ = -1.

Definition at line 41 of file LowPtGsfElectronSeedHeavyObjectCache.h.

Referenced by get(), and set().

◆ preid_gsf_dpt_

float lowptgsfeleseed::Features::preid_gsf_dpt_ = -1.

Definition at line 39 of file LowPtGsfElectronSeedHeavyObjectCache.h.

Referenced by get(), and set().

◆ preid_trk_gsf_chiratio_

float lowptgsfeleseed::Features::preid_trk_gsf_chiratio_ = -1.

Definition at line 40 of file LowPtGsfElectronSeedHeavyObjectCache.h.

Referenced by get(), and set().

◆ rho_

float lowptgsfeleseed::Features::rho_ = -1.

Definition at line 25 of file LowPtGsfElectronSeedHeavyObjectCache.h.

Referenced by get(), and set().

◆ trk_chi2red_

float lowptgsfeleseed::Features::trk_chi2red_ = -1.

Definition at line 24 of file LowPtGsfElectronSeedHeavyObjectCache.h.

Referenced by get(), and set().

◆ trk_dxy_sig_

float lowptgsfeleseed::Features::trk_dxy_sig_ = -1.

Definition at line 42 of file LowPtGsfElectronSeedHeavyObjectCache.h.

Referenced by get(), and set().

◆ trk_eta_

float lowptgsfeleseed::Features::trk_eta_ = -1.

Definition at line 19 of file LowPtGsfElectronSeedHeavyObjectCache.h.

Referenced by get(), and set().

◆ trk_high_quality_

float lowptgsfeleseed::Features::trk_high_quality_ = -1.

Definition at line 23 of file LowPtGsfElectronSeedHeavyObjectCache.h.

Referenced by get(), and set().

◆ trk_nhits_

float lowptgsfeleseed::Features::trk_nhits_ = -1.

Definition at line 22 of file LowPtGsfElectronSeedHeavyObjectCache.h.

Referenced by get(), and set().

◆ trk_p_

float lowptgsfeleseed::Features::trk_p_ = -1.

Definition at line 21 of file LowPtGsfElectronSeedHeavyObjectCache.h.

Referenced by get(), and set().

◆ trk_phi_

float lowptgsfeleseed::Features::trk_phi_ = -1.

Definition at line 20 of file LowPtGsfElectronSeedHeavyObjectCache.h.

Referenced by get(), and set().

◆ trk_pt_

float lowptgsfeleseed::Features::trk_pt_ = -1.

Definition at line 18 of file LowPtGsfElectronSeedHeavyObjectCache.h.

Referenced by get(), and set().

lowptgsfeleseed::Features::trk_dxy_sig_
float trk_dxy_sig_
Definition: LowPtGsfElectronSeedHeavyObjectCache.h:42
lowptgsfeleseed::Features::ktf_hcal_cluster_dphi_
float ktf_hcal_cluster_dphi_
Definition: LowPtGsfElectronSeedHeavyObjectCache.h:38
lowptgsfeleseed::Features::rho_
float rho_
Definition: LowPtGsfElectronSeedHeavyObjectCache.h:25
convertSQLitetoXML_cfg.output
output
Definition: convertSQLitetoXML_cfg.py:32
hcal
Definition: ConfigurationDatabase.cc:13
lowptgsfeleseed::Features::ktf_ecal_cluster_deta_
float ktf_ecal_cluster_deta_
Definition: LowPtGsfElectronSeedHeavyObjectCache.h:27
lowptgsfeleseed::Features::ktf_ecal_cluster_covEtaPhi_
float ktf_ecal_cluster_covEtaPhi_
Definition: LowPtGsfElectronSeedHeavyObjectCache.h:32
lowptgsfeleseed::Features::preid_gsf_dpt_
float preid_gsf_dpt_
Definition: LowPtGsfElectronSeedHeavyObjectCache.h:39
lowptgsfeleseed::Features::trk_p_
float trk_p_
Definition: LowPtGsfElectronSeedHeavyObjectCache.h:21
edm::Ref< TrackCollection >
lowptgsfeleseed::Features::ktf_ecal_cluster_r9_
float ktf_ecal_cluster_r9_
Definition: LowPtGsfElectronSeedHeavyObjectCache.h:34
lowptgsfeleseed::Features::ktf_hcal_cluster_deta_
float ktf_hcal_cluster_deta_
Definition: LowPtGsfElectronSeedHeavyObjectCache.h:37
lowptgsfeleseed::Features::preid_gsf_chi2red_
float preid_gsf_chi2red_
Definition: LowPtGsfElectronSeedHeavyObjectCache.h:41
lowptgsfeleseed::Features::trk_high_quality_
float trk_high_quality_
Definition: LowPtGsfElectronSeedHeavyObjectCache.h:23
lowptgsfeleseed::Features::ktf_ecal_cluster_e5x5_
float ktf_ecal_cluster_e5x5_
Definition: LowPtGsfElectronSeedHeavyObjectCache.h:30
DDAxes::rho
lowptgsfeleseed::Features::ktf_ecal_cluster_covEtaEta_
float ktf_ecal_cluster_covEtaEta_
Definition: LowPtGsfElectronSeedHeavyObjectCache.h:31
lowptgsfeleseed::Features::trk_nhits_
float trk_nhits_
Definition: LowPtGsfElectronSeedHeavyObjectCache.h:22
lowptgsfeleseed::Features::ktf_hcal_cluster_e_
float ktf_hcal_cluster_e_
Definition: LowPtGsfElectronSeedHeavyObjectCache.h:36
edm::Ref::isNonnull
bool isNonnull() const
Checks for non-null.
Definition: Ref.h:238
lowptgsfeleseed::Features::ktf_ecal_cluster_circularity_
float ktf_ecal_cluster_circularity_
Definition: LowPtGsfElectronSeedHeavyObjectCache.h:35
tools
Definition: tools.py:1
lowptgsfeleseed::Features::trk_pt_
float trk_pt_
Definition: LowPtGsfElectronSeedHeavyObjectCache.h:18
reco::TrackBase::qualityByName
static TrackQuality qualityByName(const std::string &name)
Definition: TrackBase.cc:126
lowptgsfeleseed::Features::ktf_ecal_cluster_e_
float ktf_ecal_cluster_e_
Definition: LowPtGsfElectronSeedHeavyObjectCache.h:26
lowptgsfeleseed::Features::ktf_ecal_cluster_covPhiPhi_
float ktf_ecal_cluster_covPhiPhi_
Definition: LowPtGsfElectronSeedHeavyObjectCache.h:33
lowptgsfeleseed::Features::preid_trk_gsf_chiratio_
float preid_trk_gsf_chiratio_
Definition: LowPtGsfElectronSeedHeavyObjectCache.h:40
bsc_activity_cfg.ecal
ecal
Definition: bsc_activity_cfg.py:25
lowptgsfeleseed::Features::ktf_ecal_cluster_e3x3_
float ktf_ecal_cluster_e3x3_
Definition: LowPtGsfElectronSeedHeavyObjectCache.h:29
lowptgsfeleseed::Features::trk_phi_
float trk_phi_
Definition: LowPtGsfElectronSeedHeavyObjectCache.h:20
lowptgsfeleseed::Features::trk_eta_
float trk_eta_
Definition: LowPtGsfElectronSeedHeavyObjectCache.h:19
lowptgsfeleseed::Features::trk_chi2red_
float trk_chi2red_
Definition: LowPtGsfElectronSeedHeavyObjectCache.h:24
lowptgsfeleseed::Features::ktf_ecal_cluster_dphi_
float ktf_ecal_cluster_dphi_
Definition: LowPtGsfElectronSeedHeavyObjectCache.h:28