|
ATLAS Offline Software
|
#include <LArCalibDigitMaker.h>
|
| LArCalibDigitMaker (const std::string &name, ISvcLocator *pSvcLocator) |
|
| ~LArCalibDigitMaker () |
|
StatusCode | initialize () |
|
StatusCode | execute () |
|
StatusCode | finalize () |
|
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 13 of file LArCalibDigitMaker.h.
◆ StoreGateSvc_t
◆ LArCalibDigitMaker()
LArCalibDigitMaker::LArCalibDigitMaker |
( |
const std::string & |
name, |
|
|
ISvcLocator * |
pSvcLocator |
|
) |
| |
◆ ~LArCalibDigitMaker()
LArCalibDigitMaker::~LArCalibDigitMaker |
( |
| ) |
|
◆ 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 LArCalibDigitMaker::execute |
( |
| ) |
|
Definition at line 116 of file LArCalibDigitMaker.cxx.
118 if (
m_dontRun)
return StatusCode::SUCCESS;
120 const EventContext& ctx = Gaudi::Hive::currentContext();
125 ATH_MSG_DEBUG (
"======== LArCalibDigitMaker: using SC calib line map" );
136 return StatusCode::FAILURE;
139 const unsigned eventNb=(ctx.eventID().event_number())&0xffffff ;
141 ATH_MSG_DEBUG (
"======== executing event "<< eventNb <<
" ========" );
150 if (
sc.isFailure()) {
151 ATH_MSG_DEBUG (
"Cannot read LArDigitContainer from StoreGate! key=" <<
key );
154 if (larDigitCont->
empty()) {
155 ATH_MSG_DEBUG (
"LArDigitContainer with key '" <<
key <<
"' is empty. Ignored." );
160 auto calibDigitContainer=std::make_unique<LArCalibDigitContainer>();
171 const std::vector<short>& samples=
digit->samples();
173 const std::vector<HWIdentifier>& calibChannelIDs=clcabling->
calibSlotLine(chid);
174 if (calibChannelIDs.empty()) {
178 std::vector<HWIdentifier>::const_iterator csl_it=calibChannelIDs.begin();
181 unsigned ddac=calibParams->
DAC(eventNb,*csl_it);
190 for(; csl_it != calibChannelIDs.end(); ++csl_it) {
191 if(calibParams->
isPulsed(eventNb,*csl_it)){
198 ATH_MSG_VERBOSE(
"HERE!! "<<chid<<
" "<<
gain<<
" "<<
dac<<
" "<<
delay<<
" "<<ispulsed<<
" event no "<<eventNb<<
" "<<calibChannelIDs.size()<<
" calib lines, first is "<<*csl_it);
202 calibDigitContainer->push_back(calibDigit);
206 ATH_MSG_DEBUG (
"LArCalibDigitContainer recorded to StoreGate. key=" <<
key );
208 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 LArCalibDigitMaker::finalize |
( |
| ) |
|
|
inline |
◆ initialize()
StatusCode LArCalibDigitMaker::initialize |
( |
| ) |
|
Definition at line 45 of file LArCalibDigitMaker.cxx.
51 ATH_MSG_DEBUG (
"======== LArCalibDigitMaker Initialize ========" );
56 ATH_MSG_DEBUG (
"======== LArCalibDigitMaker isSC is True ========" );
64 std::vector<std::vector<unsigned>> theseBoardIDs;
65 std::vector<std::vector<unsigned>> thesePatterns;
66 std::vector<std::vector<unsigned>> theseDACs;
69 theseDACs.reserve(
m_vDAC.size());
71 theseBoardIDs.emplace_back(elem.begin(), elem.end());
74 thesePatterns.emplace_back(elem.begin(), elem.end());
76 for (
const auto& elem :
m_vDAC) {
77 theseDACs.emplace_back(elem.begin(), elem.end());
79 std::vector<unsigned> cutPattern;
81 auto calibParams = std::make_unique<LArCalibParams>();
83 for(
long unsigned int i=0;
i < theseBoardIDs.size();
i++ ){
85 cutPattern = thesePatterns[
i];
91 if (thesePatterns[
i].
size()%4) {
92 ATH_MSG_ERROR (
"Problem with jobOptions! One Pattern must conists of 4 32bit values! Pattern "<<
i );
93 return StatusCode::FAILURE;
95 for (
unsigned id : theseBoardIDs[
i]) {
111 ATH_MSG_DEBUG (
"======== LArCalibDigitMaker initialize successfully ========" );
112 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()
◆ m_calibMapKey
◆ m_calibMapSCKey
◆ m_delayScale
double LArCalibDigitMaker::m_delayScale |
|
private |
◆ m_detStore
◆ m_dontRun
bool LArCalibDigitMaker::m_dontRun |
|
private |
◆ m_eventNb
int LArCalibDigitMaker::m_eventNb = 0 |
|
private |
◆ m_evtStore
◆ m_extendedExtraObjects
DataObjIDColl AthAlgorithm::m_extendedExtraObjects |
|
privateinherited |
◆ m_isSC
bool LArCalibDigitMaker::m_isSC |
|
private |
◆ m_keylist
std::vector<std::string> LArCalibDigitMaker::m_keylist |
|
private |
◆ m_nPatterns
std::vector<int> LArCalibDigitMaker::m_nPatterns |
|
private |
◆ m_nTrigger
unsigned LArCalibDigitMaker::m_nTrigger |
|
private |
◆ m_pulsedChids
◆ m_skipDuplicates
bool LArCalibDigitMaker::m_skipDuplicates |
|
private |
◆ m_varHandleArraysDeclared
◆ m_vBoardIDs
std::vector<std::vector<double> > LArCalibDigitMaker::m_vBoardIDs |
|
private |
◆ m_vDAC
std::vector<std::vector<double> > LArCalibDigitMaker::m_vDAC |
|
private |
◆ m_vDelay
std::vector<unsigned> LArCalibDigitMaker::m_vDelay |
|
private |
◆ m_vhka
◆ m_vPattern
std::vector<std::vector<double> > LArCalibDigitMaker::m_vPattern |
|
private |
The documentation for this class was generated from the following files:
def retrieve(aClass, aKey=None)
std::vector< HWIdentifier > m_pulsedChids
std::vector< int > m_nPatterns
std::vector< std::vector< double > > m_vBoardIDs
std::string find(const std::string &s)
return a remapped string
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
const std::vector< HWIdentifier > & calibSlotLine(const HWIdentifier id) const
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
std::vector< SG::VarHandleKeyArray * > m_vhka
#define ATH_MSG_VERBOSE(x)
const std::string & key() const
Return the StoreGate ID for the referenced object.
const ServiceHandle< StoreGateSvc > & detStore() const
The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.
virtual void setOwner(IDataHandleHolder *o)=0
#define kmaxDAC
This class contains the LAr Calibration Board settings and a set of functions to decoded them.
ServiceHandle< StoreGateSvc > & evtStore()
The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.
virtual StatusCode sysInitialize() override
Override sysInitialize.
virtual std::vector< Gaudi::DataHandle * > outputHandles() const override
Return this algorithm's output handles.
Liquid Argon digit base class.
::StatusCode StatusCode
StatusCode definition for legacy code.
std::vector< std::vector< double > > m_vDAC
bool isPulsed(const unsigned event, const HWIdentifier calibLineID) const
double delay(std::size_t d)
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
SG::ReadCondHandleKey< LArCalibLineMapping > m_calibMapKey
std::vector< std::vector< double > > m_vPattern
unsigned DAC(const unsigned event, const HWIdentifier calibLineID) const
Base class for LArDigits taken during calibration runs.
unsigned Delay(const unsigned event, const HWIdentifier calibLineID) const
StatusCode initialize(bool used=true)
std::vector< unsigned > m_vDelay
DataObjIDColl m_extendedExtraObjects
#define ATH_MSG_WARNING(x)
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
Container class for LArDigit.
AthAlgorithm()
Default constructor:
std::vector< std::string > m_keylist
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
bool empty() const noexcept
Returns true if the collection is empty.
SG::ReadCondHandleKey< LArCalibLineMapping > m_calibMapSCKey