|
ATLAS Offline Software
|
This is a non-template implementation base class for LArConditionsContainer.
More...
#include <LArConditionsContainerBase.h>
|
static bool | applyCorrectionsAtInit (bool setFlag=false, bool flag=true) |
| provide access to flag which determines corrections are applied at initialize, i.e. More...
|
|
This is a non-template implementation base class for LArConditionsContainer.
This class contains implementation details in a non-template form allowing it code to be compiled into a library.
Definition at line 39 of file LArConditionsContainerBase.h.
◆ FEBIdVector
◆ GroupingType
Grouping type.
Enumerator |
---|
Unknown | |
SingleGroup | |
SubDetectorGrouping | |
FeedThroughGrouping | |
ExtendedFTGrouping | |
ExtendedSubDetGrouping | |
SuperCells | |
Definition at line 44 of file LArConditionsContainerBase.h.
◆ LArConditionsContainerBase() [1/2]
LArConditionsContainerBase::LArConditionsContainerBase |
( |
| ) |
|
◆ LArConditionsContainerBase() [2/2]
LArConditionsContainerBase::LArConditionsContainerBase |
( |
GroupingType |
type | ) |
|
◆ ~LArConditionsContainerBase()
LArConditionsContainerBase::~LArConditionsContainerBase |
( |
| ) |
|
|
virtual |
◆ applyCorrectionsAtInit()
bool LArConditionsContainerBase::applyCorrectionsAtInit |
( |
bool |
setFlag = false , |
|
|
bool |
flag = true |
|
) |
| |
|
static |
provide access to flag which determines corrections are applied at initialize, i.e.
when conditions are read in. Default is true. This is a class (static) variable which applied to ALL conditions in a job! If one wants to change the value of the flag, pass in arguments:
Definition at line 565 of file LArConditionsContainerBase.cxx.
571 static std::atomic<bool> applyCorrs =
true;
◆ correctionIndexAndCoolChannel()
void LArConditionsContainerBase::correctionIndexAndCoolChannel |
( |
HWIdentifier |
id, |
|
|
unsigned int |
gain, |
|
|
unsigned int & |
index, |
|
|
unsigned int & |
coolChannel |
|
) |
| |
|
protected |
Definition at line 501 of file LArConditionsContainerBase.cxx.
512 log << MSG::ERROR <<
"correctionIndex> Could not get online id helper!" <<
endmsg;
543 log << MSG::ERROR <<
"correctionIndex> coolChannel not found! Online ids: "
551 coolChannel += gainOffset;
555 log << MSG::ERROR <<
"correctionIndex> coolChannel larger than lookup table: chan, size "
◆ febIdVector()
◆ groupingTypeToString()
std::string LArConditionsContainerBase::groupingTypeToString |
( |
| ) |
const |
|
protected |
Definition at line 458 of file LArConditionsContainerBase.cxx.
465 return (
"SingleGroup");
467 return (
"SubDetectorGrouping");
469 return (
"FeedThroughGrouping");
471 return (
"ExtendedFTGrouping");
473 return (
"ExtendedSubDetGrouping");
475 return (
"SuperCells");
◆ initGrouping()
StatusCode LArConditionsContainerBase::initGrouping |
( |
| ) |
|
|
protected |
Definition at line 131 of file LArConditionsContainerBase.cxx.
139 log << MSG::ERROR <<
"Unknown grouping "<<
endmsg;
151 for (; febIt != febEnd; ++febIt) {
152 febIds.push_back((*febIt).get_identifier32().get_compact());
155 unsigned int nChanPerGain = 1;
156 unsigned int minGain = 0;
157 unsigned int nGains = 3;
174 for (; febIt != febEnd; ++febIt) {
175 unsigned int febId = (*febIt).get_identifier32().get_compact();
177 emBarrel.push_back(febId);
180 emEndcap.push_back(febId);
183 hec.push_back(febId);
186 fcal.push_back(febId);
190 << MSG::hex << (febId) << MSG::dec
197 unsigned int nChanPerGain = 4;
198 unsigned int minGain = 0;
199 unsigned int nGains = 3;
252 for (; febIt != febEnd; ++febIt) {
255 if(iside <0 || iside > 1) {
256 log << MSG::ERROR <<
"Wrong side id: "<< iside <<
" from: "
257 << MSG::hex << *febIt << MSG::dec <<
endmsg;
258 return (StatusCode::FAILURE);
260 unsigned int febId = (*febIt).get_identifier32().get_compact();
262 emBarrelPS[iside].push_back(febId);
265 emEndcapPS[iside].push_back(febId);
268 emBarrel[iside].push_back(febId);
271 emEndcap[iside].push_back(febId);
274 hec[iside].push_back(febId);
277 fcal[iside].push_back(febId);
281 << MSG::hex << (febId) << MSG::dec
288 unsigned int nChanPerGain = 12;
289 unsigned int minGain = 0;
290 unsigned int nGains = 3;
292 for (
int iside=0; iside<2; ++iside) {
312 for (; febIt != febEnd; ++febIt) {
320 if (fthash <
ft.size()) {
324 log << MSG::ERROR <<
"Feedthru hash > channel map size: id, hash, size "
325 << MSG::hex << febId << MSG::dec <<
" "
326 << ftid <<
" " <<
ft.size()
328 return (StatusCode::FAILURE);
332 unsigned int nChanPerGain =
ft.size();
333 unsigned int minGain = 0;
334 unsigned int nGains = 3;
336 for (
unsigned int i = 0;
i <
ft.size(); ++
i) {
342 log <<
MSG::DEBUG <<
"Extended FeedThrough grouping (PS goes seperatly, EMEC in HEC as well)"<<
endmsg;
354 std::vector<LArCondFEBIdChanMap::FEBIdVector> ftSpecial(8);
356 for (; febIt != febEnd; ++febIt) {
366 if (fthash >=
ft.size()) {
367 log << MSG::ERROR <<
"Feedthru hash > channel map size: id, hash, size "
368 << MSG::hex << febId << MSG::dec <<
" "
369 << ftid <<
" " <<
ft.size()
371 return (StatusCode::FAILURE);
411 unsigned int nChanPerGain =
ft.size()+ftPS.size()+ftSpecial.size();
412 unsigned int minGain = 0;
413 unsigned int nGains = 3;
414 unsigned int iCoolChannel=0;
416 for (
unsigned int i = 0;
i <
ft.size(); ++
i) {
419 for (
unsigned int i = 0;
i < ftPS.size(); ++
i) {
422 for (
unsigned int i = 0;
i < ftSpecial.size(); ++
i) {
427 return StatusCode::FAILURE;
453 return (StatusCode::SUCCESS);
◆ initializeBase()
StatusCode LArConditionsContainerBase::initializeBase |
( |
| ) |
|
◆ offlineHelper()
◆ onlineHelper()
◆ setGroupingType() [1/2]
StatusCode LArConditionsContainerBase::setGroupingType |
( |
const std::string & |
groupingStr, |
|
|
MsgStream & |
logStr |
|
) |
| |
allow group type to be set externally based on a string returns an FAILURE and a message to logStr if unknown string is supplied
Definition at line 96 of file LArConditionsContainerBase.cxx.
99 if (groupingStr ==
"Single")
101 return StatusCode::SUCCESS;
103 else if (groupingStr ==
"SubDetector")
105 return StatusCode::SUCCESS;
107 else if (groupingStr ==
"ExtendedSubDetector")
109 return StatusCode::SUCCESS;
111 else if (groupingStr ==
"FeedThrough")
113 return StatusCode::SUCCESS;
115 else if (groupingStr ==
"ExtendedFeedThrough") {
117 return StatusCode::SUCCESS;
119 else if (groupingStr ==
"SuperCells") {
121 return StatusCode::SUCCESS;
124 logStr << MSG::ERROR <<
"Unknown COOL Channel Grouping '"<< groupingStr <<
"'. Allowed values are:" <<
endmsg;
125 logStr << MSG::ERROR <<
"'Single','SubDetector', 'ExtendedSubDetector','FeedThrough','ExtendedFeedThrough'" <<
endmsg;
126 return StatusCode::FAILURE;
◆ setGroupingType() [2/2]
void LArConditionsContainerBase::setGroupingType |
( |
GroupingType |
type | ) |
|
◆ m_channelToMultChanCollIndex
std::vector<unsigned int> LArConditionsContainerBase::m_channelToMultChanCollIndex |
|
protected |
◆ m_febIdChanMap
◆ m_groupType
◆ m_isInitialized
bool LArConditionsContainerBase::m_isInitialized |
|
protected |
◆ m_offlineHelper
◆ m_onlineHelper
The documentation for this class was generated from the following files:
size_type feedthroughHashMax(void) const
Define feedthrough hash tables max size.
unsigned int totalChannels() const
Total number of channels for all gains and includes special offset channels.
void setGroupingType(GroupingType type)
allow group type to be set externally - need to (re)initialize after setting grouping type
unsigned int channelsPerGain() const
Number of cool channels per gain.
Identifier32 get_identifier32() const
Get the 32-bit version Identifier, will be invalid if >32 bits needed.
id_iterator feb_begin() const
Returns an iterator pointing to a feb identifier collection.
StatusCode initGrouping()
int barrel_ec(const HWIdentifier id) const
Return the position barrel or endcap of a hardware cell identifier: barrel_ec = [0,...
unsigned int nOffsetChannels() const
Number of offset channels - i.e. correction channels.
value_type get_compact() const
Get the compact id.
IMessageSvc * getMessageSvc(bool quiet=false)
bool isFCALchannel(const HWIdentifier id) const
unsigned int minGain() const
Mininum gain value.
IdentifierHash feedthrough_Hash(HWIdentifier feedthroughId) const
Create hash id from feedthrough identifiers.
Helper class for offline supercell identifiers.
virtual bool isHECchannel(const HWIdentifier id) const =0
bool isEMECPS(const HWIdentifier id) const
int pos_neg(const HWIdentifier id) const
Return the side of a hardware cell identifier pos_neg = [0,1] positive-side or negative-side Barrel...
#define CHECK(...)
Evaluate an expression and check for errors.
Helper class for offline cell identifiers.
const LArOnlineID_Base * m_onlineHelper
void setFlag(TrigPassFlags *flags, const T *obj, const CONTAINER *container, const std::vector< bool > &flag)
Set the flag at index position.
const FEBIdVector & febIdVector(unsigned int gain, unsigned int coolChannel) const
Access to a FEB ID vector for a given gain and COOL channel.
HWIdentifier feb_Id(int barrel_ec, int pos_neg, int feedthrough, int slot) const
Create feb_Id from fields.
id_iterator feb_end() const
std::vector< unsigned int > m_channelToMultChanCollIndex
virtual bool isEMECchannel(const HWIdentifier id) const =0
const CaloCell_Base_ID * m_offlineHelper
bool isCalibration(const HWIdentifier id) const
bool isEMBchannel(const HWIdentifier id) const
std::vector< FEBId > FEBIdVector
unsigned int nGains() const
Number of gain values.
int feedthrough(const HWIdentifier id) const
Return the feedthrough of a hardware cell identifier : feedthrough = [0,31] Barrel - A/C side or H/...
std::string show_to_string(Identifier id, const IdContext *context=0, char sep='.') const
or provide the printout in string form
void addFEBIdVector(unsigned int channel, const FEBIdVector &febIdVec)
Add in a FEBIdVector - channel number should be from 0 to NChannelsPerGain-1
bool isEMBPS(const HWIdentifier id) const
This class maps FEB IDs to/from COOL channel ids.
bool isPS(const HWIdentifier id) const
LArCondFEBIdChanMap m_febIdChanMap
This is a "hash" representation of an Identifier. This encodes a 32 bit index which can be used to lo...
bool isEMECinHECchannel(const HWIdentifier id) const
HWIdentifier feedthrough_Id(int barrel_ec, int pos_neg, int feedthrough) const
Create a feedthrough identifier from fields.