Project
Loading...
Searching...
No Matches
NoiseParam.cxx
Go to the documentation of this file.
1
// Copyright 2019-2020 CERN and copyright holders of ALICE O2.
2
// See https://alice-o2.web.cern.ch/copyright for details of the copyright holders.
3
// All rights not expressly granted are reserved.
4
//
5
// This software is distributed under the terms of the GNU General Public
6
// License v3 (GPL Version 3), copied verbatim in the file "COPYING".
7
//
8
// In applying this license CERN does not waive the privileges and immunities
9
// granted to it by virtue of its status as an Intergovernmental Organization
10
// or submit itself to any jurisdiction.
11
12
#include <TH1.h>
13
#include <TFile.h>
14
#include <TDirectory.h>
15
#include "
Framework/Logger.h
"
16
#include "
ZDCReconstruction/NoiseParam.h
"
17
18
using namespace
o2::zdc
;
19
20
void
NoiseParam::setCalib
(uint32_t ich,
float
val
)
21
{
22
if
(ich >=
NChannels
) {
23
LOG
(fatal) << __func__ <<
" channel "
<< ich <<
" not in allowed range"
;
24
return
;
25
}
26
noise
[ich] =
val
;
27
}
28
29
float
NoiseParam::getCalib
(uint32_t ich)
const
30
{
31
if
(ich <
NChannels
) {
32
return
noise
[ich];
33
}
else
{
34
LOG
(fatal) << __func__ <<
" channel "
<< ich <<
" not in allowed range"
;
35
return
0;
36
}
37
}
38
39
void
NoiseParam::print
()
const
40
{
41
for
(Int_t ich = 0; ich <
NChannels
; ich++) {
42
LOG
(info) <<
ChannelNames
[ich] <<
" Noise = "
<<
noise
[ich];
43
}
44
}
Logger.h
NoiseParam.h
Noise calibration data.
val
GLuint GLfloat * val
Definition
glcorearb.h:1582
o2::zdc
Definition
ZDCConstants.h:23
o2::zdc::NChannels
constexpr int NChannels
Definition
Constants.h:65
o2::zdc::ChannelNames
constexpr std::string_view ChannelNames[]
Definition
Constants.h:147
o2::zdc::NoiseParam::getCalib
float getCalib(uint32_t ich) const
Definition
NoiseParam.cxx:29
o2::zdc::NoiseParam::noise
float noise[NChannels]
Definition
NoiseParam.h:30
o2::zdc::NoiseParam::setCalib
void setCalib(uint32_t ich, float val)
Definition
NoiseParam.cxx:20
o2::zdc::NoiseParam::print
void print() const
Definition
NoiseParam.cxx:39
LOG
LOG(info)<< "Compressed in "<< sw.CpuTime()<< " s"
Detectors
ZDC
reconstruction
src
NoiseParam.cxx
Generated on Tue Feb 25 2025 23:16:37 for Project by
1.9.8