![]() |
ATLAS Offline Software
|
In the initialize() method, the PileUpMerge and StoreGate services are initialized, and a pointer to an instance of the class MuonDetectorManager is retrieved from the detector store and used to obtain a MdtIdHelper.The MdtDigitContainer is initialized and the simulation identifier helper retrieved, together with the pointer to the digitization tool. More...
#include <MdtDigitizationTool.h>
Classes | |
| struct | GeoCorOut |
Public Member Functions | |
| MdtDigitizationTool (const std::string &type, const std::string &name, const IInterface *pIID) | |
| virtual | ~MdtDigitizationTool ()=default |
| virtual StatusCode | initialize () override final |
| Initialize. | |
| StatusCode | prepareEvent (const EventContext &ctx, const unsigned int) override final |
| When being run from PileUpToolsAlgs, this method is called at the start of the subevts loop. | |
| virtual StatusCode | processBunchXing (int bunchXing, SubEventIterator bSubEvents, SubEventIterator eSubEvents) override final |
| When being run from PileUpToolsAlgs, this method is called for each active bunch-crossing to process current SubEvents bunchXing is in ns. | |
| StatusCode | mergeEvent (const EventContext &ctx) override final |
| When being run from PileUpToolsAlgs, this method is called at the end of the subevts loop. | |
| virtual StatusCode | processAllSubEvents (const EventContext &ctx) override final |
| alternative interface which uses the PileUpMergeSvc to obtain all the required SubEvents. | |
Protected Attributes | |
| ServiceHandle< PileUpMergeSvc > | m_mergeSvc {this, "PileUpMergeSvc", "PileUpMergeSvc", ""} |
| BooleanProperty | m_onlyUseContainerName |
| SG::ReadHandleKey< MDTSimHitCollection > | m_hitsContainerKey {this, "InputObjectName", "MDT_Hits", ""} |
| std::string | m_inputObjectName {""} |
| SG::WriteHandleKey< MdtDigitContainer > | m_outputObjectKey |
| SG::WriteHandleKey< MuonSimDataCollection > | m_outputSDOKey |
| ServiceHandle< IAthRNGSvc > | m_rndmSvc {this, "RndmSvc", "AthRNGSvc", ""} |
| SG::ReadCondHandleKey< MuonCalib::MdtCalibDataContainer > | m_calibDbKey |
| SG::ReadCondHandleKey< MdtCondDbData > | m_readKey {this, "ReadKey", "MdtCondDbData", "Key of MdtCondDbData"} |
Private Types | |
| using | Collections_t = std::vector<std::unique_ptr<MdtDigitCollection> > |
Private Member Functions | |
| CLHEP::HepRandomEngine * | getRandomEngine (const std::string &streamName, const EventContext &ctx) const |
| int | digitizeTime (double time, bool isHPTDC, CLHEP::HepRandomEngine *rndmEngine) const |
| double | minimumTof (Identifier DigitId, const MuonGM::MuonDetectorManager *detMgr) const |
| bool | insideMatchingWindow (double time) const |
| bool | insideMaskWindow (double time) const |
| bool | checkMDTSimHit (const EventContext &ctx, const MDTSimHit &hit) const |
| bool | handleMDTSimHit (const EventContext &ctx, const TimedHitPtr< MDTSimHit > &phit, CLHEP::HepRandomEngine *twinRndmEngine, CLHEP::HepRandomEngine *toolRndmEngine) |
| bool | createDigits (const EventContext &ctx, Collections_t &collections, MuonSimDataCollection *sdoContainer, CLHEP::HepRandomEngine *rndmEngine) |
| GeoCorOut | correctGeometricalWireSag (const MDTSimHit &hit, const Identifier &id, const MuonGM::MdtReadoutElement *element) const |
| StatusCode | getNextEvent (const EventContext &ctx) |
| StatusCode | doDigitization (const EventContext &ctx, Collections_t &collections, MuonSimDataCollection *sdoContainer) |
| MdtDigitCollection * | getDigitCollection (Identifier elementId, Collections_t &collections) |
| void | fillMaps (const MDTSimHit *mdtHit, const Identifier digitId, const double driftR) |
Static Private Member Functions | |
| static MDTSimHit | applyDeformations (const MDTSimHit &, const MuonGM::MdtReadoutElement *, const Identifier &) |
Private Attributes | |
| MDT_SortedHitVector | m_hits |
| ServiceHandle< Muon::IMuonIdHelperSvc > | m_idHelperSvc {this, "MuonIdHelperSvc", "Muon::MuonIdHelperSvc/MuonIdHelperSvc"} |
| const MdtHitIdHelper * | m_muonHelper {} |
| const MuonGM::MuonDetectorManager * | m_MuonGeoMgr {} |
| ToolHandle< IMDT_DigitizationTool > | m_digiTool |
| std::vector< MDTSimHitCollection * > | m_MDTHitCollList |
| Gaudi::Property< double > | m_offsetTDC {this, "OffsetTDC", 800., "TDC offset used if no calibration data is found"} |
| Gaudi::Property< double > | m_signalSpeed {this, "SignalSpeed", 0.85*Gaudi::Units::c_light} |
| Gaudi::Property< double > | m_ns2TDCAMT {this, "ns2TDCAMT", 0.78125, "Conversion factor TDC/ns for AMT chips"} |
| Gaudi::Property< double > | m_ns2TDCHPTDC {this, "ns2TDCHPTDC", 0.1953125, "Conversion factor TDC/ns for HPTDC chips"} |
| Gaudi::Property< double > | m_resTDC {this, "ResolutionTDC", 0.5, "TDC resolution"} |
| Gaudi::Property< double > | m_t0ShiftTuning {this,"TunedT0Shift",-17.,"Fine tuned t0 shift value in ns"} |
| Gaudi::Property< bool > | m_checkMDTSimHits {this, "CheckSimHits", true, "Control on the hit validity"} |
| Gaudi::Property< bool > | m_useTof {this, "UseTof", true, "Option for the tof calculation"} |
| Gaudi::Property< bool > | m_useAttenuation {this, "UseAttenuation", false, ""} |
| Gaudi::Property< bool > | m_useProp {this, "UseProp", true, ""} |
| Gaudi::Property< bool > | m_useTwin {this, "UseTwin", false, ""} |
| Gaudi::Property< bool > | m_useAllBOLTwin {this, "UseAllBOLTwin", false, ""} |
| Gaudi::Property< double > | m_resTwin {this, "ResolutionTwinTube", 1.05, "Twin Tube resolution"} |
| Gaudi::Property< bool > | m_useTimeWindow {this, "UseTimeWindow", true, ""} |
| Gaudi::Property< double > | m_bunchCountOffset {this, "BunchCountOffset", -200., "Bunch crossing offset"} |
| Gaudi::Property< double > | m_matchingWindow {this, "MatchingWindow", 1000., "Matching window"} |
| Gaudi::Property< double > | m_maskWindow {this, "MaskWindow", 250., "Masked window"} |
| Gaudi::Property< double > | m_deadTime {this, "DeadTime", 700., "MDT drift tube dead time"} |
| Gaudi::Property< bool > | m_DiscardEarlyHits {this, "DiscardEarlyHits", true, ""} |
| Gaudi::Property< bool > | m_useOffSet1 {this, "UseOffSet1", true, ""} |
| Gaudi::Property< bool > | m_useOffSet2 {this, "UseOffSet2", true, ""} |
| Gaudi::Property< bool > | m_useDeformations {this, "UseDeformations", false, ""} |
| Gaudi::Property< bool > | m_DoQballCharge {this, "DoQballCharge", false, "dEdx for Qballs with account of electric charge"} |
| std::unique_ptr< TimedHitCollection< MDTSimHit > > | m_thpcMDT {} |
| Gaudi::Property< bool > | m_includePileUpTruth {this, "IncludePileUpTruth", true, "Include pile-up truth info"} |
structors and AlgTool implementation | |
| Gaudi::Property< int > | m_firstXing |
| Gaudi::Property< int > | m_lastXing |
| Gaudi::Property< int > | m_vetoPileUpTruthLinks |
| bool | m_filterPassed {true} |
| virtual bool | toProcess (int bunchXing) const override |
| the method this base class helps implementing | |
| virtual bool | filterPassed () const override |
| dummy implementation of passing filter | |
| virtual void | resetFilter () override |
| dummy implementation of filter reset | |
In the initialize() method, the PileUpMerge and StoreGate services are initialized, and a pointer to an instance of the class MuonDetectorManager is retrieved from the detector store and used to obtain a MdtIdHelper.The MdtDigitContainer is initialized and the simulation identifier helper retrieved, together with the pointer to the digitization tool.
Random numbers are obtained in the code from a dedicated stream via AtRndmSvc, which is also initialized in the initialize() method.
In the execute() method, the digits and the SDOs (Simulation Data Object, container for simulation data to be preserved after the digitization procedue, and persistified together with the RDOs) containers are created and recorded on StoreGate; the MDTSimHit collection are merged using the TimedHitCollection sorted container (done in handleMDTSimHit(TimedHitPtr <MDTSimHit>& hit)) method); into a loop over the TimedHitCollection for the given DetectorElement, the handleMDTSimHit() method converts the SimID into the Offline ID to be associated to the Digit and pass to the digitization tool the drift radius and the distance to the chamber RO side (for the propagation delay computation). The digitization tool returns a drift time and an ADC count which are used together with the Offline ID, to create the digit object (in createDigits() method).
The finalize() method returns a SUCCESS StatusCode if the digitization procedure ends succesfully.
Definition at line 87 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
private |
Definition at line 119 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
| MdtDigitizationTool::MdtDigitizationTool | ( | const std::string & | type, |
| const std::string & | name, | ||
| const IInterface * | pIID ) |
Definition at line 64 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.cxx.
|
virtualdefault |
|
staticprivate |
Definition at line 811 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.cxx.
|
private |
Definition at line 540 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.cxx.
|
private |
Definition at line 823 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.cxx.
|
private |
Definition at line 601 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.cxx.
|
private |
Definition at line 767 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.cxx.
|
private |
Definition at line 312 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.cxx.
|
private |
|
inlineoverridevirtualinherited |
|
private |
Definition at line 746 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.cxx.
|
private |
Definition at line 184 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.cxx.
|
private |
Definition at line 236 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.cxx.
|
private |
Definition at line 349 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.cxx.
|
finaloverridevirtual |
Initialize.
Reimplemented from PileUpToolBase.
Definition at line 67 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.cxx.
|
private |
Definition at line 801 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.cxx.
|
private |
Definition at line 792 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.cxx.
|
finaloverride |
When being run from PileUpToolsAlgs, this method is called at the end of the subevts loop.
Not (necessarily) able to access SubEvents
Definition at line 243 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.cxx.
|
private |
Definition at line 775 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.cxx.
|
finaloverride |
When being run from PileUpToolsAlgs, this method is called at the start of the subevts loop.
Not able to access SubEvents
Definition at line 143 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.cxx.
|
finaloverridevirtual |
alternative interface which uses the PileUpMergeSvc to obtain all the required SubEvents.
Reimplemented from PileUpToolBase.
Definition at line 278 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.cxx.
|
finaloverridevirtual |
When being run from PileUpToolsAlgs, this method is called for each active bunch-crossing to process current SubEvents bunchXing is in ns.
Reimplemented from PileUpToolBase.
Definition at line 152 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.cxx.
|
inlineoverridevirtualinherited |
dummy implementation of filter reset
Reimplemented in MergeTruthJetsTool.
Definition at line 51 of file PileUpToolBase.h.
|
inlineoverridevirtualinherited |
the method this base class helps implementing
Reimplemented in MergeHijingParsTool, and MergeTrackRecordCollTool.
Definition at line 32 of file PileUpToolBase.h.
|
private |
Definition at line 170 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
protected |
Definition at line 215 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
private |
Definition at line 158 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
private |
Definition at line 173 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
private |
Definition at line 144 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
private |
Definition at line 174 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
private |
Definition at line 185 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
protectedinherited |
Definition at line 60 of file PileUpToolBase.h.
|
protectedinherited |
Definition at line 54 of file PileUpToolBase.h.
|
private |
Definition at line 135 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
protected |
Definition at line 206 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
private |
Definition at line 137 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
private |
Definition at line 191 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
protected |
Definition at line 207 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
protectedinherited |
Definition at line 56 of file PileUpToolBase.h.
|
private |
Definition at line 172 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
private |
Definition at line 171 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
private |
Definition at line 146 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
protected |
Definition at line 203 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
private |
Definition at line 142 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
private |
Definition at line 138 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
private |
Definition at line 152 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
private |
Definition at line 153 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
private |
Definition at line 149 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
protected |
Definition at line 204 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
protected |
Definition at line 208 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
protected |
Definition at line 210 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
protected |
Definition at line 218 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
private |
Definition at line 154 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
private |
Definition at line 166 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
protected |
Definition at line 213 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
private |
Definition at line 150 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
private |
Definition at line 155 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
private |
Definition at line 188 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
private |
Definition at line 165 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
private |
Definition at line 160 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
private |
Definition at line 182 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
private |
Definition at line 177 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
private |
Definition at line 178 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
private |
Definition at line 161 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
private |
Definition at line 169 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
private |
Definition at line 159 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
private |
Definition at line 164 of file MuonDigitization/MDT_Digitization/src/MdtDigitizationTool.h.
|
protectedinherited |
Definition at line 58 of file PileUpToolBase.h.