ATLAS Offline Software
Classes | Public Member Functions | Protected Member Functions | Private Types | Private Member Functions | Private Attributes | List of all members
TrigL2MuonSA::CscRegDict Class Reference

#include <CscRegUtils.h>

Inheritance diagram for TrigL2MuonSA::CscRegDict:
Collaboration diagram for TrigL2MuonSA::CscRegDict:

Classes

struct  CscRegion
 

Public Member Functions

 CscRegDict (const std::string &type, const std::string &name, const IInterface *parent)
 
virtual StatusCode initialize () override
 
double phiCen (int module)
 
double phiMod (int module) const
 
int get_hash (int stationname, int stationeta, int stationphi) const
 
Amg::Vector3D nomalVector (int module) const
 
double displacement (int module) const
 
double posCorrectionR (int module, int charge)
 
double posCorrectionZ (int module, int charge)
 
double idealAtanNormal (int module) const
 
double actualAtanNormal (int module) const
 
int stationName (int hash) const
 
int stationEta (int hash) const
 
int stationPhi (int hash) const
 
ServiceHandle< StoreGateSvc > & evtStore ()
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc. More...
 
const ServiceHandle< StoreGateSvc > & evtStore () const
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc. More...
 
const ServiceHandle< StoreGateSvc > & detStore () const
 The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc. More...
 
virtual StatusCode sysInitialize () override
 Perform system initialization for an algorithm. More...
 
virtual StatusCode sysStart () override
 Handle START transition. More...
 
virtual std::vector< Gaudi::DataHandle * > inputHandles () const override
 Return this algorithm's input handles. More...
 
virtual std::vector< Gaudi::DataHandle * > outputHandles () const override
 Return this algorithm's output handles. More...
 
Gaudi::Details::PropertyBase & declareProperty (Gaudi::Property< T > &t)
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleKey &hndl, const std::string &doc, const SG::VarHandleKeyType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleBase &hndl, const std::string &doc, const SG::VarHandleType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleKeyArray &hndArr, const std::string &doc, const SG::VarHandleKeyArrayType &)
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, T &property, const std::string &doc, const SG::NotHandleType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, T &property, const std::string &doc="none")
 Declare a new Gaudi property. More...
 
void updateVHKA (Gaudi::Details::PropertyBase &)
 
MsgStream & msg () const
 
MsgStream & msg (const MSG::Level lvl) const
 
bool msgLvl (const MSG::Level lvl) const
 

Protected Member Functions

void renounceArray (SG::VarHandleKeyArray &handlesArray)
 remove all handles from I/O resolution More...
 
std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > renounce (T &h)
 
void extraDeps_update_handler (Gaudi::Details::PropertyBase &ExtraDeps)
 Add StoreName to extra input/output deps as needed. More...
 

Private Types

typedef ServiceHandle< StoreGateSvcStoreGateSvc_t
 

Private Member Functions

ReturnCode initializeHashDictionary ()
 
ReturnCode initializeDictionaryForData ()
 
ReturnCode initializePosCorrectionParameters ()
 
double PhiConv (double phi)
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
 specialization for handling Gaudi::Property<SG::VarHandleKey> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleKeyArrayType &)
 specialization for handling Gaudi::Property<SG::VarHandleKeyArray> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleType &)
 specialization for handling Gaudi::Property<SG::VarHandleBase> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &t, const SG::NotHandleType &)
 specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray> More...
 

Private Attributes

Gaudi::Property< bool > m_isMC { this, "MCFlag", true, "" }
 
CscRegion m_reg_dict [32] {}
 
int m_module_hashes [2][2][8] {}
 
TrigL2MuonSA::UtilTools m_util
 
StoreGateSvc_t m_evtStore
 Pointer to StoreGate (event store by default) More...
 
StoreGateSvc_t m_detStore
 Pointer to StoreGate (detector store by default) More...
 
std::vector< SG::VarHandleKeyArray * > m_vhka
 
bool m_varHandleArraysDeclared
 

Detailed Description

Definition at line 44 of file CscRegUtils.h.

Member Typedef Documentation

◆ StoreGateSvc_t

typedef ServiceHandle<StoreGateSvc> AthCommonDataStore< AthCommonMsg< AlgTool > >::StoreGateSvc_t
privateinherited

Definition at line 388 of file AthCommonDataStore.h.

Constructor & Destructor Documentation

◆ CscRegDict()

TrigL2MuonSA::CscRegDict::CscRegDict ( const std::string &  type,
const std::string &  name,
const IInterface *  parent 
)

Definition at line 16 of file CscRegUtils.cxx.

18  m_util()
19 {
20 }

Member Function Documentation

◆ actualAtanNormal()

double TrigL2MuonSA::CscRegDict::actualAtanNormal ( int  module) const
inline

Definition at line 77 of file CscRegUtils.h.

◆ declareGaudiProperty() [1/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleKeyArrayType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleKeyArray>

Definition at line 170 of file AthCommonDataStore.h.

172  {
173  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
174  hndl.value(),
175  hndl.documentation());
176 
177  }

◆ declareGaudiProperty() [2/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleKeyType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleKey>

Definition at line 156 of file AthCommonDataStore.h.

158  {
159  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
160  hndl.value(),
161  hndl.documentation());
162 
163  }

◆ declareGaudiProperty() [3/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleBase>

Definition at line 184 of file AthCommonDataStore.h.

186  {
187  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
188  hndl.value(),
189  hndl.documentation());
190  }

◆ declareGaudiProperty() [4/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  t,
const SG::NotHandleType  
)
inlineprivateinherited

specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray>

Definition at line 199 of file AthCommonDataStore.h.

200  {
201  return PBASE::declareProperty(t);
202  }

◆ declareProperty() [1/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleBase hndl,
const std::string &  doc,
const SG::VarHandleType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
hndlObject holding the property value.
docDocumentation string for the property.

This is the version for types that derive from SG::VarHandleBase. The property value object is put on the input and output lists as appropriate; then we forward to the base class.

Definition at line 245 of file AthCommonDataStore.h.

249  {
250  this->declare(hndl.vhKey());
251  hndl.vhKey().setOwner(this);
252 
253  return PBASE::declareProperty(name,hndl,doc);
254  }

◆ declareProperty() [2/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleKey hndl,
const std::string &  doc,
const SG::VarHandleKeyType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
hndlObject holding the property value.
docDocumentation string for the property.

This is the version for types that derive from SG::VarHandleKey. The property value object is put on the input and output lists as appropriate; then we forward to the base class.

Definition at line 221 of file AthCommonDataStore.h.

225  {
226  this->declare(hndl);
227  hndl.setOwner(this);
228 
229  return PBASE::declareProperty(name,hndl,doc);
230  }

◆ declareProperty() [3/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleKeyArray hndArr,
const std::string &  doc,
const SG::VarHandleKeyArrayType  
)
inlineinherited

Definition at line 259 of file AthCommonDataStore.h.

263  {
264 
265  // std::ostringstream ost;
266  // ost << Algorithm::name() << " VHKA declareProp: " << name
267  // << " size: " << hndArr.keys().size()
268  // << " mode: " << hndArr.mode()
269  // << " vhka size: " << m_vhka.size()
270  // << "\n";
271  // debug() << ost.str() << endmsg;
272 
273  hndArr.setOwner(this);
274  m_vhka.push_back(&hndArr);
275 
276  Gaudi::Details::PropertyBase* p = PBASE::declareProperty(name, hndArr, doc);
277  if (p != 0) {
278  p->declareUpdateHandler(&AthCommonDataStore<PBASE>::updateVHKA, this);
279  } else {
280  ATH_MSG_ERROR("unable to call declareProperty on VarHandleKeyArray "
281  << name);
282  }
283 
284  return p;
285 
286  }

◆ declareProperty() [4/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
T &  property,
const std::string &  doc,
const SG::NotHandleType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
propertyObject holding the property value.
docDocumentation string for the property.

This is the generic version, for types that do not derive from SG::VarHandleKey. It just forwards to the base class version of declareProperty.

Definition at line 333 of file AthCommonDataStore.h.

337  {
338  return PBASE::declareProperty(name, property, doc);
339  }

◆ declareProperty() [5/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
T &  property,
const std::string &  doc = "none" 
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
propertyObject holding the property value.
docDocumentation string for the property.

This dispatches to either the generic declareProperty or the one for VarHandle/Key/KeyArray.

Definition at line 352 of file AthCommonDataStore.h.

355  {
356  typedef typename SG::HandleClassifier<T>::type htype;
357  return declareProperty (name, property, doc, htype());
358  }

◆ declareProperty() [6/6]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( Gaudi::Property< T > &  t)
inlineinherited

Definition at line 145 of file AthCommonDataStore.h.

145  {
146  typedef typename SG::HandleClassifier<T>::type htype;
148  }

◆ detStore()

const ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< AlgTool > >::detStore ( ) const
inlineinherited

The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 95 of file AthCommonDataStore.h.

95 { return m_detStore; }

◆ displacement()

double TrigL2MuonSA::CscRegDict::displacement ( int  module) const
inline

Definition at line 99 of file CscRegUtils.h.

100 {
101  return (0<=module && module <32) ? m_reg_dict[module].Displacement : 0.;
102 }

◆ evtStore() [1/2]

ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< AlgTool > >::evtStore ( )
inlineinherited

The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 85 of file AthCommonDataStore.h.

85 { return m_evtStore; }

◆ evtStore() [2/2]

const ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< AlgTool > >::evtStore ( ) const
inlineinherited

The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 90 of file AthCommonDataStore.h.

90 { return m_evtStore; }

◆ extraDeps_update_handler()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::extraDeps_update_handler ( Gaudi::Details::PropertyBase &  ExtraDeps)
protectedinherited

Add StoreName to extra input/output deps as needed.

use the logic of the VarHandleKey to parse the DataObjID keys supplied via the ExtraInputs and ExtraOuputs Properties to add the StoreName if it's not explicitly given

◆ get_hash()

int TrigL2MuonSA::CscRegDict::get_hash ( int  stationname,
int  stationeta,
int  stationphi 
) const

Definition at line 125 of file CscRegUtils.cxx.

125  {
126 
127  int sname, seta, sphi;
128  if (stationname == 50 || stationname == 51) sname = stationname-50;
129  else { ATH_MSG_DEBUG( "stationname is out of [50,51]");
130  return 999;
131  }
132  if (stationeta == 1 || stationeta ==-1) seta = ((stationeta == 1)? 1:0);
133  else { ATH_MSG_DEBUG( "stationeta is not 1 nor -1" );
134  return 999;
135  }
136  if (stationphi >=1 || stationeta <=8) sphi = stationphi-1;
137  else { ATH_MSG_DEBUG( "stationeta is out of [1,8]" );
138  return 999;
139  }
140 
141  return m_module_hashes[sname][seta][sphi];
142 }

◆ idealAtanNormal()

double TrigL2MuonSA::CscRegDict::idealAtanNormal ( int  module) const
inline

Definition at line 76 of file CscRegUtils.h.

◆ initialize()

StatusCode TrigL2MuonSA::CscRegDict::initialize ( )
overridevirtual

Definition at line 23 of file CscRegUtils.cxx.

23  {
24 
25  int i=0;
26 
27  //small sector
28  const double SPwid = 0.32369;
29  const double Setamin = 1.97667;
30  const double Setamax = 2.76781;
31  const double SDisplace = (7441.+7518.)/2.;//7428.3;
32  const double SAtanNormal = 0.20223129856437;
33 
34  //Cside Small
35  for (int phi=0; phi<8; ++phi) {
36  m_reg_dict[i].etaMin=(-1)*Setamax;
37  m_reg_dict[i].etaMax=(-1)*Setamin;
38  m_reg_dict[i].phiMin=PhiConv( 0.125*M_PI+ phi*0.25*M_PI - 0.5*SPwid );
39  m_reg_dict[i].phiMax=PhiConv( 0.125*M_PI+ phi*0.25*M_PI + 0.5*SPwid );
40  m_reg_dict[i].phiCen= m_reg_dict[i].phiMod =PhiConv( 0.125*M_PI+ phi*0.25*M_PI );
41  m_reg_dict[i].Displacement=SDisplace;
45  ATH_MSG_DEBUG( "CscRegDict: hash= " << i << " StationName=" << stationName(i) << " StationEta=" << stationEta(i) << " StationPhi=" << stationPhi(i)
46  << " eta:[" << m_reg_dict[i].etaMin << "," << m_reg_dict[i].etaMax << "]"
47  << " phi:[" << m_reg_dict[i].phiMin << "," << m_reg_dict[i].phiMax << "]"
48  << " theta:[" << m_util.calc_theta(m_reg_dict[i].etaMin) << "," << m_util.calc_theta(m_reg_dict[i].etaMax) << "]");
49  ++i;
50  }
51  //Aside Small
52  for (int phi=0; phi<8; ++phi) {
53  m_reg_dict[i].etaMin=Setamin;
54  m_reg_dict[i].etaMax=Setamax;
55  m_reg_dict[i].phiMin=PhiConv( 0.125*M_PI+ phi*0.25*M_PI - 0.5*SPwid );
56  m_reg_dict[i].phiMax=PhiConv( 0.125*M_PI+ phi*0.25*M_PI + 0.5*SPwid );
57  m_reg_dict[i].phiCen= m_reg_dict[i].phiMod =PhiConv( 0.125*M_PI+ phi*0.25*M_PI );
58  m_reg_dict[i].Displacement=SDisplace;
62  ATH_MSG_DEBUG( "CscRegDict: hash= " << i << " StationName=" << stationName(i) << " StationEta=" << stationEta(i) << " StationPhi=" << stationPhi(i)
63  << " eta:[" << m_reg_dict[i].etaMin << "," << m_reg_dict[i].etaMax << "]"
64  << " phi:[" << m_reg_dict[i].phiMin << "," << m_reg_dict[i].phiMax << "]"
65  << " theta:[" << m_util.calc_theta(m_reg_dict[i].etaMin) << "," << m_util.calc_theta(m_reg_dict[i].etaMax) << "]");
66  ++i;
67  }
68 
69 
70  //large sector
71  const double LPwid = 0.514507;
72  const double Letamin = 2.01471;
73  const double Letamax = 2.75914;
74  const double LDisplace = (7800.+7880.)/2.;//7789.6;
75  const double LAtanNormal = 0.20223129856437;
76 
77  //Cside Large
78  for (int phi=0; phi<8; ++phi) {
79  m_reg_dict[i].etaMin=(-1)*Letamax;
80  m_reg_dict[i].etaMax=(-1)*Letamin;
81  m_reg_dict[i].phiMin=PhiConv( phi*0.25*M_PI - 0.5*LPwid );
82  m_reg_dict[i].phiMax=PhiConv( phi*0.25*M_PI + 0.5*LPwid );
83  m_reg_dict[i].phiCen= m_reg_dict[i].phiMod =PhiConv( phi*0.25*M_PI );
84  m_reg_dict[i].Displacement=LDisplace;
88  ATH_MSG_DEBUG( "CscRegDict: hash= " << i << " StationName=" << stationName(i) << " StationEta=" << stationEta(i) << " StationPhi=" << stationPhi(i)
89  << " eta:[" << m_reg_dict[i].etaMin << "," << m_reg_dict[i].etaMax << "]"
90  << " phi:[" << m_reg_dict[i].phiMin << "," << m_reg_dict[i].phiMax << "]"
91  << " theta:[" << m_util.calc_theta(m_reg_dict[i].etaMin) << "," << m_util.calc_theta(m_reg_dict[i].etaMax) << "]");
92  ++i;
93  }
94  //Aside Large
95  for (int phi=0; phi<8; ++phi) {
96  m_reg_dict[i].etaMin=Letamin;
97  m_reg_dict[i].etaMax=Letamax;
98  m_reg_dict[i].phiMin=PhiConv( phi*0.25*M_PI - 0.5*LPwid );
99  m_reg_dict[i].phiMax=PhiConv( phi*0.25*M_PI + 0.5*LPwid );
100  m_reg_dict[i].phiCen= m_reg_dict[i].phiMod =PhiConv( phi*0.25*M_PI );
101  m_reg_dict[i].Displacement=LDisplace;
105  ATH_MSG_DEBUG( "CscRegDict: hash= " << i << " StationName=" << stationName(i) << " StationEta=" << stationEta(i) << " StationPhi=" << stationPhi(i)
106  << " eta:[" << m_reg_dict[i].etaMin << "," << m_reg_dict[i].etaMax << "]"
107  << " phi:[" << m_reg_dict[i].phiMin << "," << m_reg_dict[i].phiMax << "]"
108  << " theta:[" << m_util.calc_theta(m_reg_dict[i].etaMin) << "," << m_util.calc_theta(m_reg_dict[i].etaMax) << "]");
109  ++i;
110  }
111  /*
112  ATH_MSG_DEBUG( "m_isMC=" << m_isMC );
113  if (!m_isMC){
114  initializePosCorrectionParameters();
115  initializeDictionaryForData();
116  }
117  */
119 
120 
121  return StatusCode::SUCCESS;
122 }

◆ initializeDictionaryForData()

ReturnCode TrigL2MuonSA::CscRegDict::initializeDictionaryForData ( )
private

Definition at line 267 of file CscRegUtils.cxx.

267  {
268 
269  return ReturnCode::SUCCESS;
270 }

◆ initializeHashDictionary()

ReturnCode TrigL2MuonSA::CscRegDict::initializeHashDictionary ( )
private

Definition at line 157 of file CscRegUtils.cxx.

157  {
158 
159  int hash = 0;
160  for (int sname=0; sname<2; ++sname) {
161  for (int seta=0; seta<2; ++seta) {
162  for (int sphi=0; sphi<8; ++sphi) {
163  m_module_hashes[sname][seta][sphi] = hash;
164  ATH_MSG_DEBUG( "module_hash:" << hash << " StationName:" << sname+50 << " StationEta:" << (seta ? 1 : -1) << " StationPhi:" << sphi+1 );
165  ++hash;
166  }
167  }
168  }
169  return 0;
170 }

◆ initializePosCorrectionParameters()

ReturnCode TrigL2MuonSA::CscRegDict::initializePosCorrectionParameters ( )
private

Definition at line 274 of file CscRegUtils.cxx.

274  {
275 
276 
277  return ReturnCode::SUCCESS;
278 }

◆ inputHandles()

virtual std::vector<Gaudi::DataHandle*> AthCommonDataStore< AthCommonMsg< AlgTool > >::inputHandles ( ) const
overridevirtualinherited

Return this algorithm's input handles.

We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.

◆ msg() [1/2]

MsgStream& AthCommonMsg< AlgTool >::msg ( ) const
inlineinherited

Definition at line 24 of file AthCommonMsg.h.

24  {
25  return this->msgStream();
26  }

◆ msg() [2/2]

MsgStream& AthCommonMsg< AlgTool >::msg ( const MSG::Level  lvl) const
inlineinherited

Definition at line 27 of file AthCommonMsg.h.

27  {
28  return this->msgStream(lvl);
29  }

◆ msgLvl()

bool AthCommonMsg< AlgTool >::msgLvl ( const MSG::Level  lvl) const
inlineinherited

Definition at line 30 of file AthCommonMsg.h.

30  {
31  return this->msgLevel(lvl);
32  }

◆ nomalVector()

Amg::Vector3D TrigL2MuonSA::CscRegDict::nomalVector ( int  module) const

Definition at line 174 of file CscRegUtils.cxx.

174  {
175 
176  double phi=m_reg_dict[module].phiCen;
178  Amg::Vector3D nomvec( std::sin(theta)*std::cos(phi), std::sin(theta)*std::sin(phi), std::cos(theta));
179 
180  return nomvec;
181 
182 }

◆ outputHandles()

virtual std::vector<Gaudi::DataHandle*> AthCommonDataStore< AthCommonMsg< AlgTool > >::outputHandles ( ) const
overridevirtualinherited

Return this algorithm's output handles.

We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.

◆ phiCen()

double TrigL2MuonSA::CscRegDict::phiCen ( int  module)
inline

Definition at line 68 of file CscRegUtils.h.

68 { return m_reg_dict[module].phiCen; }

◆ PhiConv()

double TrigL2MuonSA::CscRegDict::PhiConv ( double  phi)
private

Definition at line 147 of file CscRegUtils.cxx.

147  {
148 
149  if (phi>M_PI) {
150  phi -= 2*M_PI;
151  }
152 
153  return phi;
154 }

◆ phiMod()

double TrigL2MuonSA::CscRegDict::phiMod ( int  module) const
inline

Definition at line 69 of file CscRegUtils.h.

69 { return m_reg_dict[module].phiMod; }

◆ posCorrectionR()

double TrigL2MuonSA::CscRegDict::posCorrectionR ( int  module,
int  charge 
)

Definition at line 185 of file CscRegUtils.cxx.

185  {
186 
188  if (1==charge) return m_reg_dict[module].posCorrectionPlusR;
189 
190  return 0.0;
191 }

◆ posCorrectionZ()

double TrigL2MuonSA::CscRegDict::posCorrectionZ ( int  module,
int  charge 
)

Definition at line 194 of file CscRegUtils.cxx.

194  {
195 
196  double tan = this->idealAtanNormal(module);
197 
198  if (0==charge) return (-1)*tan*( m_reg_dict[module].posCorrectionMinusR );
199  if (1==charge) return (-1)*tan*( m_reg_dict[module].posCorrectionPlusR );
200 
201  return 0.0;
202 }

◆ renounce()

std::enable_if_t<std::is_void_v<std::result_of_t<decltype(&T::renounce)(T)> > && !std::is_base_of_v<SG::VarHandleKeyArray, T> && std::is_base_of_v<Gaudi::DataHandle, T>, void> AthCommonDataStore< AthCommonMsg< AlgTool > >::renounce ( T &  h)
inlineprotectedinherited

Definition at line 380 of file AthCommonDataStore.h.

381  {
382  h.renounce();
383  PBASE::renounce (h);
384  }

◆ renounceArray()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::renounceArray ( SG::VarHandleKeyArray handlesArray)
inlineprotectedinherited

remove all handles from I/O resolution

Definition at line 364 of file AthCommonDataStore.h.

364  {
365  handlesArray.renounce();
366  }

◆ stationEta()

int TrigL2MuonSA::CscRegDict::stationEta ( int  hash) const
inline

Definition at line 110 of file CscRegUtils.h.

111 {
112  if(hash<0 || hash>31) return 999;
113  else{
114  int secteta=(hash - hash%8)/8;// secteta: 0(Small Cside),1(Small Aside), 2(Large Cside), 3(Large Aside)
115  return (secteta%2) ? 1 : -1;
116  }
117 }

◆ stationName()

int TrigL2MuonSA::CscRegDict::stationName ( int  hash) const
inline

Definition at line 104 of file CscRegUtils.h.

105 {
106  if(hash<0 || hash>31) return 999;
107  else return (hash<16) ? 50 : 51;
108 }

◆ stationPhi()

int TrigL2MuonSA::CscRegDict::stationPhi ( int  hash) const
inline

Definition at line 119 of file CscRegUtils.h.

120 {
121  if(hash<0 || hash>31) return 999;
122  else return hash%8+1;
123 }

◆ sysInitialize()

virtual StatusCode AthCommonDataStore< AthCommonMsg< AlgTool > >::sysInitialize ( )
overridevirtualinherited

Perform system initialization for an algorithm.

We override this to declare all the elements of handle key arrays at the end of initialization. See comments on updateVHKA.

Reimplemented in DerivationFramework::CfAthAlgTool, AthCheckedComponent< AthAlgTool >, AthCheckedComponent<::AthAlgTool >, and asg::AsgMetadataTool.

◆ sysStart()

virtual StatusCode AthCommonDataStore< AthCommonMsg< AlgTool > >::sysStart ( )
overridevirtualinherited

Handle START transition.

We override this in order to make sure that conditions handle keys can cache a pointer to the conditions container.

◆ updateVHKA()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::updateVHKA ( Gaudi::Details::PropertyBase &  )
inlineinherited

Definition at line 308 of file AthCommonDataStore.h.

308  {
309  // debug() << "updateVHKA for property " << p.name() << " " << p.toString()
310  // << " size: " << m_vhka.size() << endmsg;
311  for (auto &a : m_vhka) {
312  std::vector<SG::VarHandleKey*> keys = a->keys();
313  for (auto k : keys) {
314  k->setOwner(this);
315  }
316  }
317  }

Member Data Documentation

◆ m_detStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< AlgTool > >::m_detStore
privateinherited

Pointer to StoreGate (detector store by default)

Definition at line 393 of file AthCommonDataStore.h.

◆ m_evtStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< AlgTool > >::m_evtStore
privateinherited

Pointer to StoreGate (event store by default)

Definition at line 390 of file AthCommonDataStore.h.

◆ m_isMC

Gaudi::Property< bool > TrigL2MuonSA::CscRegDict::m_isMC { this, "MCFlag", true, "" }
private

Definition at line 83 of file CscRegUtils.h.

◆ m_module_hashes

int TrigL2MuonSA::CscRegDict::m_module_hashes[2][2][8] {}
private

Definition at line 85 of file CscRegUtils.h.

◆ m_reg_dict

CscRegion TrigL2MuonSA::CscRegDict::m_reg_dict[32] {}
private

Definition at line 84 of file CscRegUtils.h.

◆ m_util

TrigL2MuonSA::UtilTools TrigL2MuonSA::CscRegDict::m_util
private

Definition at line 94 of file CscRegUtils.h.

◆ m_varHandleArraysDeclared

bool AthCommonDataStore< AthCommonMsg< AlgTool > >::m_varHandleArraysDeclared
privateinherited

Definition at line 399 of file AthCommonDataStore.h.

◆ m_vhka

std::vector<SG::VarHandleKeyArray*> AthCommonDataStore< AthCommonMsg< AlgTool > >::m_vhka
privateinherited

Definition at line 398 of file AthCommonDataStore.h.


The documentation for this class was generated from the following files:
TrigL2MuonSA::CscRegDict::m_module_hashes
int m_module_hashes[2][2][8]
Definition: CscRegUtils.h:85
TrigL2MuonSA::CscRegDict::PhiConv
double PhiConv(double phi)
Definition: CscRegUtils.cxx:147
TrigL2MuonSA::CscRegDict::idealAtanNormal
double idealAtanNormal(int module) const
Definition: CscRegUtils.h:76
AthCommonDataStore::declareProperty
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
Definition: AthCommonDataStore.h:145
M_PI
#define M_PI
Definition: ActiveFraction.h:11
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_evtStore
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
Definition: AthCommonDataStore.h:390
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_vhka
std::vector< SG::VarHandleKeyArray * > m_vhka
Definition: AthCommonDataStore.h:398
xAOD::etaMax
etaMax
Definition: HIEventShape_v2.cxx:46
TrigL2MuonSA::CscRegDict::CscRegion::posCorrectionPlusR
double posCorrectionPlusR
Definition: CscRegUtils.h:60
TrigL2MuonSA::CscRegDict::CscRegion::phiCen
double phiCen
Definition: CscRegUtils.h:55
read_hist_ntuple.t
t
Definition: read_hist_ntuple.py:5
drawFromPickle.cos
cos
Definition: drawFromPickle.py:36
TrigL2MuonSA::CscRegDict::initializeHashDictionary
ReturnCode initializeHashDictionary()
Definition: CscRegUtils.cxx:157
TrigL2MuonSA::CscRegDict::CscRegion::etaMin
double etaMin
Definition: CscRegUtils.h:51
TrigL2MuonSA::CscRegDict::CscRegion::actualAtanNormal
double actualAtanNormal
Definition: CscRegUtils.h:59
TrigL2MuonSA::CscRegDict::stationName
int stationName(int hash) const
Definition: CscRegUtils.h:104
SG::VarHandleKeyArray::setOwner
virtual void setOwner(IDataHandleHolder *o)=0
IDTPMcnv.htype
htype
Definition: IDTPMcnv.py:29
xAOD::phi
setEt phi
Definition: TrigEMCluster_v1.cxx:29
TrigL2MuonSA::CscRegDict::CscRegion::Displacement
double Displacement
Definition: CscRegUtils.h:57
python.PyAthena.module
module
Definition: PyAthena.py:131
TrigL2MuonSA::UtilTools::calc_theta
double calc_theta(double eta) const
Definition: CscRegUtils.h:30
python.utils.AtlRunQueryDQUtils.p
p
Definition: AtlRunQueryDQUtils.py:210
AthCommonDataStore
Definition: AthCommonDataStore.h:52
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
lumiFormat.i
int i
Definition: lumiFormat.py:85
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
test_pyathena.parent
parent
Definition: test_pyathena.py:15
drawFromPickle.tan
tan
Definition: drawFromPickle.py:36
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_detStore
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
Definition: AthCommonDataStore.h:393
jobOption.theta
theta
Definition: jobOption.ParticleGun_fwd_sequence.py:13
TrigL2MuonSA::CscRegDict::CscRegion::phiMod
double phiMod
Definition: CscRegUtils.h:56
AthAlgTool::AthAlgTool
AthAlgTool()
Default constructor:
SG::VarHandleKeyArray::renounce
virtual void renounce()=0
SG::HandleClassifier::type
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
Definition: HandleClassifier.h:54
merge_scale_histograms.doc
string doc
Definition: merge_scale_histograms.py:9
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:228
charge
double charge(const T &p)
Definition: AtlasPID.h:756
Amg::Vector3D
Eigen::Matrix< double, 3, 1 > Vector3D
Definition: GeoPrimitives.h:47
TrigL2MuonSA::CscRegDict::CscRegion::phiMin
double phiMin
Definition: CscRegUtils.h:53
TrigL2MuonSA::CscRegDict::CscRegion::phiMax
double phiMax
Definition: CscRegUtils.h:54
a
TList * a
Definition: liststreamerinfos.cxx:10
LArCellBinning.etaMin
etaMin
Definition: LArCellBinning.py:84
h
TrigL2MuonSA::CscRegDict::stationPhi
int stationPhi(int hash) const
Definition: CscRegUtils.h:119
CaloCondBlobAlgs_fillNoiseFromASCII.hash
dictionary hash
Definition: CaloCondBlobAlgs_fillNoiseFromASCII.py:109
python.CaloScaleNoiseConfig.type
type
Definition: CaloScaleNoiseConfig.py:78
TrigL2MuonSA::CscRegDict::CscRegion::etaMax
double etaMax
Definition: CscRegUtils.h:52
SG::VarHandleBase::vhKey
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
Definition: StoreGate/src/VarHandleBase.cxx:623
python.Bindings.keys
keys
Definition: Control/AthenaPython/python/Bindings.py:798
TrigL2MuonSA::CscRegDict::stationEta
int stationEta(int hash) const
Definition: CscRegUtils.h:110
drawFromPickle.sin
sin
Definition: drawFromPickle.py:36
TrigL2MuonSA::CscRegDict::m_util
TrigL2MuonSA::UtilTools m_util
Definition: CscRegUtils.h:94
TrigL2MuonSA::CscRegDict::m_reg_dict
CscRegion m_reg_dict[32]
Definition: CscRegUtils.h:84
TrigL2MuonSA::ReturnCode::SUCCESS
@ SUCCESS
Definition: CscRegUtils.h:134
TrigL2MuonSA::CscRegDict::CscRegion::idealAtanNormal
double idealAtanNormal
Definition: CscRegUtils.h:58
AthCommonDataStore::declareGaudiProperty
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition: AthCommonDataStore.h:156
fitman.k
k
Definition: fitman.py:528
TrigL2MuonSA::CscRegDict::CscRegion::posCorrectionMinusR
double posCorrectionMinusR
Definition: CscRegUtils.h:61