CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
p2eg::card Class Reference

#include <Phase2L1CaloEGammaUtils.h>

Public Member Functions

 card ()
 
float getIdx () const
 
region3x4getRegion3x4 (int idx)
 
towers3x4getTowers3x4 (int idx)
 
void setIdx (int idx)
 
void zeroOut ()
 

Private Attributes

std::array< region3x4, N_REGIONS_PER_CARDcard3x4Regions
 
std::array< towers3x4, N_REGIONS_PER_CARDcard3x4Towers
 
int idx_ = -1
 

Detailed Description

Definition at line 483 of file Phase2L1CaloEGammaUtils.h.

Constructor & Destructor Documentation

◆ card()

p2eg::card::card ( )
inline

Definition at line 491 of file Phase2L1CaloEGammaUtils.h.

References card3x4Regions, card3x4Towers, mps_fire::i, idx_, and p2eg::N_REGIONS_PER_CARD.

491  {
492  idx_ = -1;
493  for (int i = 0; i < N_REGIONS_PER_CARD; i++) {
494  card3x4Regions[i].setIdx(i);
495  card3x4Regions[i].zeroOut();
496  card3x4Towers[i].setIdx(i);
497  card3x4Towers[i].zeroOut();
498  }
499  };
static constexpr int N_REGIONS_PER_CARD
std::array< towers3x4, N_REGIONS_PER_CARD > card3x4Towers
std::array< region3x4, N_REGIONS_PER_CARD > card3x4Regions

Member Function Documentation

◆ getIdx()

float p2eg::card::getIdx ( ) const
inline

Definition at line 511 of file Phase2L1CaloEGammaUtils.h.

References idx_.

511 { return idx_; };

◆ getRegion3x4()

region3x4& p2eg::card::getRegion3x4 ( int  idx)
inline

Definition at line 512 of file Phase2L1CaloEGammaUtils.h.

References cms::cuda::assert(), card3x4Regions, heavyIonCSV_trainingSettings::idx, and p2eg::N_REGIONS_PER_CARD.

Referenced by Phase2L1CaloEGammaEmulator::produce().

512  {
514  return card3x4Regions[idx];
515  }
assert(be >=bs)
static constexpr int N_REGIONS_PER_CARD
std::array< region3x4, N_REGIONS_PER_CARD > card3x4Regions

◆ getTowers3x4()

towers3x4& p2eg::card::getTowers3x4 ( int  idx)
inline

Definition at line 516 of file Phase2L1CaloEGammaUtils.h.

References cms::cuda::assert(), card3x4Towers, heavyIonCSV_trainingSettings::idx, and p2eg::N_REGIONS_PER_CARD.

Referenced by Phase2L1CaloEGammaEmulator::produce().

516  {
518  return card3x4Towers[idx];
519  }
assert(be >=bs)
static constexpr int N_REGIONS_PER_CARD
std::array< towers3x4, N_REGIONS_PER_CARD > card3x4Towers

◆ setIdx()

void p2eg::card::setIdx ( int  idx)
inline

◆ zeroOut()

void p2eg::card::zeroOut ( )
inline

Definition at line 503 of file Phase2L1CaloEGammaUtils.h.

References card3x4Regions, card3x4Towers, mps_fire::i, and p2eg::N_REGIONS_PER_CARD.

503  {
504  for (int i = 0; i < N_REGIONS_PER_CARD; i++) {
505  card3x4Regions[i].zeroOut();
506  card3x4Towers[i].zeroOut();
507  };
508  };
static constexpr int N_REGIONS_PER_CARD
std::array< towers3x4, N_REGIONS_PER_CARD > card3x4Towers
std::array< region3x4, N_REGIONS_PER_CARD > card3x4Regions

Member Data Documentation

◆ card3x4Regions

std::array<region3x4, N_REGIONS_PER_CARD> p2eg::card::card3x4Regions
private

Definition at line 486 of file Phase2L1CaloEGammaUtils.h.

Referenced by card(), getRegion3x4(), and zeroOut().

◆ card3x4Towers

std::array<towers3x4, N_REGIONS_PER_CARD> p2eg::card::card3x4Towers
private

Definition at line 487 of file Phase2L1CaloEGammaUtils.h.

Referenced by card(), getTowers3x4(), and zeroOut().

◆ idx_

int p2eg::card::idx_ = -1
private

Definition at line 485 of file Phase2L1CaloEGammaUtils.h.

Referenced by card(), getIdx(), and setIdx().