CMS 3D CMS Logo

Functions
HGCalTileIndex Namespace Reference

Functions

int32_t tileCassette (int32_t, int32_t, int32_t, int32_t)
 
bool tileExist (const int32_t *hex, int32_t zside, int32_t phi)
 
bool tileFineExist (const int32_t *hex, int32_t zside, int32_t phi)
 
int32_t tileIndex (int32_t layer, int32_t ring, int32_t phi)
 
int32_t tileLayer (int32_t index)
 
int32_t tilePack (int32_t ly, int32_t k1, int32_t k2)
 
int32_t tilePhi (int32_t index)
 
int32_t tileProperty (int32_t, int32_t)
 
int32_t tileRing (int32_t index)
 
int32_t tileSiPM (int32_t)
 
int32_t tileType (int32_t)
 
std::tuple< int32_t, int32_t, int32_t > tileUnpack (int32_t index)
 

Function Documentation

◆ tileCassette()

int32_t HGCalTileIndex::tileCassette ( int32_t  iphi,
int32_t  phiOffset,
int32_t  nphiCassette,
int32_t  cassettes 
)

Definition at line 27 of file HGCalTileIndex.cc.

References hcalRecHitTable_cff::iphi, and gmt_cfi::phiOffset.

Referenced by HGCalDDDConstants::assignCellTrap(), HGCalDDDConstants::cassetteTile(), and HGCalDDDConstants::locateCellTrap().

27  {
28  int32_t cassette(0);
29  if (nphiCassette > 1) {
30  cassette = (iphi - phiOffset) / nphiCassette;
31  if (cassette < 0)
32  cassette += cassettes;
33  else if (cassette >= cassettes)
34  cassette = cassettes - 1;
35  }
36  return (cassette + 1);
37 }
phiOffset
Definition: gmt_cfi.py:37

◆ tileExist()

bool HGCalTileIndex::tileExist ( const int32_t *  hex,
int32_t  zside,
int32_t  phi 
)

Definition at line 67 of file HGCalTileIndex.cc.

References TauDecayModes::dec, hcalRecHitTable_cff::iphi, findQualityFiles::jj, HGCalProperty::kHGCalTilePhis, HGCalProperty::kHGCalTilePhisBy2, HGCalProperty::kHGCalTilePhisBy3, HGCalProperty::kHGCalTilePhisWord, convertSQLiteXML::ok, PVValHelper::phi, and ecaldqm::zside().

Referenced by HGCalDDDConstants::tileExist().

67  {
68  int32_t phi(iphi - 1);
69  if (zside > 0) {
73  }
77  bool ok = (hex[iw] & (1 << ibit));
78 #ifdef EDM_ML_DEBUG
79  edm::LogVerbatim("HGCalGeom") << "tileExist::Phi " << iphi << " " << phi << " zside " << zside << " jj|iw|ibit " << jj
80  << "|" << iw << "|" << ibit << " hex " << std::hex << hex[iw] << std::dec << " OK "
81  << ok;
82 #endif
83  return ok;
84 }
Log< level::Info, true > LogVerbatim
constexpr int32_t kHGCalTilePhisBy3
Definition: HGCalProperty.h:52
int zside(DetId const &)
constexpr int32_t kHGCalTilePhis
Definition: HGCalProperty.h:48
constexpr int32_t kHGCalTilePhisWord
Definition: HGCalProperty.h:50
constexpr int32_t kHGCalTilePhisBy2
Definition: HGCalProperty.h:51

◆ tileFineExist()

bool HGCalTileIndex::tileFineExist ( const int32_t *  hex,
int32_t  zside,
int32_t  phi 
)

Definition at line 86 of file HGCalTileIndex.cc.

References TauDecayModes::dec, hcalRecHitTable_cff::iphi, findQualityFiles::jj, HGCalProperty::kHGCalFineTilePhis, HGCalProperty::kHGCalFineTilePhisBy2, HGCalProperty::kHGCalFineTilePhisBy3, HGCalProperty::kHGCalTilePhisWord, convertSQLiteXML::ok, PVValHelper::phi, and ecaldqm::zside().

86  {
87  int32_t phi(iphi - 1);
88  if (zside > 0) {
92  }
96  bool ok = (hex[iw] & (1 << ibit));
97 #ifdef EDM_ML_DEBUG
98  edm::LogVerbatim("HGCalGeom") << "tileFineexist::Phi " << iphi << " " << phi << " zside " << zside << " jj|iw|ibit "
99  << jj << "|" << iw << "|" << ibit << " hex " << std::hex << hex[iw] << std::dec
100  << " OK " << ok;
101 #endif
102  return ok;
103 }
Log< level::Info, true > LogVerbatim
int zside(DetId const &)
constexpr int32_t kHGCalFineTilePhis
Definition: HGCalProperty.h:49
constexpr int32_t kHGCalFineTilePhisBy3
Definition: HGCalProperty.h:54
constexpr int32_t kHGCalFineTilePhisBy2
Definition: HGCalProperty.h:53
constexpr int32_t kHGCalTilePhisWord
Definition: HGCalProperty.h:50

◆ tileIndex()

int32_t HGCalTileIndex::tileIndex ( int32_t  layer,
int32_t  ring,
int32_t  phi 
)

Definition at line 7 of file HGCalTileIndex.cc.

References l1ctLayer2EG_cff::id, HGCalProperty::kHGCalLayerMask, HGCalProperty::kHGCalLayerOffset, HGCalProperty::kHGCalPhiMask, HGCalProperty::kHGCalPhiOffset, HGCalProperty::kHGCalRingMask, HGCalProperty::kHGCalRingOffset, nano_mu_digi_cff::layer, PVValHelper::phi, and relativeConstraints::ring.

Referenced by HGCalTestScintHits::analyze(), HGCalNumberingScheme::getUnitID(), HGCalNumberingScheme::HGCalNumberingScheme(), HGCScintSD::HGCScintSD(), ticl::TracksterLinkingbySkeletons::linkTracksters(), HGCScintSD::setDetUnitId(), HGCalDDDConstants::tileCount(), HGCalDDDConstants::tileExist(), HGCalDDDConstants::tileInfo(), and HGCalDDDConstants::tileType().

7  {
8  int32_t id(0);
12  return id;
13 }
constexpr int32_t kHGCalRingMask
Definition: HGCalProperty.h:35
constexpr int32_t kHGCalPhiOffset
Definition: HGCalProperty.h:32
constexpr int32_t kHGCalLayerOffset
Definition: HGCalProperty.h:29
constexpr int32_t kHGCalLayerMask
Definition: HGCalProperty.h:30
constexpr int32_t kHGCalPhiMask
Definition: HGCalProperty.h:33
constexpr int32_t kHGCalRingOffset
Definition: HGCalProperty.h:34

◆ tileLayer()

int32_t HGCalTileIndex::tileLayer ( int32_t  index)

Definition at line 15 of file HGCalTileIndex.cc.

References HGCalProperty::kHGCalLayerMask, and HGCalProperty::kHGCalLayerOffset.

15  {
17 }
constexpr int32_t kHGCalLayerOffset
Definition: HGCalProperty.h:29
constexpr int32_t kHGCalLayerMask
Definition: HGCalProperty.h:30

◆ tilePack()

int32_t HGCalTileIndex::tilePack ( int32_t  ly,
int32_t  k1,
int32_t  k2 
)

Definition at line 52 of file HGCalTileIndex.cc.

References HGCalProperty::kHGCalTilePack.

◆ tilePhi()

int32_t HGCalTileIndex::tilePhi ( int32_t  index)

Definition at line 23 of file HGCalTileIndex.cc.

References HGCalProperty::kHGCalPhiMask, and HGCalProperty::kHGCalPhiOffset.

23  {
25 }
constexpr int32_t kHGCalPhiOffset
Definition: HGCalProperty.h:32
constexpr int32_t kHGCalPhiMask
Definition: HGCalProperty.h:33

◆ tileProperty()

int32_t HGCalTileIndex::tileProperty ( int32_t  type,
int32_t  sipm 
)

◆ tileRing()

int32_t HGCalTileIndex::tileRing ( int32_t  index)

Definition at line 19 of file HGCalTileIndex.cc.

References HGCalProperty::kHGCalRingMask, and HGCalProperty::kHGCalRingOffset.

19  {
21 }
constexpr int32_t kHGCalRingMask
Definition: HGCalProperty.h:35
constexpr int32_t kHGCalRingOffset
Definition: HGCalProperty.h:34

◆ tileSiPM()

int32_t HGCalTileIndex::tileSiPM ( int32_t  property)

Definition at line 48 of file HGCalTileIndex.cc.

References HGCalProperty::kHGCalFactor, and HGCalProperty::kHGCalOffsetSiPM.

48  {
50 }
constexpr int32_t kHGCalOffsetSiPM
Definition: HGCalProperty.h:45
constexpr int32_t kHGCalFactor
Definition: HGCalProperty.h:37

◆ tileType()

int32_t HGCalTileIndex::tileType ( int32_t  property)

Definition at line 44 of file HGCalTileIndex.cc.

References HGCalProperty::kHGCalFactor, and HGCalProperty::kHGCalOffsetType.

44  {
46 }
constexpr int32_t kHGCalFactor
Definition: HGCalProperty.h:37
constexpr int32_t kHGCalOffsetType
Definition: HGCalProperty.h:44

◆ tileUnpack()

std::tuple< int32_t, int32_t, int32_t > HGCalTileIndex::tileUnpack ( int32_t  index)