|
ATLAS Offline Software
|
#include <PrintSiElements.h>
|
| PrintSiElements (const std::string &name, ISvcLocator *pSvcLocator) |
|
virtual StatusCode | initialize () override |
|
virtual StatusCode | execute () override |
|
virtual StatusCode | finalize () override |
|
StatusCode | printElements (const std::string &managerName) |
|
std::string | printTransform (const Amg::Transform3D &trans) const |
|
void | extractAlphaBetaGamma (const Amg::Transform3D &trans, double &alpha, double &beta, double &gamma) const |
|
virtual StatusCode | sysInitialize () override |
| Override sysInitialize. More...
|
|
virtual const DataObjIDColl & | extraOutputDeps () const override |
| Return the list of extra output dependencies. More...
|
|
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 | 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 |
|
|
std::ofstream | m_fileout |
|
bool | m_firstEvent |
|
bool | m_modulesOnly |
|
bool | m_expandId |
|
bool | m_nominal |
|
bool | m_aligned |
|
bool | m_fullRotationMatrix |
|
std::string | m_outputFileName |
|
ServiceHandle< IGeoModelSvc > | m_geoModelSvc {this, "GeoModelSvc", "GeoModelSvc"} |
|
SG::ReadCondHandleKey< InDetDD::SiDetectorElementCollection > | m_pixelDetEleCollKey {this, "PixelDetEleCollKey", "PixelDetectorElementCollection", "Key of SiDetectorElementCollection for Pixel"} |
|
SG::ReadCondHandleKey< InDetDD::SiDetectorElementCollection > | m_SCTDetEleCollKey {this, "SCTDetEleCollKey", "SCT_DetectorElementCollection", "Key of SiDetectorElementCollection for SCT"} |
|
SG::ReadCondHandleKey< InDetDD::SiDetectorElementCollection > | m_ITkPixelDetEleCollKey {this, "ITkPixelDetEleCollKey", "ITkPixelDetectorElementCollection", "Key of SiDetectorElementCollection for ITkPixel"} |
|
SG::ReadCondHandleKey< InDetDD::SiDetectorElementCollection > | m_ITkStripDetEleCollKey {this, "ITkStripDetEleCollKey", "ITkStripDetectorElementCollection", "Key of SiDetectorElementCollection for ITkStrip"} |
|
std::vector< std::string > | m_detManagerNames |
|
DataObjIDColl | m_extendedExtraObjects |
|
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 |
|
Definition at line 21 of file PrintSiElements.h.
◆ StoreGateSvc_t
◆ PrintSiElements()
PrintSiElements::PrintSiElements |
( |
const std::string & |
name, |
|
|
ISvcLocator * |
pSvcLocator |
|
) |
| |
◆ declareGaudiProperty() [1/4]
specialization for handling Gaudi::Property<SG::VarHandleKeyArray>
Definition at line 170 of file AthCommonDataStore.h.
175 hndl.documentation());
◆ declareGaudiProperty() [2/4]
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition at line 156 of file AthCommonDataStore.h.
161 hndl.documentation());
◆ declareGaudiProperty() [3/4]
specialization for handling Gaudi::Property<SG::VarHandleBase>
Definition at line 184 of file AthCommonDataStore.h.
189 hndl.documentation());
◆ declareGaudiProperty() [4/4]
◆ declareProperty() [1/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
hndl | Object holding the property value. |
doc | Documentation 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.
250 this->declare(hndl.
vhKey());
251 hndl.
vhKey().setOwner(
this);
253 return PBASE::declareProperty(
name,hndl,
doc);
◆ declareProperty() [2/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
hndl | Object holding the property value. |
doc | Documentation 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.
229 return PBASE::declareProperty(
name,hndl,
doc);
◆ declareProperty() [3/6]
◆ declareProperty() [4/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
property | Object holding the property value. |
doc | Documentation 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.
338 return PBASE::declareProperty(
name, property,
doc);
◆ declareProperty() [5/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
property | Object holding the property value. |
doc | Documentation 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.
◆ declareProperty() [6/6]
◆ detStore()
◆ evtStore() [1/2]
◆ evtStore() [2/2]
◆ execute()
StatusCode PrintSiElements::execute |
( |
| ) |
|
|
overridevirtual |
◆ extractAlphaBetaGamma()
void PrintSiElements::extractAlphaBetaGamma |
( |
const Amg::Transform3D & |
trans, |
|
|
double & |
alpha, |
|
|
double & |
beta, |
|
|
double & |
gamma |
|
) |
| const |
Definition at line 219 of file PrintSiElements.cxx.
222 double siny = trans(0,2);
227 if ((trans(1,2) == 0) && (trans(2,2) == 0)) {
231 alpha = atan2(trans(1,1),trans(2,1));
233 alpha = atan2(-trans(1,2),trans(2,2));
234 gamma = atan2(-trans(0,1),trans(0,0));
235 if (alpha == 0) alpha = 0;
◆ extraDeps_update_handler()
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
◆ extraOutputDeps()
const DataObjIDColl & AthAlgorithm::extraOutputDeps |
( |
| ) |
const |
|
overridevirtualinherited |
Return the list of extra output dependencies.
This list is extended to include symlinks implied by inheritance relations.
Definition at line 50 of file AthAlgorithm.cxx.
57 return Algorithm::extraOutputDeps();
◆ finalize()
StatusCode PrintSiElements::finalize |
( |
| ) |
|
|
overridevirtual |
◆ initialize()
StatusCode PrintSiElements::initialize |
( |
| ) |
|
|
overridevirtual |
Definition at line 49 of file PrintSiElements.cxx.
56 return StatusCode::FAILURE;
69 return StatusCode::SUCCESS;
◆ inputHandles()
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]
◆ msg() [2/2]
◆ msgLvl()
◆ outputHandles()
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.
◆ printElements()
StatusCode PrintSiElements::printElements |
( |
const std::string & |
managerName | ) |
|
Definition at line 74 of file PrintSiElements.cxx.
76 if (managerName==
"Pixel") {
78 elements = *pixelDetEleHandle;
79 if (not pixelDetEleHandle.isValid() or elements==
nullptr) {
81 return StatusCode::RECOVERABLE;
83 }
else if (managerName==
"SCT") {
85 elements = *sctDetEleHandle;
86 if (not sctDetEleHandle.isValid() or elements==
nullptr) {
88 return StatusCode::RECOVERABLE;
91 else if (managerName==
"ITkPixel") {
93 elements = *pixelDetEleHandle;
94 if (not pixelDetEleHandle.isValid() or elements==
nullptr) {
96 return StatusCode::RECOVERABLE;
99 else if (managerName==
"ITkStrip") {
101 elements = *stripDetEleHandle;
102 if (not stripDetEleHandle.isValid() or elements==
nullptr) {
104 return StatusCode::RECOVERABLE;
107 if (elements==
nullptr) {
108 ATH_MSG_FATAL(
"SiDetectorElementCollection elements is nullptr");
109 return StatusCode::FAILURE;
123 if (element->isPixel()) {
124 const PixelID * pixIdHelper =
dynamic_cast<const PixelID *
>(element->getIdHelper());
134 const SCT_ID * sctIdHelper =
dynamic_cast<const SCT_ID *
>(element->getIdHelper());
151 trans = element->moduleTransform();
152 defTrans = element->defModuleTransform();
156 trans = element->transform();
157 defTrans = element->defTransform();
160 std::ostringstream idstr;
162 idstr << 2 <<
" " <<
det <<
" "
163 <<
bec <<
" " << layer_disk <<
" "
164 << phi_module <<
" " << eta_module <<
" "
165 <<
side <<
" " <<
id <<
" ";
167 idstr << element->getIdHelper()->show_to_string(
id) <<
" ";
177 return StatusCode::SUCCESS;
◆ printTransform()
Definition at line 198 of file PrintSiElements.cxx.
200 std::ostringstream ostr;
201 ostr <<
xyz.x() <<
" " <<
xyz.y() <<
" " <<
xyz.z() <<
" ";
203 for (
int i=0;
i < 3;
i++) {
204 for (
int j=0; j < 3; j++) {
205 ostr << trans(
i,j) <<
" ";
211 ostr << alpha <<
" " <<
beta <<
" " <<
gamma;
◆ renounce()
◆ renounceArray()
◆ sysInitialize()
StatusCode AthAlgorithm::sysInitialize |
( |
| ) |
|
|
overridevirtualinherited |
◆ sysStart()
Handle START transition.
We override this in order to make sure that conditions handle keys can cache a pointer to the conditions container.
◆ updateVHKA()
◆ m_aligned
bool PrintSiElements::m_aligned |
|
private |
◆ m_detManagerNames
std::vector<std::string> PrintSiElements::m_detManagerNames |
|
private |
◆ m_detStore
◆ m_evtStore
◆ m_expandId
bool PrintSiElements::m_expandId |
|
private |
◆ m_extendedExtraObjects
DataObjIDColl AthAlgorithm::m_extendedExtraObjects |
|
privateinherited |
◆ m_fileout
std::ofstream PrintSiElements::m_fileout |
|
private |
◆ m_firstEvent
bool PrintSiElements::m_firstEvent |
|
private |
◆ m_fullRotationMatrix
bool PrintSiElements::m_fullRotationMatrix |
|
private |
◆ m_geoModelSvc
◆ m_ITkPixelDetEleCollKey
◆ m_ITkStripDetEleCollKey
◆ m_modulesOnly
bool PrintSiElements::m_modulesOnly |
|
private |
◆ m_nominal
bool PrintSiElements::m_nominal |
|
private |
◆ m_outputFileName
std::string PrintSiElements::m_outputFileName |
|
private |
◆ m_pixelDetEleCollKey
◆ m_SCTDetEleCollKey
◆ m_varHandleArraysDeclared
◆ m_vhka
The documentation for this class was generated from the following files:
SG::ReadCondHandleKey< InDetDD::SiDetectorElementCollection > m_ITkStripDetEleCollKey
std::string find(const std::string &s)
return a remapped string
StatusCode printElements(const std::string &managerName)
int barrel_ec(const Identifier &id) const
Values of different levels (failure returns 0)
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
std::vector< SG::VarHandleKeyArray * > m_vhka
int barrel_ec(const Identifier &id) const
Values of different levels (failure returns 0)
int phi_module(const Identifier &id) const
std::string m_outputFileName
virtual void setOwner(IDataHandleHolder *o)=0
void extractAlphaBetaGamma(const Amg::Transform3D &trans, double &alpha, double &beta, double &gamma) const
virtual StatusCode sysInitialize() override
Override sysInitialize.
virtual std::vector< Gaudi::DataHandle * > outputHandles() const override
Return this algorithm's output handles.
SG::ReadCondHandleKey< InDetDD::SiDetectorElementCollection > m_pixelDetEleCollKey
SG::ReadCondHandleKey< InDetDD::SiDetectorElementCollection > m_ITkPixelDetEleCollKey
::StatusCode StatusCode
StatusCode definition for legacy code.
Eigen::Affine3d Transform3D
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
virtual void renounce()=0
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
int layer_disk(const Identifier &id) const
int eta_module(const Identifier &id) const
int layer_disk(const Identifier &id) const
StatusCode initialize(bool used=true)
Eigen::Matrix< double, 3, 1 > Vector3D
DataObjIDColl m_extendedExtraObjects
std::string printTransform(const Amg::Transform3D &trans) const
#define ATH_MSG_WARNING(x)
std::vector< std::string > m_detManagerNames
int eta_module(const Identifier &id) const
ServiceHandle< IGeoModelSvc > m_geoModelSvc
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
int side(const Identifier &id) const
AthAlgorithm()
Default constructor:
bool m_fullRotationMatrix
SG::ReadCondHandleKey< InDetDD::SiDetectorElementCollection > m_SCTDetEleCollKey
int phi_module(const Identifier &id) const
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>