ATLAS Offline Software
Loading...
Searching...
No Matches
LArEM_region Class Reference

This class provides an interface to deal with regions in the neighbours finding. More...

#include <LArEM_region.h>

Collaboration diagram for LArEM_region:

Public Member Functions

 LArEM_region ()
 LArEM_region (unsigned int &minHash, short int &nbEtaBins, short int &nPhi, float minEta, float granulEta, float minPhi, float granulPhi, bool fullSym, bool isBarrelMiddle, short int &prevEtaReg, short int &nextEtaReg, std::vector< short int > &prevSampReg, std::vector< short int > &nextSampReg, std::vector< short int > &prevSubdetReg, std::vector< short int > &nextSubdetReg)
 ~LArEM_region ()
short int numberOfEta () const
 number of eta bins in the whole region
short int phiN () const
 number of phi bins
float etaGranularity () const
 eta granularity
float phiGranularity () const
 phi granularity
bool fullTwoPi () const
 true if detector covers full 2pi (== wraparound option in dictionary)
bool isFirstBarrelRegion () const
 true if region close to barrel middle
float etaMin () const
 starting eta
float etaMax () const
 end eta
float phiMin () const
 starting phi
float phiMax () const
 end phi
unsigned int hashMin () const
 hash Id of the first cell of the region
unsigned int hashMax () const
 hash Id of the last cell of the region +1
short int prevEtaRegion () const
 region number of the previous region in eta
short int nextEtaRegion () const
 region number of the next region in eta
bool isEtaMin (unsigned int index) const
 is the considered cell in the first eta bin of the region ?
bool isEtaMax (unsigned int index) const
 is the considered cell in the last eta bin of the region ?
bool isPhiMin (unsigned int index) const
 is the considered cell in the first phi bin of the region ?
bool isPhiMax (unsigned int index) const
 is the considered cell in the last phi bin of the region ?
const std::vector< short int > & prevSamplingRegion () const
 region number of the prev region in sampling
const std::vector< short int > & nextSamplingRegion () const
 region number of the next region in sampling
const std::vector< short int > & prevSubdetRegion () const
 region number of the prev region in subdet
const std::vector< short int > & nextSubdetRegion () const
 region number of the next region in subdet

Private Attributes

unsigned int m_hashMin
short int m_nbEtaBins
short int m_nPhi
float m_minEta
float m_granulEta
float m_minPhi
float m_granulPhi
bool m_fullSym
bool m_isFirstBarrelRegion
short int m_prevEtaReg
short int m_nextEtaReg
std::vector< short int > m_prevSampReg
std::vector< short int > m_nextSampReg
std::vector< short int > m_prevSubdetReg
std::vector< short int > m_nextSubdetReg

Detailed Description

This class provides an interface to deal with regions in the neighbours finding.

Definition at line 19 of file LArEM_region.h.

Constructor & Destructor Documentation

◆ LArEM_region() [1/2]

LArEM_region::LArEM_region ( )

Definition at line 12 of file LArEM_region.cxx.

12 :
13 m_hashMin(0)
14 ,m_nbEtaBins(0)
15 ,m_nPhi(0)
16 ,m_minEta(99)
17 ,m_granulEta(0)
18 ,m_minPhi(99)
19 ,m_granulPhi(0)
20 ,m_fullSym(true)
22 ,m_prevEtaReg(63)
23 ,m_nextEtaReg(63)
24{
25}
short int m_nextEtaReg
short int m_nPhi
bool m_isFirstBarrelRegion
unsigned int m_hashMin
short int m_prevEtaReg
short int m_nbEtaBins

◆ LArEM_region() [2/2]

LArEM_region::LArEM_region ( unsigned int & minHash,
short int & nbEtaBins,
short int & nPhi,
float minEta,
float granulEta,
float minPhi,
float granulPhi,
bool fullSym,
bool isBarrelMiddle,
short int & prevEtaReg,
short int & nextEtaReg,
std::vector< short int > & prevSampReg,
std::vector< short int > & nextSampReg,
std::vector< short int > & prevSubdetReg,
std::vector< short int > & nextSubdetReg )

Definition at line 27 of file LArEM_region.cxx.

32 : m_hashMin (minHash),
33 m_nbEtaBins (nbEtaBins),
34 m_nPhi (nPhi),
35 m_minEta (minEta),
36 m_granulEta (granulEta),
37 m_minPhi (minPhi),
38 m_granulPhi (granulPhi),
39 m_fullSym (fullSym),
40 m_isFirstBarrelRegion (isBarrelMiddle),
41 m_prevEtaReg (prevEtaReg),
42 m_nextEtaReg (nextEtaReg),
43 m_prevSampReg (prevSampReg),
44 m_nextSampReg (nextSampReg),
45 m_prevSubdetReg (prevSubdetReg),
46 m_nextSubdetReg (nextSubdetReg)
47{
48
49
50}
std::vector< short int > m_prevSubdetReg
std::vector< short int > m_nextSampReg
std::vector< short int > m_nextSubdetReg
std::vector< short int > m_prevSampReg

◆ ~LArEM_region()

LArEM_region::~LArEM_region ( )
default

Member Function Documentation

◆ etaGranularity()

float LArEM_region::etaGranularity ( ) const
inline

eta granularity

Definition at line 40 of file LArEM_region.h.

40{ return m_granulEta ; }

◆ etaMax()

float LArEM_region::etaMax ( ) const
inline

end eta

Definition at line 55 of file LArEM_region.h.

55{ return (m_minEta + m_nbEtaBins*m_granulEta) ; }

◆ etaMin()

float LArEM_region::etaMin ( ) const
inline

starting eta

Definition at line 52 of file LArEM_region.h.

52{ return m_minEta ; }

◆ fullTwoPi()

bool LArEM_region::fullTwoPi ( ) const
inline

true if detector covers full 2pi (== wraparound option in dictionary)

Definition at line 46 of file LArEM_region.h.

46{ return m_fullSym ; }

◆ hashMax()

unsigned int LArEM_region::hashMax ( ) const
inline

hash Id of the last cell of the region +1

Definition at line 67 of file LArEM_region.h.

67{ return (m_hashMin + m_nbEtaBins * m_nPhi) ; }

◆ hashMin()

unsigned int LArEM_region::hashMin ( ) const
inline

hash Id of the first cell of the region

Definition at line 64 of file LArEM_region.h.

64{ return m_hashMin ; }

◆ isEtaMax()

bool LArEM_region::isEtaMax ( unsigned int index) const
inline

is the considered cell in the last eta bin of the region ?

Definition at line 81 of file LArEM_region.h.

81 {
82 return ((hashMax()-m_nPhi)<=index) && (index<hashMax());
83 }
unsigned int hashMax() const
hash Id of the last cell of the region +1
str index
Definition DeMoScan.py:362

◆ isEtaMin()

bool LArEM_region::isEtaMin ( unsigned int index) const
inline

is the considered cell in the first eta bin of the region ?

Definition at line 76 of file LArEM_region.h.

76 {
77 return ((m_hashMin<=index) && (index<(m_hashMin+m_nPhi)));
78 }

◆ isFirstBarrelRegion()

bool LArEM_region::isFirstBarrelRegion ( ) const
inline

true if region close to barrel middle

Definition at line 49 of file LArEM_region.h.

49{ return m_isFirstBarrelRegion ; }

◆ isPhiMax()

bool LArEM_region::isPhiMax ( unsigned int index) const
inline

is the considered cell in the last phi bin of the region ?

Definition at line 91 of file LArEM_region.h.

91 {
92 return !m_fullSym && (index-m_hashMin+1)%m_nPhi == 0;
93 }

◆ isPhiMin()

bool LArEM_region::isPhiMin ( unsigned int index) const
inline

is the considered cell in the first phi bin of the region ?

Definition at line 86 of file LArEM_region.h.

86 {
87 return !m_fullSym && (index-m_hashMin)%m_nPhi == 0;
88 }

◆ nextEtaRegion()

short int LArEM_region::nextEtaRegion ( ) const
inline

region number of the next region in eta

Definition at line 73 of file LArEM_region.h.

73{ return m_nextEtaReg; }

◆ nextSamplingRegion()

const std::vector< short int > & LArEM_region::nextSamplingRegion ( ) const
inline

region number of the next region in sampling

Definition at line 99 of file LArEM_region.h.

99{ return m_nextSampReg; }

◆ nextSubdetRegion()

const std::vector< short int > & LArEM_region::nextSubdetRegion ( ) const
inline

region number of the next region in subdet

Definition at line 105 of file LArEM_region.h.

105{ return m_nextSubdetReg; }

◆ numberOfEta()

short int LArEM_region::numberOfEta ( ) const
inline

number of eta bins in the whole region

Definition at line 34 of file LArEM_region.h.

34{ return m_nbEtaBins ; }

◆ phiGranularity()

float LArEM_region::phiGranularity ( ) const
inline

phi granularity

Definition at line 43 of file LArEM_region.h.

43{ return m_granulPhi ; }

◆ phiMax()

float LArEM_region::phiMax ( ) const
inline

end phi

Definition at line 61 of file LArEM_region.h.

61{ return (m_minPhi + m_nPhi*m_granulPhi) ; }

◆ phiMin()

float LArEM_region::phiMin ( ) const
inline

starting phi

Definition at line 58 of file LArEM_region.h.

58{ return m_minPhi ; }

◆ phiN()

short int LArEM_region::phiN ( ) const
inline

number of phi bins

Definition at line 37 of file LArEM_region.h.

37{ return m_nPhi ; }

◆ prevEtaRegion()

short int LArEM_region::prevEtaRegion ( ) const
inline

region number of the previous region in eta

Definition at line 70 of file LArEM_region.h.

70{ return m_prevEtaReg; }

◆ prevSamplingRegion()

const std::vector< short int > & LArEM_region::prevSamplingRegion ( ) const
inline

region number of the prev region in sampling

Definition at line 96 of file LArEM_region.h.

96{ return m_prevSampReg; }

◆ prevSubdetRegion()

const std::vector< short int > & LArEM_region::prevSubdetRegion ( ) const
inline

region number of the prev region in subdet

Definition at line 102 of file LArEM_region.h.

102{ return m_prevSubdetReg; }

Member Data Documentation

◆ m_fullSym

bool LArEM_region::m_fullSym
private

Definition at line 116 of file LArEM_region.h.

◆ m_granulEta

float LArEM_region::m_granulEta
private

Definition at line 113 of file LArEM_region.h.

◆ m_granulPhi

float LArEM_region::m_granulPhi
private

Definition at line 115 of file LArEM_region.h.

◆ m_hashMin

unsigned int LArEM_region::m_hashMin
private

Definition at line 109 of file LArEM_region.h.

◆ m_isFirstBarrelRegion

bool LArEM_region::m_isFirstBarrelRegion
private

Definition at line 117 of file LArEM_region.h.

◆ m_minEta

float LArEM_region::m_minEta
private

Definition at line 112 of file LArEM_region.h.

◆ m_minPhi

float LArEM_region::m_minPhi
private

Definition at line 114 of file LArEM_region.h.

◆ m_nbEtaBins

short int LArEM_region::m_nbEtaBins
private

Definition at line 110 of file LArEM_region.h.

◆ m_nextEtaReg

short int LArEM_region::m_nextEtaReg
private

Definition at line 120 of file LArEM_region.h.

◆ m_nextSampReg

std::vector<short int> LArEM_region::m_nextSampReg
private

Definition at line 122 of file LArEM_region.h.

◆ m_nextSubdetReg

std::vector<short int> LArEM_region::m_nextSubdetReg
private

Definition at line 124 of file LArEM_region.h.

◆ m_nPhi

short int LArEM_region::m_nPhi
private

Definition at line 111 of file LArEM_region.h.

◆ m_prevEtaReg

short int LArEM_region::m_prevEtaReg
private

Definition at line 119 of file LArEM_region.h.

◆ m_prevSampReg

std::vector<short int> LArEM_region::m_prevSampReg
private

Definition at line 121 of file LArEM_region.h.

◆ m_prevSubdetReg

std::vector<short int> LArEM_region::m_prevSubdetReg
private

Definition at line 123 of file LArEM_region.h.


The documentation for this class was generated from the following files: