ATLAS Offline Software
Public Types | Public Member Functions | Protected Member Functions | Protected Attributes | Private Types | Private Member Functions | Private Attributes | List of all members
LArNoiseComplete Class Reference

This class implements the ILArNoise interface. More...

#include <LArNoiseComplete.h>

Inheritance diagram for LArNoiseComplete:
Collaboration diagram for LArNoiseComplete:

Public Types

typedef LArConditionsContainer< LArNoisePCONTAINER
 
enum  { ERRORCODE = LArElecCalib::ERRORCODE }
 
typedef LArNoiseP LArCondObj
 
typedef unsigned int FebId
 Typedefs for subset. More...
 
typedef LArConditionsSubset< LArNoisePSubset
 
typedef LArConditionsSubset< LArNoiseP >::Traits Traits
 
typedef Subset::ChannelVector ChannelVector
 
typedef Subset::FebPairReference FebPairReference
 
typedef ChannelVector::const_iterator ChannelVectorIterator
 
typedef Subset::size_type size_type
 
typedef Subset::ConstCorrectionVecIt ConstCorrectionIt
 
typedef Subset::Reference Reference
 
typedef Subset::ConstReference ConstReference
 
typedef Subset::Pointer Pointer
 
typedef Subset::ConstPointer ConstPointer
 
typedef LArConditionsContainerDB< LArNoisePConditionsMap
 Typedefs for DB. More...
 
typedef ConditionsMap::const_iterator ConstConditionsMapIterator
 
typedef ConditionsMap::iterator ConditionsMapIterator
 
typedef std::map< unsigned int, ConditionsMapGainMap
 
typedef std::pair< unsigned int, ConditionsMapGainPair
 
typedef GainMap::const_iterator ConstGainMapIterator
 
typedef GainMap::iterator GainMapIterator
 
typedef CondMultChanCollection< SubsetMultChanCollection
 Typedefs for MultChan access. More...
 
typedef MultChanCollection::chan_const_iterator chan_const_iterator
 
typedef MultChanCollection::iov_const_iterator iov_const_iterator
 
typedef MultChanCollection::chan_size_type chan_size_type
 
typedef MultChanCollection::iov_size_type iov_size_type
 

Public Member Functions

 LArNoiseComplete ()
 
virtual ~LArNoiseComplete ()
 
virtual const float & noise (const HWIdentifier &CellID, int gain) const override
 
void set (const HWIdentifier &CellID, int gain, float vNoise)
 
void setPdata (const HWIdentifier id, const LArNoiseP &payload, unsigned int gain=0)
 put payload in persistent data More...
 
ConstReference get (const HWIdentifier id, unsigned int gain=0) const
 get data with online identifier More...
 
Reference get (const HWIdentifier id, unsigned int gain=0)
 non-const get data with online identifier More...
 
unsigned int coolChannel (const HWIdentifier id, unsigned int gain=0) const
 Return the COOL channel number for a given online id and gain. More...
 
unsigned int groupingType () const
 Type of grouping - defined in LArConditionContainerBase.h. More...
 
std::string groupingTypeToString () const
 Type of grouping - defined in LArConditionContainerBase.h. More...
 
unsigned int groupNumber (unsigned int coolChannel) const
 Return the group number of a COOL channel (0 - correction group, 1-N for FEB ID groups) More...
 
unsigned int nGroups () const
 Number of groups - minimum is 2 (1 correction group, 1 FEB ID group) More...
 
unsigned int minGain () const
 Mininum gain value. More...
 
unsigned int nGains () const
 Number of gain values. More...
 
chan_const_iterator chan_begin () const
 Access to Channel numbers via iterators - from MultChanCollection. More...
 
chan_const_iterator chan_end () const
 
chan_size_type chan_size () const
 number of channels - from MultChanCollection More...
 
iov_const_iterator iov_begin () const
 Access to IOVs via iterators - from MultChanCollection. More...
 
iov_const_iterator iov_end () const
 
iov_size_type iov_size () const
 number of IOVs - from MultChanCollection More...
 
unsigned int conditionsPerChannel (unsigned int coolChannel) const
 Statistics: number of conditions per COOL channel. More...
 
unsigned int conditionsPerGroup (unsigned int group) const
 Statistics: number of conditions per group. More...
 
unsigned int conditionsPerGain (unsigned int gain) const
 Statistics: number of conditions per gain. More...
 
unsigned int totalNumberOfConditions () const
 Statistics: total number of conditions. More...
 
unsigned int totalNumberOfCorrections () const
 Statistics: total number of corrections. More...
 
bool correctionsApplied () const
 Have corrections been applied? More...
 
StatusCode applyCorrections ()
 apply correction set More...
 
StatusCode undoCorrections ()
 undo corrections that have been already applied More...
 
StatusCode insertCorrection (HWIdentifier id, const LArNoiseP &cond, unsigned int gain, bool corrChannel=true)
 access to corrections - More...
 
ConstCorrectionIt undoCorrBegin (unsigned int gain) const
 get iterator over the Undo-Vector for a certain gain More...
 
ConstCorrectionIt undoCorrEnd (unsigned int gain) const
 
ConstConditionsMapIterator begin (unsigned int gain) const
 get iterator for all channels for a gain More...
 
ConditionsMapIterator begin (unsigned int gain)
 
ConstConditionsMapIterator begin (unsigned int gain, const std::vector< FebId > &febIds) const
 get iterator for all channels for a gain, restricted to a list of FebIds More...
 
ConditionsMapIterator begin (unsigned int gain, const std::vector< FebId > &febIds)
 
ConstConditionsMapIterator begin (unsigned int gain, const HWIdentifier &febId) const
 get iterator for all channels for a gain, restricted to one Feb More...
 
ConditionsMapIterator begin (unsigned int gain, const HWIdentifier &febId)
 
ConstConditionsMapIterator end (unsigned int gain) const
 end of all channels for this gain More...
 
ConditionsMapIterator end (unsigned int gain)
 
void removeConditions ()
 Remove conditions leaving the corrections - may be needed to only write out the corrections when both are present. More...
 
void removeConditionsChannel (unsigned int coolChannel)
 Remove the conditions for a specific cool channel - e.g. More...
 
std::vector< unsigned > completeCorrectionChannels ()
 Fill all non-existing Correction Channels with emtpy subsets This is necessary to terminate the IOV of the previous correction. More...
 
virtual StatusCode initialize ()
 Initialization done after creation or read back - derived classes may augment the functionality. More...
 
bool merge (const LArConditionsContainer< LArNoiseP > &other)
 

Protected Member Functions

ConstReference empty () const
 Access to standard empty value. More...
 

Protected Attributes

GainMap m_cached
 Map indexed by gain providing pointers into the data in the CondMultChanCollection. More...
 

Private Types

typedef std::vector< ConstPointerTVector
 
typedef TVector::const_iterator TVectorIterator
 
typedef std::map< unsigned int, TVectorTVectorMap
 
typedef TVectorMap::const_iterator TVectorMapIterator
 
typedef Subset::CorrectionPair CorrectionPair
 
typedef Subset::CorrectionVec CorrectionVector
 
typedef Subset::ConstCorrectionVecIt ConstCorrectionVecIt
 
typedef std::vector< CorrectionVectorCorrectionVectors
 
typedef DataVector< SubsetSubsetDV
 
typedef SubsetDV::const_iterator const_iterator
 
typedef SubsetDV::iterator iterator
 

Private Member Functions

StatusCode updateConditionsMap (FebId id, unsigned int gain, ConditionsMap &conditionsMap)
 Update the ConditionsMap for a new FEB ID. More...
 
void sortSubsets ()
 Sort subsets by channel number. More...
 

Private Attributes

ConstCorrectionIt m_dummyCorrIt
 Dummy iterator (returned if requested for invalid gain) More...
 
CorrectionVectors m_correctionsUndo
 
bool m_correctionsApplied
 
CorrectionVector m_emptyCorrectionVec
 

Detailed Description

This class implements the ILArNoise interface.

Author
W. Lampl, S. Laplace
Version
0-0-1 , 08/01/2004

History:

Definition at line 25 of file LArNoiseComplete.h.

Member Typedef Documentation

◆ chan_const_iterator

Definition at line 95 of file LArConditionsContainer.h.

◆ chan_size_type

Definition at line 97 of file LArConditionsContainer.h.

◆ ChannelVector

Definition at line 74 of file LArConditionsContainer.h.

◆ ChannelVectorIterator

typedef ChannelVector::const_iterator LArConditionsContainer< LArNoiseP >::ChannelVectorIterator
inherited

Definition at line 76 of file LArConditionsContainer.h.

◆ ConditionsMap

Typedefs for DB.

Definition at line 85 of file LArConditionsContainer.h.

◆ ConditionsMapIterator

Definition at line 87 of file LArConditionsContainer.h.

◆ const_iterator

Definition at line 322 of file LArConditionsContainer.h.

◆ ConstConditionsMapIterator

Definition at line 86 of file LArConditionsContainer.h.

◆ ConstCorrectionIt

Definition at line 78 of file LArConditionsContainer.h.

◆ ConstCorrectionVecIt

Definition at line 319 of file LArConditionsContainer.h.

◆ ConstGainMapIterator

typedef GainMap::const_iterator LArConditionsContainer< LArNoiseP >::ConstGainMapIterator
inherited

Definition at line 90 of file LArConditionsContainer.h.

◆ ConstPointer

Definition at line 82 of file LArConditionsContainer.h.

◆ ConstReference

Definition at line 80 of file LArConditionsContainer.h.

◆ CONTAINER

Definition at line 29 of file LArNoiseComplete.h.

◆ CorrectionPair

Definition at line 317 of file LArConditionsContainer.h.

◆ CorrectionVector

Definition at line 318 of file LArConditionsContainer.h.

◆ CorrectionVectors

typedef std::vector<CorrectionVector> LArConditionsContainer< LArNoiseP >::CorrectionVectors
privateinherited

Definition at line 320 of file LArConditionsContainer.h.

◆ FebId

typedef unsigned int LArConditionsContainer< LArNoiseP >::FebId
inherited

Typedefs for subset.

Definition at line 71 of file LArConditionsContainer.h.

◆ FebPairReference

Definition at line 75 of file LArConditionsContainer.h.

◆ GainMap

typedef std::map<unsigned int, ConditionsMap > LArConditionsContainer< LArNoiseP >::GainMap
inherited

Definition at line 88 of file LArConditionsContainer.h.

◆ GainMapIterator

typedef GainMap::iterator LArConditionsContainer< LArNoiseP >::GainMapIterator
inherited

Definition at line 91 of file LArConditionsContainer.h.

◆ GainPair

typedef std::pair<unsigned int, ConditionsMap > LArConditionsContainer< LArNoiseP >::GainPair
inherited

Definition at line 89 of file LArConditionsContainer.h.

◆ iov_const_iterator

Definition at line 96 of file LArConditionsContainer.h.

◆ iov_size_type

Definition at line 98 of file LArConditionsContainer.h.

◆ iterator

Definition at line 323 of file LArConditionsContainer.h.

◆ LArCondObj

Definition at line 69 of file LArConditionsContainer.h.

◆ MultChanCollection

Typedefs for MultChan access.

Definition at line 94 of file LArConditionsContainer.h.

◆ Pointer

Definition at line 81 of file LArConditionsContainer.h.

◆ Reference

Definition at line 79 of file LArConditionsContainer.h.

◆ size_type

Definition at line 77 of file LArConditionsContainer.h.

◆ Subset

Definition at line 72 of file LArConditionsContainer.h.

◆ SubsetDV

Definition at line 321 of file LArConditionsContainer.h.

◆ Traits

Definition at line 73 of file LArConditionsContainer.h.

◆ TVector

typedef std::vector<ConstPointer> LArConditionsContainer< LArNoiseP >::TVector
privateinherited

Definition at line 313 of file LArConditionsContainer.h.

◆ TVectorIterator

typedef TVector::const_iterator LArConditionsContainer< LArNoiseP >::TVectorIterator
privateinherited

Definition at line 314 of file LArConditionsContainer.h.

◆ TVectorMap

typedef std::map<unsigned int, TVector> LArConditionsContainer< LArNoiseP >::TVectorMap
privateinherited

Definition at line 315 of file LArConditionsContainer.h.

◆ TVectorMapIterator

typedef TVectorMap::const_iterator LArConditionsContainer< LArNoiseP >::TVectorMapIterator
privateinherited

Definition at line 316 of file LArConditionsContainer.h.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
inherited
Enumerator
ERRORCODE 

Definition at line 39 of file ILArNoise.h.

Constructor & Destructor Documentation

◆ LArNoiseComplete()

LArNoiseComplete::LArNoiseComplete ( )

Definition at line 7 of file LArNoiseComplete.cxx.

8 {
9 
10 }

◆ ~LArNoiseComplete()

LArNoiseComplete::~LArNoiseComplete ( )
virtual

Definition at line 12 of file LArNoiseComplete.cxx.

12 {}

Member Function Documentation

◆ applyCorrections()

StatusCode LArConditionsContainer< LArNoiseP >::applyCorrections
inherited

apply correction set

◆ begin() [1/6]

ConditionsMapIterator LArConditionsContainer< LArNoiseP >::begin ( unsigned int  gain)
inherited

◆ begin() [2/6]

ConstConditionsMapIterator LArConditionsContainer< LArNoiseP >::begin ( unsigned int  gain) const
inherited

get iterator for all channels for a gain

◆ begin() [3/6]

ConditionsMapIterator LArConditionsContainer< LArNoiseP >::begin ( unsigned int  gain,
const HWIdentifier febId 
)
inherited

◆ begin() [4/6]

ConstConditionsMapIterator LArConditionsContainer< LArNoiseP >::begin ( unsigned int  gain,
const HWIdentifier febId 
) const
inherited

get iterator for all channels for a gain, restricted to one Feb

◆ begin() [5/6]

ConditionsMapIterator LArConditionsContainer< LArNoiseP >::begin ( unsigned int  gain,
const std::vector< FebId > &  febIds 
)
inherited

◆ begin() [6/6]

ConstConditionsMapIterator LArConditionsContainer< LArNoiseP >::begin ( unsigned int  gain,
const std::vector< FebId > &  febIds 
) const
inherited

get iterator for all channels for a gain, restricted to a list of FebIds

◆ chan_begin()

Access to Channel numbers via iterators - from MultChanCollection.

◆ chan_end()

◆ chan_size()

number of channels - from MultChanCollection

◆ completeCorrectionChannels()

std::vector<unsigned> LArConditionsContainer< LArNoiseP >::completeCorrectionChannels
inherited

Fill all non-existing Correction Channels with emtpy subsets This is necessary to terminate the IOV of the previous correction.

◆ conditionsPerChannel()

unsigned int LArConditionsContainer< LArNoiseP >::conditionsPerChannel ( unsigned int  coolChannel) const
inherited

Statistics: number of conditions per COOL channel.

◆ conditionsPerGain()

unsigned int LArConditionsContainer< LArNoiseP >::conditionsPerGain ( unsigned int  gain) const
inherited

Statistics: number of conditions per gain.

◆ conditionsPerGroup()

unsigned int LArConditionsContainer< LArNoiseP >::conditionsPerGroup ( unsigned int  group) const
inherited

Statistics: number of conditions per group.

◆ coolChannel()

unsigned int LArConditionsContainer< LArNoiseP >::coolChannel ( const HWIdentifier  id,
unsigned int  gain = 0 
) const
inherited

Return the COOL channel number for a given online id and gain.

◆ correctionsApplied()

bool LArConditionsContainer< LArNoiseP >::correctionsApplied
inherited

Have corrections been applied?

◆ empty()

ConstReference LArConditionsContainer< LArNoiseP >::empty
protectedinherited

Access to standard empty value.

◆ end() [1/2]

ConditionsMapIterator LArConditionsContainer< LArNoiseP >::end ( unsigned int  gain)
inherited

◆ end() [2/2]

ConstConditionsMapIterator LArConditionsContainer< LArNoiseP >::end ( unsigned int  gain) const
inherited

end of all channels for this gain

◆ get() [1/2]

Reference LArConditionsContainer< LArNoiseP >::get ( const HWIdentifier  id,
unsigned int  gain = 0 
)
inherited

non-const get data with online identifier

◆ get() [2/2]

ConstReference LArConditionsContainer< LArNoiseP >::get ( const HWIdentifier  id,
unsigned int  gain = 0 
) const
inherited

get data with online identifier

◆ groupingType()

unsigned int LArConditionsContainer< LArNoiseP >::groupingType
inherited

Type of grouping - defined in LArConditionContainerBase.h.

◆ groupingTypeToString()

std::string LArConditionsContainer< LArNoiseP >::groupingTypeToString
inherited

Type of grouping - defined in LArConditionContainerBase.h.

◆ groupNumber()

unsigned int LArConditionsContainer< LArNoiseP >::groupNumber ( unsigned int  coolChannel) const
inherited

Return the group number of a COOL channel (0 - correction group, 1-N for FEB ID groups)

◆ initialize()

virtual StatusCode LArConditionsContainer< LArNoiseP >::initialize
virtualinherited

Initialization done after creation or read back - derived classes may augment the functionality.

Reimplemented in LArNoiseMC.

◆ insertCorrection()

StatusCode LArConditionsContainer< LArNoiseP >::insertCorrection ( HWIdentifier  id,
const LArNoiseP cond,
unsigned int  gain,
bool  corrChannel = true 
)
inherited

access to corrections -

Insert a new channel id / T pair. If new channel id is the same as an existing one, the new T replaces the old T

◆ iov_begin()

Access to IOVs via iterators - from MultChanCollection.

◆ iov_end()

◆ iov_size()

number of IOVs - from MultChanCollection

◆ merge()

bool LArConditionsContainer< LArNoiseP >::merge ( const LArConditionsContainer< LArNoiseP > &  other)
inherited

◆ minGain()

unsigned int LArConditionsContainer< LArNoiseP >::minGain
inherited

Mininum gain value.

◆ nGains()

unsigned int LArConditionsContainer< LArNoiseP >::nGains
inherited

Number of gain values.

◆ nGroups()

unsigned int LArConditionsContainer< LArNoiseP >::nGroups
inherited

Number of groups - minimum is 2 (1 correction group, 1 FEB ID group)

◆ noise()

const float & LArNoiseComplete::noise ( const HWIdentifier CellID,
int  gain 
) const
overridevirtual

Implements ILArNoise.

Reimplemented in LArNoiseMC.

Definition at line 26 of file LArNoiseComplete.cxx.

26  {
27  const LArNoiseP& t = get(CellID, gain);
28  return (t.m_Noise);
29 }

◆ removeConditions()

void LArConditionsContainer< LArNoiseP >::removeConditions
inherited

Remove conditions leaving the corrections - may be needed to only write out the corrections when both are present.

◆ removeConditionsChannel()

void LArConditionsContainer< LArNoiseP >::removeConditionsChannel ( unsigned int  coolChannel)
inherited

Remove the conditions for a specific cool channel - e.g.

in order not to write it out

◆ set()

void LArNoiseComplete::set ( const HWIdentifier CellID,
int  gain,
float  vNoise 
)

Definition at line 16 of file LArNoiseComplete.cxx.

16  {
17 
18  LArNoiseP t ;
19  t.m_Noise = Noise;
20  setPdata(CellID, t, gain);
21 
22 }

◆ setPdata()

void LArConditionsContainer< LArNoiseP >::setPdata ( const HWIdentifier  id,
const LArNoiseP payload,
unsigned int  gain = 0 
)
inherited

put payload in persistent data

◆ sortSubsets()

void LArConditionsContainer< LArNoiseP >::sortSubsets
privateinherited

Sort subsets by channel number.

◆ totalNumberOfConditions()

unsigned int LArConditionsContainer< LArNoiseP >::totalNumberOfConditions
inherited

Statistics: total number of conditions.

◆ totalNumberOfCorrections()

unsigned int LArConditionsContainer< LArNoiseP >::totalNumberOfCorrections
inherited

Statistics: total number of corrections.

◆ undoCorrBegin()

ConstCorrectionIt LArConditionsContainer< LArNoiseP >::undoCorrBegin ( unsigned int  gain) const
inherited

get iterator over the Undo-Vector for a certain gain

◆ undoCorrections()

StatusCode LArConditionsContainer< LArNoiseP >::undoCorrections
inherited

undo corrections that have been already applied

◆ undoCorrEnd()

ConstCorrectionIt LArConditionsContainer< LArNoiseP >::undoCorrEnd ( unsigned int  gain) const
inherited

◆ updateConditionsMap()

StatusCode LArConditionsContainer< LArNoiseP >::updateConditionsMap ( FebId  id,
unsigned int  gain,
ConditionsMap conditionsMap 
)
privateinherited

Update the ConditionsMap for a new FEB ID.

Member Data Documentation

◆ m_cached

GainMap LArConditionsContainer< LArNoiseP >::m_cached
protectedinherited

Map indexed by gain providing pointers into the data in the CondMultChanCollection.


Definition at line 286 of file LArConditionsContainer.h.

◆ m_correctionsApplied

bool LArConditionsContainer< LArNoiseP >::m_correctionsApplied
privateinherited

Definition at line 327 of file LArConditionsContainer.h.

◆ m_correctionsUndo

CorrectionVectors LArConditionsContainer< LArNoiseP >::m_correctionsUndo
privateinherited

Definition at line 326 of file LArConditionsContainer.h.

◆ m_dummyCorrIt

ConstCorrectionIt LArConditionsContainer< LArNoiseP >::m_dummyCorrIt
privateinherited

Dummy iterator (returned if requested for invalid gain)

Definition at line 291 of file LArConditionsContainer.h.

◆ m_emptyCorrectionVec

CorrectionVector LArConditionsContainer< LArNoiseP >::m_emptyCorrectionVec
privateinherited

Definition at line 328 of file LArConditionsContainer.h.


The documentation for this class was generated from the following files:
LArConditionsContainer< LArNoiseP >::setPdata
void setPdata(const HWIdentifier id, const LArNoiseP &payload, unsigned int gain=0)
put payload in persistent data
CaloCondBlobAlgs_fillNoiseFromASCII.gain
gain
Definition: CaloCondBlobAlgs_fillNoiseFromASCII.py:110
read_hist_ntuple.t
t
Definition: read_hist_ntuple.py:5
LArConditionsContainer< LArNoiseP >::get
ConstReference get(const HWIdentifier id, unsigned int gain=0) const
get data with online identifier
LArNoiseP
Definition: LArNoiseP.h:12
ILArNoise::ERRORCODE
@ ERRORCODE
Definition: ILArNoise.h:39
LArElecCalib::ERRORCODE
@ ERRORCODE
Definition: LArCalibErrorCode.h:17