|
ATLAS Offline Software
|
#include <GetDetectorPositions.h>
|
| GetDetectorPositions (const std::string &name, ISvcLocator *pSvcLocator) |
| Authors: John Alison johnd.nosp@m.a@he.nosp@m.p.upe.nosp@m.nn.e.nosp@m.du More...
|
|
StatusCode | initialize () |
| initialize More...
|
|
StatusCode | execute () |
| execute More...
|
|
StatusCode | finalize () |
| Finalize. More...
|
|
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 |
|
Definition at line 34 of file GetDetectorPositions.h.
◆ StoreGateSvc_t
◆ GetDetectorPositions()
GetDetectorPositions::GetDetectorPositions |
( |
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 GetDetectorPositions::execute |
( |
| ) |
|
execute
run only for one event
Definition at line 99 of file GetDetectorPositions.cxx.
108 return StatusCode::SUCCESS;
110 std::cout <<
"========================================================================================" <<std::endl;
111 std::cout <<
"==================== Getting the Inner Detector Positions ==============================" <<std::endl;
112 std::cout <<
"========================================================================================" <<std::endl;
124 return StatusCode::SUCCESS;
◆ 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 GetDetectorPositions::finalize |
( |
| ) |
|
◆ initialize()
StatusCode GetDetectorPositions::initialize |
( |
| ) |
|
initialize
Retrive TRT info
Retrive SCT info
Retrive Pixel info
Output text File
Definition at line 59 of file GetDetectorPositions.cxx.
66 return StatusCode::FAILURE;
72 return StatusCode::FAILURE;
79 return StatusCode::FAILURE;
87 return StatusCode::FAILURE;
95 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.
◆ 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()
◆ writeDetailedTRTPositions()
void GetDetectorPositions::writeDetailedTRTPositions |
( |
bool |
doDoubleSampling = false | ) |
|
|
private |
Writing the Detailed (all straws) TRT Positions.
Definition at line 267 of file GetDetectorPositions.cxx.
273 for (; trtStrawIt != trtStrawItE; ++trtStrawIt) {
◆ writePixelPositions()
void GetDetectorPositions::writePixelPositions |
( |
| ) |
|
|
private |
Functions to get the data.
Writing the Pixel Positions.
Definition at line 138 of file GetDetectorPositions.cxx.
143 if (not pixelDetEleHandle.isValid() or elements==
nullptr) {
160 float pix_x = p3d.x();
161 float pix_y = p3d.y();
162 float pix_z = p3d.z();
165 << pix_barrel_ec <<
" "
166 << pix_layer_disk <<
" "
167 << pix_phi_module <<
" "
168 << pix_eta_module <<
" "
◆ writeSCTPositions()
void GetDetectorPositions::writeSCTPositions |
( |
| ) |
|
|
private |
Writing the SCT Positions.
Definition at line 182 of file GetDetectorPositions.cxx.
187 if (not sctDetEleHandle.isValid() or elements==
nullptr) {
203 float sct_x = p3d.x();
204 float sct_y = p3d.y();
205 float sct_z = p3d.z();
208 << sct_barrel_ec <<
" "
209 << sct_layer_disk <<
" "
210 << sct_phi_module <<
" "
211 << sct_eta_module <<
" "
◆ writeSimpleTRTPositions()
void GetDetectorPositions::writeSimpleTRTPositions |
( |
| ) |
|
|
private |
Writing the Simple (not all straws) TRT Positions.
Definition at line 251 of file GetDetectorPositions.cxx.
258 for(; trtStrawLayIt != trtStrawLayItE; ++trtStrawLayIt ) {
◆ writeTRTPositions() [1/2]
void GetDetectorPositions::writeTRTPositions |
( |
| ) |
|
|
private |
◆ writeTRTPositions() [2/2]
Write the TRT Positions.
Definition at line 293 of file GetDetectorPositions.cxx.
304 float trt_x = p3d.x();
305 float trt_y = p3d.y();
306 float trt_z = p3d.z();
309 << trt_barrel_ec <<
" "
310 << trt_layer_or_wheel <<
" "
311 << trt_phi_module <<
" "
312 << trt_straw_layer <<
" ";
◆ writeTwoTRTPositions()
void GetDetectorPositions::writeTwoTRTPositions |
( |
Identifier const & |
trtId | ) |
|
|
private |
Write the TRT Positions, sampling each straw twice Allows the wire-by-wire alignment to be debugged.
Definition at line 331 of file GetDetectorPositions.cxx.
343 float first_X = firstSampling.x();
344 float first_Y = firstSampling.y();
345 float first_Z = firstSampling.z();
349 float second_X = secondSampling.x();
350 float second_Y = secondSampling.y();
351 float second_Z = secondSampling.z();
354 << trt_barrel_ec <<
" "
355 << trt_layer_or_wheel <<
" "
356 << trt_phi_module <<
" "
357 << trt_straw_layer <<
" "
365 << trt_barrel_ec <<
" "
366 << trt_layer_or_wheel <<
" "
367 << trt_phi_module <<
" "
368 << trt_straw_layer <<
" "
◆ DetailLevel
GetDetectorPositions.DetailLevel |
◆ job
GetDetectorPositions.job = AlgSequence() |
◆ m_detailLevel
unsigned int GetDetectorPositions::m_detailLevel |
|
private |
◆ m_detStore
◆ m_doTRT
bool GetDetectorPositions::m_doTRT |
|
private |
◆ m_eventCount
int GetDetectorPositions::m_eventCount {-1} |
|
private |
◆ m_evtStore
◆ m_extendedExtraObjects
DataObjIDColl AthAlgorithm::m_extendedExtraObjects |
|
privateinherited |
◆ m_outputFile
std::ofstream GetDetectorPositions::m_outputFile |
|
private |
◆ m_outputFileName
std::string GetDetectorPositions::m_outputFileName |
|
private |
◆ m_pixelDetEleCollKey
◆ m_PixelHelper
◆ m_SCTDetEleCollKey
◆ m_SCTHelper
◆ m_TRTDetectorManager
◆ m_TRTHelper
◆ m_varHandleArraysDeclared
◆ m_vhka
◆ name
GetDetectorPositions.name |
◆ OutputLevel
GetDetectorPositions.OutputLevel |
The documentation for this class was generated from the following files:
def retrieve(aClass, aKey=None)
const PixelID * m_PixelHelper
Tools.
void writeSimpleTRTPositions()
Writing the Simple (not all straws) TRT Positions.
void writePixelPositions()
Functions to get the data.
int barrel_ec(const Identifier &id) const
Values of different levels (failure returns 0)
SG::ReadCondHandleKey< InDetDD::SiDetectorElementCollection > m_pixelDetEleCollKey
Pixel Data.
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
void writeSCTPositions()
Writing the SCT Positions.
std::vector< SG::VarHandleKeyArray * > m_vhka
void writeTRTPositions()
Writing the TRT positions (depends on the level of detail)
bool msgLvl(const MSG::Level lvl) const
void writeTwoTRTPositions(Identifier const &trtId)
Write the TRT Positions, sampling each straw twice Allows the wire-by-wire alignment to be debugged.
int barrel_ec(const Identifier &id) const
Values of different levels (failure returns 0)
int phi_module(const Identifier &id) const
void writeDetailedTRTPositions(bool doDoubleSampling=false)
Writing the Detailed (all straws) TRT Positions.
std::string m_outputFileName
const_id_iterator straw_layer_end(void) const
const ServiceHandle< StoreGateSvc > & detStore() const
The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.
virtual void setOwner(IDataHandleHolder *o)=0
int straw(const Identifier &id) const
virtual StatusCode sysInitialize() override
Override sysInitialize.
int phi_index_max(const Identifier &id) const
virtual std::vector< Gaudi::DataHandle * > outputHandles() const override
Return this algorithm's output handles.
int eta_index_max(const Identifier &id) const
::StatusCode StatusCode
StatusCode definition for legacy code.
SG::ReadCondHandleKey< InDetDD::SiDetectorElementCollection > m_SCTDetEleCollKey
SCT Data.
const SCT_ID * m_SCTHelper
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
int barrel_ec(const Identifier &id) const
Values of different levels (failure returns 0)
int straw_layer(const Identifier &id) const
int layer_or_wheel(const Identifier &id) const
virtual void renounce()=0
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
int nStrips(const MuonGM::TgcReadoutElement &readoutEle, int layer)
int layer_disk(const Identifier &id) const
int eta_module(const Identifier &id) const
const TRT_BaseElement * getElement(Identifier id) const
Access Elements Generically---------------------------------------------—.
int layer_disk(const Identifier &id) const
StatusCode initialize(bool used=true)
const InDetDD::TRT_DetectorManager * m_TRTDetectorManager
Eigen::Matrix< double, 3, 1 > Vector3D
const_expanded_id_iterator straw_end(void) const
int phi_module(const Identifier &id) const
DataObjIDColl m_extendedExtraObjects
const Amg::Transform3D & strawTransform(unsigned int straw) const
Straw transform - fast access in array, in Tracking frame: Amg.
#define ATH_MSG_WARNING(x)
int eta_module(const Identifier &id) const
int strip_max(const Identifier &id) const
virtual const Amg::Vector3D & center() const override final
Element Surface: center of a straw layer.
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
const TRT_ID * m_TRTHelper
AthAlgorithm()
Default constructor:
const_expanded_id_iterator straw_begin(void) const
For straw ids, only expanded id iterators are available.
const_id_iterator straw_layer_begin(void) const
Iterators over full set of straw_layer ids. Straw_layer ids are sorted.
Identifier wafer_id(int barrel_ec, int layer_disk, int phi_module, int eta_module, int side) const
For a single side of module.
This is a "hash" representation of an Identifier. This encodes a 32 bit index which can be used to lo...
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>
std::ofstream m_outputFile
Identifier straw_id(int barrel_ec, int phi_module, int layer_or_wheel, int straw_layer, int straw) const
Three ways of getting id for a single straw:
unsigned int m_detailLevel
Name of the Output file.