|
ATLAS Offline Software
|
#include <LArPhysWaveShifter.h>
|
| LArPhysWaveShifter (const std::string &name, ISvcLocator *pSvcLocator) |
|
| ~LArPhysWaveShifter () |
|
StatusCode | initialize () |
|
StatusCode | execute () |
|
StatusCode | stop () |
|
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 22 of file LArPhysWaveShifter.h.
◆ StoreGateSvc_t
◆ LArPhysWaveShifter()
LArPhysWaveShifter::LArPhysWaveShifter |
( |
const std::string & |
name, |
|
|
ISvcLocator * |
pSvcLocator |
|
) |
| |
◆ ~LArPhysWaveShifter()
LArPhysWaveShifter::~LArPhysWaveShifter |
( |
| ) |
|
|
default |
◆ ComputeTimeShiftByFEB()
StatusCode LArPhysWaveShifter::ComputeTimeShiftByFEB |
( |
unsigned |
mode = 2 | ) |
|
|
private |
Definition at line 321 of file LArPhysWaveShifter.cxx.
347 if (
sc.isFailure()) {
348 ATH_MSG_INFO(
"LArPhysWaveContainer (key=" <<
key <<
") not found in StoreGate" );
351 if ( larPhysWaveContainerOld ==
nullptr ) {
356 ATH_MSG_INFO(
"ComputeTimeShiftByFEB(): processing LArPhysWaveContainer from StoreGate, key = " <<
key );
363 if ( wave_it == wave_it_e ) {
364 ATH_MSG_INFO(
"ComputeTimeShiftByFEB(): LArPhysWaveContainer (key = " <<
key <<
") has no wave with gain = " <<
gain );
368 for ( ; wave_it!=wave_it_e; wave_it++) {
371 if ( larPhysWave->
isEmpty() )
continue;
377 unsigned newFEBTstart = 999;
378 unsigned theChanInFEB = 0;
392 ATH_MSG_VERBOSE(std::hex << chid << std::dec<<
" TimeOffset: "<<bindiff);
398 theChanInFEB =
static_cast<unsigned>(nChanInFEB.
TimeOffset(febid)+1);
417 for (;
it!=it_e;++
it) {
424 ATH_MSG_INFO( nFeb <<
". FEB ID 0x" << std::hex << (*it).get_compact() << std::dec
436 outfile <<
"FakeLArTimeOffset.FEBids = [ " ;
439 for (;
it!=it_e;++
it) {
440 outfile <<
"0x" << std::hex << (*it).get_compact() << std::dec ;
445 outfile <<
"FakeLArTimeOffset.FEbTimeOffsets = [ " ;
448 for (;
it!=it_e;++
it) {
459 return StatusCode::FAILURE;
464 ATH_MSG_ERROR(
"Can't record LArFEBTimeOffset to DetectorStore" );
465 return StatusCode::FAILURE;
471 ATH_MSG_ERROR(
"Can't symlink LArFEBTimeOffset to abstract interface in DetectorStore" );
472 return StatusCode::FAILURE;
475 return StatusCode::SUCCESS;
◆ 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 LArPhysWaveShifter::execute |
( |
| ) |
|
|
inline |
◆ 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 LArPhysWaveShifter::finalize |
( |
| ) |
|
|
inline |
◆ initialize()
StatusCode LArPhysWaveShifter::initialize |
( |
| ) |
|
|
inline |
◆ 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()
◆ stop()
StatusCode LArPhysWaveShifter::stop |
( |
| ) |
|
Definition at line 74 of file LArPhysWaveShifter.cxx.
90 msg(MSG::ERROR) <<
"Could not get LArOnlineID helper !" <<
endmsg;
91 return StatusCode::FAILURE;
100 if (
sc.isFailure()) {
101 msg(MSG::ERROR) <<
"Could not get LArOnlineID helper !" <<
endmsg;
102 return StatusCode::FAILURE;
111 ToolHandle<LArPhysWaveTool> larPhysWaveTool(
"LArPhysWaveTool");
112 sc=larPhysWaveTool.retrieve();
113 if (
sc!=StatusCode::SUCCESS) {
122 if (
sc!=StatusCode::SUCCESS) {
124 <<
". Disabling use of PhysCaliTdiff values in wave shift." );
127 ATH_MSG_INFO(
"LArPhysCaliTdiff successfully retrieved" );
135 if(!
sc.isSuccess()) {
143 ATH_MSG_INFO(
"Will use helper class for start time." );
156 ATH_MSG_INFO(
"Manually shifting pulses by a constant index from peak." );
173 ATH_MSG_INFO(
"Manually shifting pulses by *FEB* time indexes." );
175 if (
sc.isFailure()) {
176 ATH_MSG_ERROR(
"Cannot find any FEB time offsets. Please check." );
183 auto totalShifts = std::make_unique<LArOFCBinComplete>();
185 ATH_MSG_ERROR(
"Failed to set grouping type for LArPhysCaliTdiffComplete object" );
186 return StatusCode::FAILURE;
189 if(totalShifts->initialize().isFailure()) {
190 ATH_MSG_ERROR(
"Failed to initialize LArPhysCaliTdiffComplete object" );
191 return StatusCode::FAILURE;
203 if (
sc.isFailure()) {
204 ATH_MSG_INFO(
"LArPhysWaveContainer (key=" <<
key <<
") not found in StoreGate" );
207 ATH_MSG_INFO(
"Processing LArPhysWaveContainer from StoreGate, key = " <<
key );
216 if ( wave_it == wave_it_e ) {
217 ATH_MSG_INFO(
"LArPhysWaveContainer (key = " <<
key <<
") has no wave with gain = " <<
gain );
221 for ( ; wave_it!=wave_it_e; wave_it++) {
223 if ( nchannel < 100 || ( nchannel < 1000 && nchannel%100==0 ) || nchannel%1000==0 )
224 ATH_MSG_INFO(
"Processing physics waveform number " << nchannel );
230 if ( larPhysWave->
isEmpty() ) {
257 float tdiff = larPhysCaliTdiff->
Tdiff(chid,
gain);
258 if (tdiff<=-999.) tdiff = 0.;
260 tdiff = tdiff>0. ? (
float)((
long)(tdiff+0.5)) : (
float)((long)(tdiff-0.5));
272 <<
" --> Time shift for channel 0x" << MSG::hex << chid.
get_compact() << MSG::dec
310 if (
sc.isFailure()) {
317 return StatusCode::SUCCESS;
◆ 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_cellByCellShiftsKey
std::string LArPhysWaveShifter::m_cellByCellShiftsKey |
|
private |
◆ m_compTimeShiftByFEB
bool LArPhysWaveShifter::m_compTimeShiftByFEB |
|
private |
◆ m_detStore
◆ m_dumpTimeShiftByFEB
bool LArPhysWaveShifter::m_dumpTimeShiftByFEB |
|
private |
◆ m_evtStore
◆ m_extendedExtraObjects
DataObjIDColl AthAlgorithm::m_extendedExtraObjects |
|
privateinherited |
◆ m_fileTimeShiftByFEB
std::string LArPhysWaveShifter::m_fileTimeShiftByFEB |
|
private |
◆ m_groupingType
std::string LArPhysWaveShifter::m_groupingType |
|
private |
◆ m_isSC
bool LArPhysWaveShifter::m_isSC |
|
private |
◆ m_keylist
std::vector<std::string> LArPhysWaveShifter::m_keylist |
|
private |
◆ m_keyout
std::string LArPhysWaveShifter::m_keyout |
|
private |
◆ m_larFEBTstart
◆ m_modeTimeShiftByFEB
unsigned LArPhysWaveShifter::m_modeTimeShiftByFEB |
|
private |
◆ m_nDelays
int LArPhysWaveShifter::m_nDelays |
|
private |
◆ m_nIndexFromPeak
int LArPhysWaveShifter::m_nIndexFromPeak |
|
private |
◆ m_nSamplings
int LArPhysWaveShifter::m_nSamplings |
|
private |
◆ m_onlineHelper
◆ m_timeShiftByFEB
bool LArPhysWaveShifter::m_timeShiftByFEB |
|
private |
◆ m_timeShiftByHelper
bool LArPhysWaveShifter::m_timeShiftByHelper |
|
private |
◆ m_timeShiftByIndex
int LArPhysWaveShifter::m_timeShiftByIndex |
|
private |
◆ m_timeShiftFromPeak
bool LArPhysWaveShifter::m_timeShiftFromPeak |
|
private |
◆ m_timeShiftGuardRegion
int LArPhysWaveShifter::m_timeShiftGuardRegion |
|
private |
◆ m_timeShiftOffset
bool LArPhysWaveShifter::m_timeShiftOffset |
|
private |
◆ m_timeShiftOffsetValue
float LArPhysWaveShifter::m_timeShiftOffsetValue |
|
private |
◆ m_totalShiftsKey
std::string LArPhysWaveShifter::m_totalShiftsKey |
|
private |
◆ m_TshiftLayer
std::vector<unsigned int> LArPhysWaveShifter::m_TshiftLayer |
|
private |
◆ m_usePhysCaliTdiff
bool LArPhysWaveShifter::m_usePhysCaliTdiff |
|
private |
◆ m_varHandleArraysDeclared
◆ m_vhka
The documentation for this class was generated from the following files:
std::string m_cellByCellShiftsKey
std::string m_groupingType
virtual const float & Tdiff(const HWIdentifier &id, int gain) const =0
HWIdentifier channelId() const
unsigned getStart(const LArWave &theWave) const
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
virtual float TimeOffset(const HWIdentifier fId) const =0
Declaration of const iterator.
int m_timeShiftGuardRegion
std::string m_totalShiftsKey
const double & getDt() const
delta time
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
std::vector< SG::VarHandleKeyArray * > m_vhka
value_type get_compact() const
Get the compact id.
id_iterator feb_begin() const
Returns an iterator pointing to a feb identifier collection.
bool m_dumpTimeShiftByFEB
StatusCode ComputeTimeShiftByFEB(unsigned mode)
#define ATH_MSG_VERBOSE(x)
unsigned int getMax(const LArWave &theWave) const
return index of maximum sample
unsigned m_modeTimeShiftByFEB
Liquid Argon Physics Wave Container.
const ServiceHandle< StoreGateSvc > & detStore() const
The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.
const LArOnlineID_Base * m_onlineHelper
virtual void setOwner(IDataHandleHolder *o)=0
bool m_compTimeShiftByFEB
virtual StatusCode sysInitialize() override
Override sysInitialize.
bool isEmpty() const
is LArWave uninitialized?
virtual std::vector< Gaudi::DataHandle * > outputHandles() const override
Return this algorithm's output handles.
ConstConditionsMapIterator end(unsigned int gain) const
end of all channels for this gain
LArFEBTimeOffset * m_larFEBTstart
::StatusCode StatusCode
StatusCode definition for legacy code.
std::string m_fileTimeShiftByFEB
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
std::vector< std::string > m_keylist
HWIdentifier feb_Id(int barrel_ec, int pos_neg, int feedthrough, int slot) const
Create feb_Id from fields.
virtual void renounce()=0
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
id_iterator feb_end() const
float TimeOffset(const HWIdentifier fId) const
Helper for the Liquid Argon Calorimeter cell identifiers.
DataObjIDColl m_extendedExtraObjects
#define ATH_MSG_WARNING(x)
ConstConditionsMapIterator begin(unsigned int gain) const
get iterator for all channels for a gain
void setTimeOffset(const HWIdentifier fId, const float offset)
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
AthAlgorithm()
Default constructor:
void setDefaultReturnValue(const float value)
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
float m_timeShiftOffsetValue