CMS 3D CMS Logo

List of all members | Public Member Functions | Private Types | Private Member Functions | Private Attributes | Static Private Attributes
HGCalTriggerNtupleHGCTriggerCells Class Reference
Inheritance diagram for HGCalTriggerNtupleHGCTriggerCells:
HGCalTriggerNtupleBase

Public Member Functions

void fill (const edm::Event &e, const edm::EventSetup &es) final
 
 HGCalTriggerNtupleHGCTriggerCells (const edm::ParameterSet &conf)
 
void initialize (TTree &, const edm::ParameterSet &, edm::ConsumesCollector &&) final
 
 ~HGCalTriggerNtupleHGCTriggerCells () override
 
- Public Member Functions inherited from HGCalTriggerNtupleBase
 HGCalTriggerNtupleBase (const edm::ParameterSet &conf)
 
virtual ~HGCalTriggerNtupleBase ()
 

Private Types

typedef edm::AssociationMap< edm::OneToMany< CaloParticleCollection, l1t::HGCalTriggerCellBxCollection > > CaloToCellsMap
 

Private Member Functions

double calibrate (double, int, unsigned)
 
void clear () final
 
void simhits (const edm::Event &e, std::unordered_map< uint32_t, double > &simhits_ee, std::unordered_map< uint32_t, double > &simhits_fh, std::unordered_map< uint32_t, double > &simhits_bh)
 

Private Attributes

edm::EDGetToken caloparticles_map_token_
 
std::vector< double > fcPerMip_
 
bool fill_simenergy_
 
bool fill_truthmap_
 
bool filter_cells_in_multiclusters_
 
edm::ESHandle< HGCalTriggerGeometryBasegeometry_
 
double keV2fC_
 
std::vector< double > layerWeights_
 
edm::EDGetToken multiclusters_token_
 
edm::EDGetToken simhits_bh_token_
 
edm::EDGetToken simhits_ee_token_
 
edm::EDGetToken simhits_fh_token_
 
std::vector< int > tc_cell_
 
std::vector< int > tc_cellu_
 
std::vector< int > tc_cellv_
 
std::vector< uint32_t > tc_cluster_id_
 
std::vector< uint32_t > tc_compressedCharge_
 
std::vector< uint32_t > tc_data_
 
std::vector< float > tc_energy_
 
std::vector< float > tc_eta_
 
std::vector< int > tc_genparticle_index_
 
std::vector< uint32_t > tc_id_
 
std::vector< int > tc_layer_
 
std::vector< float > tc_mipPt_
 
std::vector< uint32_t > tc_multicluster_id_
 
std::vector< float > tc_multicluster_pt_
 
int tc_n_
 
std::vector< int > tc_panel_number_
 
std::vector< int > tc_panel_sector_
 
std::vector< float > tc_phi_
 
std::vector< float > tc_pt_
 
std::vector< int > tc_side_
 
std::vector< float > tc_simenergy_
 
std::vector< int > tc_subdet_
 
std::vector< uint32_t > tc_uncompressedCharge_
 
std::vector< int > tc_wafer_
 
std::vector< int > tc_wafertype_
 
std::vector< int > tc_waferu_
 
std::vector< int > tc_waferv_
 
std::vector< float > tc_x_
 
std::vector< float > tc_y_
 
std::vector< float > tc_z_
 
std::vector< double > thicknessCorrections_
 
edm::EDGetToken trigger_cells_token_
 
HGCalTriggerTools triggerTools_
 

Static Private Attributes

static const unsigned kPanelMask_ = 0x7F
 
static const unsigned kPanelOffset_ = 0
 
static const unsigned kSectorMask_ = 0x7
 
static const unsigned kSectorOffset_ = 7
 

Additional Inherited Members

Detailed Description

Definition at line 20 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Member Typedef Documentation

Definition at line 85 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Constructor & Destructor Documentation

HGCalTriggerNtupleHGCTriggerCells::HGCalTriggerNtupleHGCTriggerCells ( const edm::ParameterSet conf)

Definition at line 90 of file HGCalTriggerNtupleHGCTriggerCells.cc.

91  : HGCalTriggerNtupleBase(conf),
92  fill_simenergy_(conf.getParameter<bool>("FillSimEnergy")),
93  fill_truthmap_(conf.getParameter<bool>("FillTruthMap")),
94  filter_cells_in_multiclusters_(conf.getParameter<bool>("FilterCellsInMulticlusters")),
95  keV2fC_(conf.getParameter<double>("keV2fC")),
96  fcPerMip_(conf.getParameter<std::vector<double>>("fcPerMip")),
97  layerWeights_(conf.getParameter<std::vector<double>>("layerWeights")),
98  thicknessCorrections_(conf.getParameter<std::vector<double>>("thicknessCorrections")) {}
T getParameter(std::string const &) const
HGCalTriggerNtupleBase(const edm::ParameterSet &conf)
HGCalTriggerNtupleHGCTriggerCells::~HGCalTriggerNtupleHGCTriggerCells ( )
inlineoverride

Member Function Documentation

double HGCalTriggerNtupleHGCTriggerCells::calibrate ( double  energy,
int  thickness,
unsigned  layer 
)
private
void HGCalTriggerNtupleHGCTriggerCells::clear ( void  )
finalprivatevirtual

Implements HGCalTriggerNtupleBase.

Definition at line 368 of file HGCalTriggerNtupleHGCTriggerCells.cc.

References tc_cell_, tc_cellu_, tc_cellv_, tc_cluster_id_, tc_compressedCharge_, tc_data_, tc_energy_, tc_eta_, tc_genparticle_index_, tc_id_, tc_layer_, tc_mipPt_, tc_multicluster_id_, tc_multicluster_pt_, tc_n_, tc_panel_number_, tc_panel_sector_, tc_phi_, tc_pt_, tc_side_, tc_simenergy_, tc_subdet_, tc_uncompressedCharge_, tc_wafer_, tc_wafertype_, tc_waferu_, tc_waferv_, tc_x_, tc_y_, and tc_z_.

Referenced by fill(), and ~HGCalTriggerNtupleHGCTriggerCells().

368  {
369  tc_n_ = 0;
370  tc_id_.clear();
371  tc_subdet_.clear();
372  tc_side_.clear();
373  tc_layer_.clear();
374  tc_wafer_.clear();
375  tc_waferu_.clear();
376  tc_waferv_.clear();
377  tc_wafertype_.clear();
378  tc_panel_number_.clear();
379  tc_panel_sector_.clear();
380  tc_cell_.clear();
381  tc_cellu_.clear();
382  tc_cellv_.clear();
383  tc_data_.clear();
384  tc_uncompressedCharge_.clear();
385  tc_compressedCharge_.clear();
386  tc_mipPt_.clear();
387  tc_pt_.clear();
388  tc_energy_.clear();
389  tc_simenergy_.clear();
390  tc_eta_.clear();
391  tc_phi_.clear();
392  tc_x_.clear();
393  tc_y_.clear();
394  tc_z_.clear();
395  tc_cluster_id_.clear();
396  tc_multicluster_id_.clear();
397  tc_multicluster_pt_.clear();
398  tc_genparticle_index_.clear();
399 }
void HGCalTriggerNtupleHGCTriggerCells::fill ( const edm::Event e,
const edm::EventSetup es 
)
finalvirtual

Implements HGCalTriggerNtupleBase.

Definition at line 160 of file HGCalTriggerNtupleHGCTriggerCells.cc.

References BXVector< T >::begin(), calibrate(), caloparticles_map_token_, HGCalDetId::cell(), clear(), BXVector< T >::end(), HCALHighEnergyHPDFilter_cfi::energy, HGCalTriggerTools::eventSetup(), fill_simenergy_, fill_truthmap_, filter_cells_in_multiclusters_, DetId::Forward, geometry_, edm::EventSetup::get(), edm::Event::getByToken(), HGCalTriggerGeometryBase::getCellsFromTriggerCell(), HGCalTriggerGeometryBase::getModuleFromTriggerCell(), DetId::HGCalHSc, DetId::HGCalTrigger, HGCHEB, triggerObjects_cff::id, HGCScintillatorDetId::ietaAbs(), HGCScintillatorDetId::iphi(), HGCalTriggerTools::isEm(), HGCalTriggerTools::isSilicon(), kPanelMask_, kPanelOffset_, kSectorMask_, kSectorOffset_, HGCalTriggerTools::layerWithOffset(), multiclusters_token_, simhits(), HGCScintillatorDetId::subdet(), HGCalTriggerDetId::subdet(), tc_cell_, tc_cellu_, tc_cellv_, tc_cluster_id_, tc_compressedCharge_, tc_data_, tc_energy_, tc_eta_, tc_genparticle_index_, tc_id_, tc_layer_, tc_mipPt_, tc_multicluster_id_, tc_multicluster_pt_, tc_n_, tc_panel_number_, tc_panel_sector_, tc_phi_, tc_pt_, tc_side_, tc_simenergy_, tc_subdet_, tc_uncompressedCharge_, tc_wafer_, tc_wafertype_, tc_waferu_, tc_waferv_, tc_x_, tc_y_, tc_z_, Calorimetry_cff::thickness, HGCalTriggerTools::thicknessIndex(), trigger_cells_token_, HGCalTriggerDetId::triggerCellU(), HGCalTriggerDetId::triggerCellV(), triggerTools_, HGCScintillatorDetId::type(), HGCalTriggerDetId::type(), HGCalDetId::wafer(), HGCalDetId::waferType(), HGCalTriggerDetId::waferU(), HGCalTriggerDetId::waferV(), and HGCalTriggerTools::zside().

Referenced by ~HGCalTriggerNtupleHGCTriggerCells().

160  {
161  // retrieve trigger cells
163  e.getByToken(trigger_cells_token_, trigger_cells_h);
164  const l1t::HGCalTriggerCellBxCollection& trigger_cells = *trigger_cells_h;
165 
166  // retrieve clusters
168  e.getByToken(multiclusters_token_, multiclusters_h);
169  const l1t::HGCalMulticlusterBxCollection& multiclusters = *multiclusters_h;
170 
171  // retrieve geometry
172  es.get<CaloGeometryRecord>().get(geometry_);
173 
174  // sim hit association
175  std::unordered_map<uint32_t, double> simhits_ee;
176  std::unordered_map<uint32_t, double> simhits_fh;
177  std::unordered_map<uint32_t, double> simhits_bh;
178  if (fill_simenergy_)
179  simhits(e, simhits_ee, simhits_fh, simhits_bh);
180 
181  edm::Handle<CaloToCellsMap> caloparticles_map_h;
182  std::unordered_map<uint32_t, unsigned> cell_to_genparticle;
183  if (fill_truthmap_) {
184  e.getByToken(caloparticles_map_token_, caloparticles_map_h);
185  for (auto& keyval : *caloparticles_map_h) {
186  for (auto& tcref : keyval.val)
187  cell_to_genparticle.emplace(tcref->detId(), keyval.key->g4Tracks().at(0).genpartIndex() - 1);
188  }
189  }
190 
191  // Associate cells to clusters
192  std::unordered_map<uint32_t, uint32_t> cell2cluster;
193  std::unordered_map<uint32_t, l1t::HGCalMulticlusterBxCollection::const_iterator> cell2multicluster;
194  for (auto mcl_itr = multiclusters.begin(0); mcl_itr != multiclusters.end(0); mcl_itr++) {
195  // loop on 2D clusters inside 3D clusters
196  for (const auto& cl_ptr : mcl_itr->constituents()) {
197  // loop on TC inside 2D clusters
198  for (const auto& tc_ptr : cl_ptr.second->constituents()) {
199  cell2cluster.emplace(tc_ptr.second->detId(), cl_ptr.second->detId());
200  cell2multicluster.emplace(tc_ptr.second->detId(), mcl_itr);
201  }
202  }
203  }
204 
206 
207  clear();
208  for (auto tc_itr = trigger_cells.begin(0); tc_itr != trigger_cells.end(0); tc_itr++) {
209  if (tc_itr->hwPt() > 0) {
210  auto cl_itr = cell2cluster.find(tc_itr->detId());
211  auto mcl_itr = cell2multicluster.find(tc_itr->detId());
212  uint32_t cl_id = (cl_itr != cell2cluster.end() ? cl_itr->second : 0);
213  uint32_t mcl_id = (mcl_itr != cell2multicluster.end() ? mcl_itr->second->detId() : 0);
214  float mcl_pt = (mcl_itr != cell2multicluster.end() ? mcl_itr->second->pt() : 0.);
215  // Filter cells not included in a multicluster, if requested
216  if (filter_cells_in_multiclusters_ && mcl_id == 0)
217  continue;
218  tc_n_++;
219  // hardware data
220  DetId id(tc_itr->detId());
222  int panel_sector = -999;
223  int panel_number = -999;
224  if (panelId.det() == DetId::Forward) {
225  HGCalDetId panelIdHGCal(panelId);
226  if (panelId.subdetId() == ForwardSubdetector::HGCHEB) {
227  panel_number = panelIdHGCal.wafer();
228  } else {
229  panel_sector = (panelIdHGCal.wafer() >> kSectorOffset_) & kSectorMask_;
230  panel_number = (panelIdHGCal.wafer() >> kPanelOffset_) & kPanelMask_;
231  }
232  } else if (id.det() == DetId::HGCalHSc) {
233  HGCScintillatorDetId panelIdSci(panelId);
234  panel_sector = panelIdSci.iphi();
235  panel_number = panelIdSci.ietaAbs();
236  }
237  tc_panel_number_.emplace_back(panel_number);
238  tc_panel_sector_.emplace_back(panel_sector);
239  tc_id_.emplace_back(tc_itr->detId());
240  tc_side_.emplace_back(triggerTools_.zside(id));
241  tc_layer_.emplace_back(triggerTools_.layerWithOffset(id));
242  // V9 detids
243  if (id.det() == DetId::HGCalTrigger) {
244  HGCalTriggerDetId idv9(id);
245  tc_subdet_.emplace_back(idv9.subdet());
246  tc_waferu_.emplace_back(idv9.waferU());
247  tc_waferv_.emplace_back(idv9.waferV());
248  tc_wafertype_.emplace_back(idv9.type());
249  tc_cellu_.emplace_back(idv9.triggerCellU());
250  tc_cellv_.emplace_back(idv9.triggerCellV());
251  } else if (id.det() == DetId::HGCalHSc) {
252  HGCScintillatorDetId idv9(id);
253  tc_subdet_.emplace_back(idv9.subdet());
254  tc_waferu_.emplace_back(-999);
255  tc_waferv_.emplace_back(-999);
256  tc_wafertype_.emplace_back(idv9.type());
257  tc_cellu_.emplace_back(idv9.ietaAbs());
258  tc_cellv_.emplace_back(idv9.iphi());
259  }
260  // V8 detids
261  else {
262  HGCalDetId idv8(id);
263  tc_subdet_.emplace_back(id.subdetId());
264  tc_wafer_.emplace_back(idv8.wafer());
265  tc_wafertype_.emplace_back(idv8.waferType());
266  tc_cell_.emplace_back(idv8.cell());
267  }
268  tc_data_.emplace_back(tc_itr->hwPt());
269  tc_uncompressedCharge_.emplace_back(tc_itr->uncompressedCharge());
270  tc_compressedCharge_.emplace_back(tc_itr->compressedCharge());
271  tc_mipPt_.emplace_back(tc_itr->mipPt());
272  // physical values
273  tc_pt_.emplace_back(tc_itr->pt());
274  tc_energy_.emplace_back(tc_itr->energy());
275  tc_eta_.emplace_back(tc_itr->eta());
276  tc_phi_.emplace_back(tc_itr->phi());
277  tc_x_.emplace_back(tc_itr->position().x());
278  tc_y_.emplace_back(tc_itr->position().y());
279  tc_z_.emplace_back(tc_itr->position().z());
280  // Links between TC and clusters
281  tc_cluster_id_.emplace_back(cl_id);
282  tc_multicluster_id_.emplace_back(mcl_id);
283  tc_multicluster_pt_.emplace_back(mcl_pt);
284 
285  if (fill_simenergy_) {
286  double energy = 0;
287  unsigned layer = triggerTools_.layerWithOffset(id);
288  // search for simhit for all the cells inside the trigger cell
289  for (uint32_t c_id : geometry_->getCellsFromTriggerCell(id)) {
291  if (triggerTools_.isEm(id)) {
292  auto itr = simhits_ee.find(c_id);
293  if (itr != simhits_ee.end())
294  energy += calibrate(itr->second, thickness, layer);
295  } else if (triggerTools_.isSilicon(id)) {
296  auto itr = simhits_fh.find(c_id);
297  if (itr != simhits_fh.end())
298  energy += calibrate(itr->second, thickness, layer);
299  } else {
300  auto itr = simhits_bh.find(c_id);
301  if (itr != simhits_bh.end())
302  energy += itr->second;
303  }
304  }
305  tc_simenergy_.emplace_back(energy);
306  }
307  }
308 
309  if (fill_truthmap_) {
310  auto itr(cell_to_genparticle.find(tc_itr->detId()));
311  if (itr == cell_to_genparticle.end())
312  tc_genparticle_index_.push_back(-1);
313  else
314  tc_genparticle_index_.push_back(itr->second);
315  }
316  }
317 }
const_iterator end(int bx) const
edm::ESHandle< HGCalTriggerGeometryBase > geometry_
virtual geom_set getCellsFromTriggerCell(const unsigned cell_det_id) const =0
void eventSetup(const edm::EventSetup &)
bool getByToken(EDGetToken token, Handle< PROD > &result) const
Definition: Event.h:525
unsigned layerWithOffset(const DetId &) const
int zside(const DetId &) const
Definition: DetId.h:17
int thicknessIndex(const DetId &, bool tc=false) const
bool isSilicon(const DetId &) const
virtual unsigned getModuleFromTriggerCell(const unsigned trigger_cell_det_id) const =0
bool isEm(const DetId &) const
T get() const
Definition: EventSetup.h:73
void simhits(const edm::Event &e, std::unordered_map< uint32_t, double > &simhits_ee, std::unordered_map< uint32_t, double > &simhits_fh, std::unordered_map< uint32_t, double > &simhits_bh)
const_iterator begin(int bx) const
void HGCalTriggerNtupleHGCTriggerCells::initialize ( TTree &  tree,
const edm::ParameterSet conf,
edm::ConsumesCollector &&  collector 
)
finalvirtual

Implements HGCalTriggerNtupleBase.

Definition at line 100 of file HGCalTriggerNtupleHGCTriggerCells.cc.

References caloparticles_map_token_, fill_simenergy_, fill_truthmap_, edm::ParameterSet::getParameter(), edm::ParameterSet::getUntrackedParameter(), multiclusters_token_, ZMuMuAnalysisNtupler_cff::prefix, simhits_bh_token_, simhits_ee_token_, simhits_fh_token_, AlCaHLTBitMon_QueryRunRegistry::string, tc_cell_, tc_cellu_, tc_cellv_, tc_cluster_id_, tc_compressedCharge_, tc_data_, tc_energy_, tc_eta_, tc_genparticle_index_, tc_id_, tc_layer_, tc_mipPt_, tc_multicluster_id_, tc_multicluster_pt_, tc_n_, tc_panel_number_, tc_panel_sector_, tc_phi_, tc_pt_, tc_side_, tc_simenergy_, tc_subdet_, tc_uncompressedCharge_, tc_wafer_, tc_wafertype_, tc_waferu_, tc_waferv_, tc_x_, tc_y_, tc_z_, and trigger_cells_token_.

Referenced by ~HGCalTriggerNtupleHGCTriggerCells().

102  {
104  collector.consumes<l1t::HGCalTriggerCellBxCollection>(conf.getParameter<edm::InputTag>("TriggerCells"));
106  collector.consumes<l1t::HGCalMulticlusterBxCollection>(conf.getParameter<edm::InputTag>("Multiclusters"));
107 
108  if (fill_simenergy_) {
112  }
113 
114  if (fill_truthmap_)
116  collector.consumes<CaloToCellsMap>(conf.getParameter<edm::InputTag>("caloParticlesToCells"));
117 
118  std::string prefix(conf.getUntrackedParameter<std::string>("Prefix", "tc"));
119 
120  std::string bname;
121  auto withPrefix([&prefix, &bname](char const* vname) -> char const* {
122  bname = prefix + "_" + vname;
123  return bname.c_str();
124  });
125 
126  tree.Branch(withPrefix("n"), &tc_n_, (prefix + "_n/I").c_str());
127  tree.Branch(withPrefix("id"), &tc_id_);
128  tree.Branch(withPrefix("subdet"), &tc_subdet_);
129  tree.Branch(withPrefix("zside"), &tc_side_);
130  tree.Branch(withPrefix("layer"), &tc_layer_);
131  tree.Branch(withPrefix("wafer"), &tc_wafer_);
132  tree.Branch(withPrefix("waferu"), &tc_waferu_);
133  tree.Branch(withPrefix("waferv"), &tc_waferv_);
134  tree.Branch(withPrefix("wafertype"), &tc_wafertype_);
135  tree.Branch(withPrefix("panel_number"), &tc_panel_number_);
136  tree.Branch(withPrefix("panel_sector"), &tc_panel_sector_);
137  tree.Branch(withPrefix("cell"), &tc_cell_);
138  tree.Branch(withPrefix("cellu"), &tc_cellu_);
139  tree.Branch(withPrefix("cellv"), &tc_cellv_);
140  tree.Branch(withPrefix("data"), &tc_data_);
141  tree.Branch(withPrefix("uncompressedCharge"), &tc_uncompressedCharge_);
142  tree.Branch(withPrefix("compressedCharge"), &tc_compressedCharge_);
143  tree.Branch(withPrefix("pt"), &tc_pt_);
144  tree.Branch(withPrefix("mipPt"), &tc_mipPt_);
145  tree.Branch(withPrefix("energy"), &tc_energy_);
146  if (fill_simenergy_)
147  tree.Branch(withPrefix("simenergy"), &tc_simenergy_);
148  tree.Branch(withPrefix("eta"), &tc_eta_);
149  tree.Branch(withPrefix("phi"), &tc_phi_);
150  tree.Branch(withPrefix("x"), &tc_x_);
151  tree.Branch(withPrefix("y"), &tc_y_);
152  tree.Branch(withPrefix("z"), &tc_z_);
153  tree.Branch(withPrefix("cluster_id"), &tc_cluster_id_);
154  tree.Branch(withPrefix("multicluster_id"), &tc_multicluster_id_);
155  tree.Branch(withPrefix("multicluster_pt"), &tc_multicluster_pt_);
156  if (fill_truthmap_)
157  tree.Branch(withPrefix("genparticle_index"), &tc_genparticle_index_);
158 }
EDGetTokenT< ProductType > consumes(edm::InputTag const &tag)
T getParameter(std::string const &) const
T getUntrackedParameter(std::string const &, T const &) const
std::vector< PCaloHit > PCaloHitContainer
Definition: tree.py:1
edm::AssociationMap< edm::OneToMany< CaloParticleCollection, l1t::HGCalTriggerCellBxCollection > > CaloToCellsMap
void HGCalTriggerNtupleHGCTriggerCells::simhits ( const edm::Event e,
std::unordered_map< uint32_t, double > &  simhits_ee,
std::unordered_map< uint32_t, double > &  simhits_fh,
std::unordered_map< uint32_t, double > &  simhits_bh 
)
private

Definition at line 327 of file HGCalTriggerNtupleHGCTriggerCells.cc.

References HGCalTriggerGeometryBase::bhTopology(), HGCalTriggerGeometryBase::eeTopology(), HGCalTriggerGeometryBase::fhTopology(), geometry_, edm::Event::getByToken(), HGCalTriggerGeometryBase::hscTopology(), HGCalTriggerGeometryBase::isV9Geometry(), simhits_bh_token_, simhits_ee_token_, simhits_fh_token_, HGCalTriggerTools::simToReco(), and triggerTools_.

Referenced by fill(), and ~HGCalTriggerNtupleHGCTriggerCells().

330  {
332  e.getByToken(simhits_ee_token_, ee_simhits_h);
333  const edm::PCaloHitContainer& ee_simhits = *ee_simhits_h;
335  e.getByToken(simhits_fh_token_, fh_simhits_h);
336  const edm::PCaloHitContainer& fh_simhits = *fh_simhits_h;
338  e.getByToken(simhits_bh_token_, bh_simhits_h);
339  const edm::PCaloHitContainer& bh_simhits = *bh_simhits_h;
340 
341  //EE
342  for (const auto& simhit : ee_simhits) {
343  DetId id = triggerTools_.simToReco(simhit.id(), geometry_->eeTopology());
344  if (id.rawId() == 0)
345  continue;
346  auto itr_insert = simhits_ee.emplace(id, 0.);
347  itr_insert.first->second += simhit.energy();
348  }
349  // FH
350  for (const auto& simhit : fh_simhits) {
351  DetId id = triggerTools_.simToReco(simhit.id(), geometry_->fhTopology());
352  if (id.rawId() == 0)
353  continue;
354  auto itr_insert = simhits_fh.emplace(id, 0.);
355  itr_insert.first->second += simhit.energy();
356  }
357  // BH
358  for (const auto& simhit : bh_simhits) {
360  : triggerTools_.simToReco(simhit.id(), geometry_->bhTopology()));
361  if (id.rawId() == 0)
362  continue;
363  auto itr_insert = simhits_bh.emplace(id, 0.);
364  itr_insert.first->second += simhit.energy();
365  }
366 }
edm::ESHandle< HGCalTriggerGeometryBase > geometry_
std::vector< PCaloHit > PCaloHitContainer
bool getByToken(EDGetToken token, Handle< PROD > &result) const
Definition: Event.h:525
const HGCalTopology & eeTopology() const
const HcalTopology & bhTopology() const
Definition: DetId.h:17
const HGCalTopology & hscTopology() const
DetId simToReco(const DetId &, const HGCalTopology &) const
const HGCalTopology & fhTopology() const

Member Data Documentation

edm::EDGetToken HGCalTriggerNtupleHGCTriggerCells::caloparticles_map_token_
private

Definition at line 39 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by fill(), and initialize().

std::vector<double> HGCalTriggerNtupleHGCTriggerCells::fcPerMip_
private

Definition at line 44 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by calibrate().

bool HGCalTriggerNtupleHGCTriggerCells::fill_simenergy_
private

Definition at line 40 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by fill(), and initialize().

bool HGCalTriggerNtupleHGCTriggerCells::fill_truthmap_
private

Definition at line 41 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by fill(), and initialize().

bool HGCalTriggerNtupleHGCTriggerCells::filter_cells_in_multiclusters_
private

Definition at line 42 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by fill().

edm::ESHandle<HGCalTriggerGeometryBase> HGCalTriggerNtupleHGCTriggerCells::geometry_
private

Definition at line 47 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by fill(), and simhits().

double HGCalTriggerNtupleHGCTriggerCells::keV2fC_
private

Definition at line 43 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by calibrate().

const unsigned HGCalTriggerNtupleHGCTriggerCells::kPanelMask_ = 0x7F
staticprivate

Definition at line 50 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by fill().

const unsigned HGCalTriggerNtupleHGCTriggerCells::kPanelOffset_ = 0
staticprivate

Definition at line 49 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by fill().

const unsigned HGCalTriggerNtupleHGCTriggerCells::kSectorMask_ = 0x7
staticprivate

Definition at line 52 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by fill().

const unsigned HGCalTriggerNtupleHGCTriggerCells::kSectorOffset_ = 7
staticprivate

Definition at line 51 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by fill().

std::vector<double> HGCalTriggerNtupleHGCTriggerCells::layerWeights_
private

Definition at line 45 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by calibrate().

edm::EDGetToken HGCalTriggerNtupleHGCTriggerCells::multiclusters_token_
private

Definition at line 37 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by fill(), and initialize().

edm::EDGetToken HGCalTriggerNtupleHGCTriggerCells::simhits_bh_token_
private

Definition at line 38 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by initialize(), and simhits().

edm::EDGetToken HGCalTriggerNtupleHGCTriggerCells::simhits_ee_token_
private

Definition at line 38 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by initialize(), and simhits().

edm::EDGetToken HGCalTriggerNtupleHGCTriggerCells::simhits_fh_token_
private

Definition at line 38 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by initialize(), and simhits().

std::vector<int> HGCalTriggerNtupleHGCTriggerCells::tc_cell_
private

Definition at line 65 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by clear(), fill(), and initialize().

std::vector<int> HGCalTriggerNtupleHGCTriggerCells::tc_cellu_
private

Definition at line 66 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by clear(), fill(), and initialize().

std::vector<int> HGCalTriggerNtupleHGCTriggerCells::tc_cellv_
private

Definition at line 67 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by clear(), fill(), and initialize().

std::vector<uint32_t> HGCalTriggerNtupleHGCTriggerCells::tc_cluster_id_
private

Definition at line 80 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by clear(), fill(), and initialize().

std::vector<uint32_t> HGCalTriggerNtupleHGCTriggerCells::tc_compressedCharge_
private

Definition at line 70 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by clear(), fill(), and initialize().

std::vector<uint32_t> HGCalTriggerNtupleHGCTriggerCells::tc_data_
private

Definition at line 68 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by clear(), fill(), and initialize().

std::vector<float> HGCalTriggerNtupleHGCTriggerCells::tc_energy_
private

Definition at line 73 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by clear(), fill(), and initialize().

std::vector<float> HGCalTriggerNtupleHGCTriggerCells::tc_eta_
private

Definition at line 75 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by clear(), fill(), and initialize().

std::vector<int> HGCalTriggerNtupleHGCTriggerCells::tc_genparticle_index_
private

Definition at line 83 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by clear(), fill(), and initialize().

std::vector<uint32_t> HGCalTriggerNtupleHGCTriggerCells::tc_id_
private

Definition at line 55 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by clear(), fill(), and initialize().

std::vector<int> HGCalTriggerNtupleHGCTriggerCells::tc_layer_
private

Definition at line 58 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by clear(), fill(), and initialize().

std::vector<float> HGCalTriggerNtupleHGCTriggerCells::tc_mipPt_
private

Definition at line 71 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by clear(), fill(), and initialize().

std::vector<uint32_t> HGCalTriggerNtupleHGCTriggerCells::tc_multicluster_id_
private

Definition at line 81 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by clear(), fill(), and initialize().

std::vector<float> HGCalTriggerNtupleHGCTriggerCells::tc_multicluster_pt_
private

Definition at line 82 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by clear(), fill(), and initialize().

int HGCalTriggerNtupleHGCTriggerCells::tc_n_
private

Definition at line 54 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by clear(), fill(), and initialize().

std::vector<int> HGCalTriggerNtupleHGCTriggerCells::tc_panel_number_
private

Definition at line 59 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by clear(), fill(), and initialize().

std::vector<int> HGCalTriggerNtupleHGCTriggerCells::tc_panel_sector_
private

Definition at line 60 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by clear(), fill(), and initialize().

std::vector<float> HGCalTriggerNtupleHGCTriggerCells::tc_phi_
private

Definition at line 76 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by clear(), fill(), and initialize().

std::vector<float> HGCalTriggerNtupleHGCTriggerCells::tc_pt_
private

Definition at line 72 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by clear(), fill(), and initialize().

std::vector<int> HGCalTriggerNtupleHGCTriggerCells::tc_side_
private

Definition at line 57 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by clear(), fill(), and initialize().

std::vector<float> HGCalTriggerNtupleHGCTriggerCells::tc_simenergy_
private

Definition at line 74 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by clear(), fill(), and initialize().

std::vector<int> HGCalTriggerNtupleHGCTriggerCells::tc_subdet_
private

Definition at line 56 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by clear(), fill(), and initialize().

std::vector<uint32_t> HGCalTriggerNtupleHGCTriggerCells::tc_uncompressedCharge_
private

Definition at line 69 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by clear(), fill(), and initialize().

std::vector<int> HGCalTriggerNtupleHGCTriggerCells::tc_wafer_
private

Definition at line 61 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by clear(), fill(), and initialize().

std::vector<int> HGCalTriggerNtupleHGCTriggerCells::tc_wafertype_
private

Definition at line 64 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by clear(), fill(), and initialize().

std::vector<int> HGCalTriggerNtupleHGCTriggerCells::tc_waferu_
private

Definition at line 62 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by clear(), fill(), and initialize().

std::vector<int> HGCalTriggerNtupleHGCTriggerCells::tc_waferv_
private

Definition at line 63 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by clear(), fill(), and initialize().

std::vector<float> HGCalTriggerNtupleHGCTriggerCells::tc_x_
private

Definition at line 77 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by clear(), fill(), and initialize().

std::vector<float> HGCalTriggerNtupleHGCTriggerCells::tc_y_
private

Definition at line 78 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by clear(), fill(), and initialize().

std::vector<float> HGCalTriggerNtupleHGCTriggerCells::tc_z_
private

Definition at line 79 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by clear(), fill(), and initialize().

std::vector<double> HGCalTriggerNtupleHGCTriggerCells::thicknessCorrections_
private

Definition at line 46 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by calibrate().

edm::EDGetToken HGCalTriggerNtupleHGCTriggerCells::trigger_cells_token_
private

Definition at line 37 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by fill(), and initialize().

HGCalTriggerTools HGCalTriggerNtupleHGCTriggerCells::triggerTools_
private

Definition at line 35 of file HGCalTriggerNtupleHGCTriggerCells.cc.

Referenced by fill(), and simhits().