Belle II Software  release-08-01-10
ARICHAsicInfo.h
1 /**************************************************************************
2  * basf2 (Belle II Analysis Software Framework) *
3  * Author: The Belle II Collaboration *
4  * *
5  * See git log for contributors and copyright holders. *
6  * This file is licensed under LGPL-3.0, see LICENSE.md. *
7  **************************************************************************/
8 
9 #pragma once
10 #include <vector>
11 #include <string>
12 #include <TObject.h>
13 #include <TTimeStamp.h>
14 #include <TH3F.h>
15 
16 namespace Belle2 {
25  class ARICHAsicInfo: public TObject {
26  public:
32 
36  ARICHAsicInfo(const std::string& id, TTimeStamp timeFinishGain, TTimeStamp timeFinishOffset, std::vector<int>& deadChannel,
37  std::vector<int>& badConnChannel, std::vector<int>& badOffsetChannel, std::vector<int>& badLinChannel, int numProbCh,
38  std::vector<TH3F*>& gain, std::vector<TH3F*>& offset, const std::string& comment): m_id(id), m_timeFinishGain(timeFinishGain),
39  m_timeFinishOffset(timeFinishOffset), m_deadChannel(deadChannel), m_badConnChannel(badConnChannel),
40  m_badOffsetChannel(badOffsetChannel), m_badLinChannel(badLinChannel), m_numProblematicChannels(numProbCh), m_gain(gain),
41  m_offset(offset), m_comment(comment) {};
42 
47 
51  std::string getAsicID() const {return m_id; }
52 
56  void setAsicID(const std::string& id) {m_id = id; }
57 
61  TTimeStamp getTimeFinishGain() const {return m_timeFinishGain; }
62 
66  void setTimeFinishGain(TTimeStamp timeFinishGain) {m_timeFinishGain = timeFinishGain; }
67 
71  TTimeStamp getTimeFinishOffset() const {return m_timeFinishOffset; }
72 
76  void setTimeFinishOffset(TTimeStamp timeFinishOffset) {m_timeFinishOffset = timeFinishOffset; }
77 
83  int getDeadChannel(unsigned int i) const;
84 
89  void appendDeadChannel(int channel) {m_deadChannel.push_back(channel); }
90 
95  void setDeadChannels(const std::vector<int>& deadChannels) {m_deadChannel = deadChannels; }
96 
101  int getDeadChannelsSize() const {return m_deadChannel.size();}
102 
108  int getBadConnChannel(unsigned int i) const;
109 
114  void appendBadConnChannel(int ichannel) { m_badConnChannel.push_back(ichannel); }
115 
120  int getBadConnChannelsSize() const {return m_badConnChannel.size();}
121 
126  void setBadConnChannels(const std::vector<int>& badConnChannels) {m_badConnChannel = badConnChannels; }
127 
133  int getBadOffsetChannel(unsigned int i) const;
134 
139  void appendBadOffsetChannel(int ichannel) { m_badOffsetChannel.push_back(ichannel); }
140 
145  int getBadOffsetChannelsSize() const {return m_badOffsetChannel.size();}
146 
151  void setBadOffsetChannels(const std::vector<int>& badOffsetChannels) {m_badOffsetChannel = badOffsetChannels; }
152 
158  int getBadLinChannel(unsigned int i) const;
159 
164  void appendBadLinChannel(int ichannel) { m_badLinChannel.push_back(ichannel); }
165 
170  int getBadLinChannelsSize() const {return m_badLinChannel.size();}
171 
176  void setBadLinChannels(const std::vector<int>& badLinChannels) {m_badLinChannel = badLinChannels; }
177 
182 
186  void setNumOfProblematicChannels(int numProbCh) {m_numProblematicChannels = numProbCh; }
187 
192  TH3F* getGainMeasurement(unsigned int i) const;
193 
198  void setGainMeasurement(std::vector<TH3F*> gain);
203  TH3F* getOffsetMeasurement(unsigned int i) const;
204 
209  void setOffsetMeasurement(std::vector<TH3F*> offset);
210 
214  std::string getComment() const {return m_comment; }
215 
219  void setComment(const std::string& comment) {m_comment = comment; }
220 
221 
222  private:
223  std::string m_id;
224  TTimeStamp m_timeFinishGain;
225  TTimeStamp m_timeFinishOffset;
226  std::vector<int> m_deadChannel;
227  std::vector<int> m_badConnChannel;
228  std::vector<int> m_badOffsetChannel;
229  std::vector<int> m_badLinChannel;
231  std::vector<TH3F*> m_gain;
232  std::vector<TH3F*> m_offset;
233  std::string m_comment;
236  };
238 } // end namespace Belle2
239 
Tested ASIC chips.
Definition: ARICHAsicInfo.h:25
void setBadLinChannels(const std::vector< int > &badLinChannels)
Set vector of bad linearity channel numbers.
std::string m_comment
Comment.
TH3F * getOffsetMeasurement(unsigned int i) const
Return Measurements with different offset settings.
std::vector< TH3F * > m_gain
Threshold scans with different gain settings.
void setNumOfProblematicChannels(int numProbCh)
Set number of problematic channels.
int getBadConnChannelsSize() const
Return size of the list of channels with bad connections.
std::string getComment() const
Return Commment.
std::vector< int > m_deadChannel
List of dead channels on the ASIC chip.
void appendBadLinChannel(int ichannel)
Add a channel number to the list of channels with bad linearity.
std::vector< int > m_badConnChannel
List of channels with bad connections during the measurement.
void setBadOffsetChannels(const std::vector< int > &badOffsetChannels)
Set vector of bad offset channel numbers.
void appendBadConnChannel(int ichannel)
Add a channel number to the list of channels with bad connections.
void setGainMeasurement(std::vector< TH3F * > gain)
set Measurements with different gain settings
int getBadLinChannel(unsigned int i) const
Return a channel number from the list of channels with bad linearity.
int getBadOffsetChannel(unsigned int i) const
Return a channel number from the list of channels with bad offset adjustment.
std::string m_id
Asic Identifier.
int getDeadChannelsSize() const
Return size of the list of dead channels.
void appendBadOffsetChannel(int ichannel)
Add a channel number to the list of channels with bad offset adjustment.
void setTimeFinishOffset(TTimeStamp timeFinishOffset)
Set Test date offset - finish.
Definition: ARICHAsicInfo.h:76
TTimeStamp getTimeFinishGain() const
Return Test date gain - finish.
Definition: ARICHAsicInfo.h:61
ClassDef(ARICHAsicInfo, 3)
ClassDef.
void setBadConnChannels(const std::vector< int > &badConnChannels)
Set vector of bad connection channel numbers.
TTimeStamp m_timeFinishGain
Test Date of gain measurements - finish.
float getNumOfProblematicChannels() const
Return number of problematic channels.
int getBadOffsetChannelsSize() const
Return size of the list of channels with bad offset adjustment.
void setTimeFinishGain(TTimeStamp timeFinishGain)
Set Test date gain - finish.
Definition: ARICHAsicInfo.h:66
void setOffsetMeasurement(std::vector< TH3F * > offset)
set Measurements with different offset settings
ARICHAsicInfo(const std::string &id, TTimeStamp timeFinishGain, TTimeStamp timeFinishOffset, std::vector< int > &deadChannel, std::vector< int > &badConnChannel, std::vector< int > &badOffsetChannel, std::vector< int > &badLinChannel, int numProbCh, std::vector< TH3F * > &gain, std::vector< TH3F * > &offset, const std::string &comment)
Constructor.
Definition: ARICHAsicInfo.h:36
int getBadConnChannel(unsigned int i) const
Return a channel number from the list of channels with bad connections.
void setDeadChannels(const std::vector< int > &deadChannels)
Set vector of dead channel numbers.
Definition: ARICHAsicInfo.h:95
~ARICHAsicInfo()
Destructor.
Definition: ARICHAsicInfo.h:46
TTimeStamp getTimeFinishOffset() const
Return Test date offset - finish.
Definition: ARICHAsicInfo.h:71
ARICHAsicInfo()
Default constructor.
Definition: ARICHAsicInfo.h:30
std::string getAsicID() const
Return Asic Identifier.
Definition: ARICHAsicInfo.h:51
void appendDeadChannel(int channel)
Add a channel number to the list of dead channels.
Definition: ARICHAsicInfo.h:89
int getDeadChannel(unsigned int i) const
Return a channel number from the list of dead channels.
TTimeStamp m_timeFinishOffset
Test Date of offset measurements - finish.
void setAsicID(const std::string &id)
Set Asic Identifier.
Definition: ARICHAsicInfo.h:56
int getBadLinChannelsSize() const
Return size of the list of channels with bad linearity.
void setComment(const std::string &comment)
Set comment.
TH3F * getGainMeasurement(unsigned int i) const
Return Measurements with different gain settings.
int m_numProblematicChannels
Number of channels with problems.
std::vector< int > m_badLinChannel
List of channels with bad linearity.
std::vector< TH3F * > m_offset
Threshold scans with different offset settings (course & fine offset)
std::vector< int > m_badOffsetChannel
List of channels with bad offset adjustment.
Abstract base class for different kinds of events.