![]() |
ATLAS Offline Software
|
Implementation of the ICaloDepthTool interface.Given a Track direction, checks if it is in the Calorimeter acceptance and provides various radii to be compared/used in the extrapolation. More...
#include <CaloDepthTool.h>
Public Types | |
| enum class | DepthChoice { egparam , cscopt , cscopt2 , TBparam , entrance , middle , flat } |
Public Member Functions | |
| CaloDepthTool (const std::string &type, const std::string &name, const IInterface *parent) | |
| Standard constructor. | |
| virtual | ~CaloDepthTool () |
| Destructor. | |
| virtual StatusCode | initialize () override |
| Tool Initialize. | |
| virtual StatusCode | finalize () override |
| Tool Finalize. | |
| double | radius (const CaloCell_ID::SUBCALO subcalo, const int sampling_or_module, const bool barrel, const double eta, const double phi, const CaloDetDescrManager *caloDD) const |
| get radius | |
| double | radius (const CaloCell_ID::CaloSample sample, const double eta, const double phi, const CaloDetDescrManager *caloDD) const |
| get radius | |
| ServiceHandle< StoreGateSvc > & | evtStore () |
The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc. | |
| const ServiceHandle< StoreGateSvc > & | detStore () const |
The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc. | |
| virtual StatusCode | sysInitialize () override |
| Perform system initialization for an algorithm. | |
| virtual StatusCode | sysStart () override |
| Handle START transition. | |
| virtual std::vector< Gaudi::DataHandle * > | inputHandles () const override |
| Return this algorithm's input handles. | |
| virtual std::vector< Gaudi::DataHandle * > | outputHandles () const override |
| Return this algorithm's output handles. | |
| Gaudi::Details::PropertyBase & | declareProperty (Gaudi::Property< T, V, H > &t) |
| void | updateVHKA (Gaudi::Details::PropertyBase &) |
| MsgStream & | msg () const |
| bool | msgLvl (const MSG::Level lvl) const |
Static Public Member Functions | |
| static const InterfaceID & | interfaceID () |
| Query interface. | |
| static double | deta (const CaloCell_ID::SUBCALO subcalo, const int sampling_or_module, const bool barrel, const double eta, const CaloDetDescrManager *caloDD) |
| How far are you (in eta) from a given sample or - if you are in - how far are you from the edge ? | |
| static double | deta (const CaloCell_ID::CaloSample sample, const double eta, const CaloDetDescrManager *caloDD) |
| How far are you (in eta) from a given sample or - if you are in - how far are you from the edge ? | |
| static double | entrance (const CaloCell_ID::SUBCALO subcalo, const int sampling_or_module, const bool barrel, const double eta, const double phi, const CaloDetDescrManager *caloDD) |
| For a given direction, return the entrance of the given CaloCell_ID::CaloSample. | |
| static double | entrance (const CaloCell_ID::CaloSample sample, const double eta, const double phi, const CaloDetDescrManager *caloDD) |
| For a given direction, return the entrance of the given CaloCell_ID::CaloSample. | |
| static double | middle (const CaloCell_ID::SUBCALO subcalo, const int sampling_or_module, const bool barrel, const double eta, const double phi, const CaloDetDescrManager *caloDD) |
| For a given direction, return the middle of the given CaloCell_ID::CaloSample. | |
| static double | middle (const CaloCell_ID::CaloSample sample, const double eta, const double phi, const CaloDetDescrManager *caloDD) |
| For a given direction, return the middle of the given CaloCell_ID::CaloSample. | |
| static double | exit (const CaloCell_ID::SUBCALO subcalo, const int sampling_or_module, const bool barrel, const double eta, const double phi, const CaloDetDescrManager *caloDD) |
| For a given direction, return the exit of the given CaloCell_ID::CaloSample. | |
| static double | exit (const CaloCell_ID::CaloSample sample, const double eta, const double phi, const CaloDetDescrManager *caloDD) |
| For a given direction, return the exit of the given CaloCell_ID::CaloSample. | |
| static double | flat (const CaloCell_ID::SUBCALO subcalo, const int sampling_or_module, const bool barrel, const int side, const CaloDetDescrManager *caloDD) |
| If the direction is not specified, returns a "flat" aproximation (truely valid for strips only). | |
| static double | flat (const CaloCell_ID::CaloSample sample, const int side, const CaloDetDescrManager *caloDD) |
| If the direction is not specified, returns a "flat" aproximation (truely valid for strips only). | |
| static double | depth (const CaloCell_ID::SUBCALO subcalo, const int sampling_or_module, const bool barrel, const int side, const CaloDetDescrManager *caloDD) |
| If the direction is not specified, returns a "flat" aproximation (truely valid for strips only). | |
| static double | depth (const CaloCell_ID::CaloSample sample, const int side, const CaloDetDescrManager *caloDD) |
| If the direction is not specified, returns a "flat" aproximation (truely valid for strips only). | |
| static double | get_entrance_radius (CaloCell_ID::CaloSample sample, double eta, double phi, const CaloDetDescrManager *caloDD) |
| will look for the corresponding CaloDetDescrElement and return its entrance radius | |
| static double | get_entrance_z (CaloCell_ID::CaloSample sample, double eta, double phi, const CaloDetDescrManager *caloDD) |
| will look for the corresponding CaloDetDescrElement and return its entrance z | |
| static double | cscopt2_parametrized (const CaloCell_ID::CaloSample sample, const double eta, const double phi, const CaloDetDescrManager *caloDD) |
| Same as cscopt with the outermost EMB2 point excluded. | |
Protected Member Functions | |
| CaloDepthTool () | |
| CaloDepthTool (const CaloDepthTool &) | |
| CaloDepthTool & | operator= (const CaloDepthTool &) |
| void | renounceArray (SG::VarHandleKeyArray &handlesArray) |
| remove all handles from I/O resolution | |
| 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. | |
Private Types | |
| typedef ServiceHandle< StoreGateSvc > | StoreGateSvc_t |
Private Member Functions | |
| Gaudi::Details::PropertyBase & | declareGaudiProperty (Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyType &) |
| specialization for handling Gaudi::Property<SG::VarHandleKey> | |
Static Private Member Functions | |
| static double | egparametrized (const CaloCell_ID::SUBCALO subcalo, const int sampling_or_module, const bool barrel, const double eta, const double phi, const CaloDetDescrManager *caloDD) |
| Methods taken from the old egammaqdepth class : return the parametrised depth used in DC1 and DC2. | |
| static double | egparametrized (const CaloCell_ID::CaloSample sample, const double eta, const double phi, const CaloDetDescrManager *caloDD) |
| Methods taken from the old egammaqdepth class : return the parametrised depth used in DC1 and DC2. | |
| static double | TBparametrized (const CaloCell_ID::SUBCALO subcalo, const int sampling_or_module, const bool barrel, const double eta, const double phi, const CaloDetDescrManager *caloDD) |
| Parametrisation taken from the old egammaqdepth class, but adapted for TestBeam. | |
| static double | TBparametrized (const CaloCell_ID::CaloSample sample, const double eta, const double phi, const CaloDetDescrManager *caloDD) |
| Parametrisation taken from the old egammaqdepth class, but adapted for TestBeam. | |
| static double | cscopt_parametrized (const CaloCell_ID::CaloSample sample, const double eta, const double phi, const CaloDetDescrManager *caloDD) |
| Layers 1 and 2 depths set to give the best eta resolution. | |
| static double | get_middle_radius (CaloCell_ID::CaloSample sample, double eta, double phi, const CaloDetDescrManager *caloDD) |
| will look for the corresponding CaloDetDescrElement and return its middle radius | |
| static double | get_middle_z (CaloCell_ID::CaloSample sample, double eta, double phi, const CaloDetDescrManager *caloDD) |
| will look for the corresponding CaloDetDescrElement and return its middle z | |
| static double | get_exit_radius (CaloCell_ID::CaloSample sample, double eta, double phi, const CaloDetDescrManager *caloDD) |
| will look for the corresponding CaloDetDescrElement and return its middle radius | |
| static double | get_exit_z (CaloCell_ID::CaloSample sample, double eta, double phi, const CaloDetDescrManager *caloDD) |
| will look for the corresponding CaloDetDescrElement and return its middle z | |
Private Attributes | |
| Gaudi::Property< std::string > | m_depth_choice { this, "DepthChoice", "", "depth choice" } |
| Depth choice related code User passes a string but we convert to an enum at init to avoid string comparisons. | |
| DepthChoice | m_depthChoice = DepthChoice::entrance |
| const CaloCell_ID * | m_calo_id |
| ID Helper. | |
| CaloPhiRange | m_range |
| Phi range helper object. | |
| StoreGateSvc_t | m_evtStore |
| Pointer to StoreGate (event store by default) | |
| StoreGateSvc_t | m_detStore |
| Pointer to StoreGate (detector store by default) | |
| std::vector< SG::VarHandleKeyArray * > | m_vhka |
| bool | m_varHandleArraysDeclared |
Implementation of the ICaloDepthTool interface.Given a Track direction, checks if it is in the Calorimeter acceptance and provides various radii to be compared/used in the extrapolation.
This tool extends the functionality of the old egammaUtils/egammaqdepth class
In all the methods, radius stands for r in the (cylindric) barrel, for z in the (disk) endcap.
The generic method radius() uses the default choosen by joboption, and if the result is 0 because the eta/phi direction is outside the Sample acceptance, returns the egparametrised depth as backup solution.
Definition at line 45 of file CaloDepthTool.h.
|
privateinherited |
Definition at line 388 of file AthCommonDataStore.h.
|
strong |
| Enumerator | |
|---|---|
| egparam | |
| cscopt | |
| cscopt2 | |
| TBparam | |
| entrance | |
| middle | |
| flat | |
Definition at line 238 of file CaloDepthTool.h.
| CaloDepthTool::CaloDepthTool | ( | const std::string & | type, |
| const std::string & | name, | ||
| const IInterface * | parent ) |
Standard constructor.
Definition at line 49 of file CaloDepthTool.cxx.
|
virtualdefault |
Destructor.
|
protected |
|
protected |
|
static |
Same as cscopt with the outermost EMB2 point excluded.
This improves the fit. From CSC12 E=100 GeV photons.
Definition at line 323 of file CaloDepthTool.cxx.
|
staticprivate |
Layers 1 and 2 depths set to give the best eta resolution.
From CSC12 E=100 GeV photons.
Definition at line 253 of file CaloDepthTool.cxx.
|
inlineprivateinherited |
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition at line 156 of file AthCommonDataStore.h.
|
inlineinherited |
Definition at line 145 of file AthCommonDataStore.h.
|
static |
If the direction is not specified, returns a "flat" aproximation (truely valid for strips only).
Definition at line 618 of file CaloDepthTool.cxx.
|
static |
If the direction is not specified, returns a "flat" aproximation (truely valid for strips only).
Definition at line 605 of file CaloDepthTool.cxx.
|
static |
How far are you (in eta) from a given sample or - if you are in - how far are you from the edge ?
This method will return the distance to the closest edge. If you are outside the sample volume, it will always be a positive number. If you are inside the sample volume, the distance will be multiplied by -1 : i.e.always a negative number.
Definition at line 155 of file CaloDepthTool.cxx.
|
static |
How far are you (in eta) from a given sample or - if you are in - how far are you from the edge ?
This method will return the distance to the closest edge. If you are outside the sample volume, it will always be a positive number. If you are inside the sample volume, the distance will be multiplied by -1 : i.e.always a negative number.
Definition at line 142 of file CaloDepthTool.cxx.
|
inlineinherited |
The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.
Definition at line 95 of file AthCommonDataStore.h.
|
staticprivate |
Methods taken from the old egammaqdepth class : return the parametrised depth used in DC1 and DC2.
Only LAREM is foreseen
Definition at line 183 of file CaloDepthTool.cxx.
|
staticprivate |
Methods taken from the old egammaqdepth class : return the parametrised depth used in DC1 and DC2.
Only LAREM is foreseen
Definition at line 169 of file CaloDepthTool.cxx.
|
static |
For a given direction, return the entrance of the given CaloCell_ID::CaloSample.
If the direction does not cross any CaloCell, the returned bool will be set to False.
Definition at line 447 of file CaloDepthTool.cxx.
|
static |
For a given direction, return the entrance of the given CaloCell_ID::CaloSample.
If the direction does not cross any CaloCell, the returned bool will be set to False.
Definition at line 433 of file CaloDepthTool.cxx.
|
inlineinherited |
The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.
Definition at line 85 of file AthCommonDataStore.h.
|
static |
For a given direction, return the exit of the given CaloCell_ID::CaloSample.
If the direction does not cross any CaloCell, the returned bool will be set to False.
Definition at line 518 of file CaloDepthTool.cxx.
|
static |
For a given direction, return the exit of the given CaloCell_ID::CaloSample.
If the direction does not cross any CaloCell, the returned bool will be set to False.
Definition at line 504 of file CaloDepthTool.cxx.
|
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
|
overridevirtual |
Tool Finalize.
Definition at line 81 of file CaloDepthTool.cxx.
|
static |
If the direction is not specified, returns a "flat" aproximation (truely valid for strips only).
Definition at line 552 of file CaloDepthTool.cxx.
|
static |
If the direction is not specified, returns a "flat" aproximation (truely valid for strips only).
Definition at line 539 of file CaloDepthTool.cxx.
|
static |
will look for the corresponding CaloDetDescrElement and return its entrance radius
Definition at line 660 of file CaloDepthTool.cxx.
|
static |
will look for the corresponding CaloDetDescrElement and return its entrance z
Definition at line 677 of file CaloDepthTool.cxx.
|
staticprivate |
will look for the corresponding CaloDetDescrElement and return its middle radius
Definition at line 722 of file CaloDepthTool.cxx.
|
staticprivate |
will look for the corresponding CaloDetDescrElement and return its middle z
Definition at line 740 of file CaloDepthTool.cxx.
|
staticprivate |
will look for the corresponding CaloDetDescrElement and return its middle radius
Definition at line 694 of file CaloDepthTool.cxx.
|
staticprivate |
will look for the corresponding CaloDetDescrElement and return its middle z
Definition at line 708 of file CaloDepthTool.cxx.
|
overridevirtual |
Tool Initialize.
Definition at line 61 of file CaloDepthTool.cxx.
|
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.
|
static |
Query interface.
Definition at line 44 of file CaloDepthTool.cxx.
|
static |
For a given direction, return the middle of the given CaloCell_ID::CaloSample.
If the direction does not cross any CaloCell, the returned bool will be set to False.
Definition at line 483 of file CaloDepthTool.cxx.
|
static |
For a given direction, return the middle of the given CaloCell_ID::CaloSample.
If the direction does not cross any CaloCell, the returned bool will be set to False.
Definition at line 469 of file CaloDepthTool.cxx.
|
inlineinherited |
Definition at line 24 of file AthCommonMsg.h.
|
inlineinherited |
Definition at line 30 of file AthCommonMsg.h.
|
protected |
|
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.
| double CaloDepthTool::radius | ( | const CaloCell_ID::CaloSample | sample, |
| const double | eta, | ||
| const double | phi, | ||
| const CaloDetDescrManager * | caloDD ) const |
get radius
Generic method to be used in client code : the default choosen by joboption, and if the result is 0 because the eta/phi direction is outside the Sample acceptance, returns the egparametrised depth as backup solution.
Definition at line 103 of file CaloDepthTool.cxx.
| double CaloDepthTool::radius | ( | const CaloCell_ID::SUBCALO | subcalo, |
| const int | sampling_or_module, | ||
| const bool | barrel, | ||
| const double | eta, | ||
| const double | phi, | ||
| const CaloDetDescrManager * | caloDD ) const |
get radius
Generic method to be used in client code : the default choosen by joboption, and if the result is 0 because the eta/phi direction is outside the Sample acceptance, returns the egparametrised depth as backup solution.
Definition at line 89 of file CaloDepthTool.cxx.
|
inlineprotectedinherited |
Definition at line 380 of file AthCommonDataStore.h.
|
inlineprotectedinherited |
remove all handles from I/O resolution
Definition at line 364 of file AthCommonDataStore.h.
|
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 asg::AsgMetadataTool, AthCheckedComponent< AthAlgTool >, AthCheckedComponent<::AthAlgTool >, and DerivationFramework::CfAthAlgTool.
|
overridevirtualinherited |
Handle START transition.
We override this in order to make sure that conditions handle keys can cache a pointer to the conditions container.
|
staticprivate |
Parametrisation taken from the old egammaqdepth class, but adapted for TestBeam.
Only LAREM is foreseen
Definition at line 403 of file CaloDepthTool.cxx.
|
staticprivate |
Parametrisation taken from the old egammaqdepth class, but adapted for TestBeam.
Only LAREM is foreseen
Definition at line 389 of file CaloDepthTool.cxx.
|
inlineinherited |
Definition at line 308 of file AthCommonDataStore.h.
|
private |
ID Helper.
Definition at line 341 of file CaloDepthTool.h.
|
private |
Depth choice related code User passes a string but we convert to an enum at init to avoid string comparisons.
Definition at line 336 of file CaloDepthTool.h.
|
private |
Definition at line 338 of file CaloDepthTool.h.
|
privateinherited |
Pointer to StoreGate (detector store by default)
Definition at line 393 of file AthCommonDataStore.h.
|
privateinherited |
Pointer to StoreGate (event store by default)
Definition at line 390 of file AthCommonDataStore.h.
|
private |
Phi range helper object.
Definition at line 344 of file CaloDepthTool.h.
|
privateinherited |
Definition at line 399 of file AthCommonDataStore.h.
|
privateinherited |
Definition at line 398 of file AthCommonDataStore.h.