Project
Loading...
Searching...
No Matches
ChamberEfficiencyResponse.h
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
16
17#ifndef O2_MID_CHAMBEREFFICIENCYRESPONSE_H
18#define O2_MID_CHAMBEREFFICIENCYRESPONSE_H
19
20#include <random>
23
24namespace o2
25{
26namespace mid
27{
29{
30 public:
31 ChamberEfficiencyResponse(const ChamberEfficiency& efficiencyMap);
32 virtual ~ChamberEfficiencyResponse() = default;
33
34 bool isEfficient(int deId, int columnId, int line, bool& isEfficientBP, bool& isEfficientNBP);
35
37 void setSeed(unsigned int seed) { mGenerator.seed(seed); }
38
40 void setFromCounters(const std::vector<ChEffCounter>& counters) { mEfficiency.setFromCounters(counters); }
41
42 private:
43 ChamberEfficiency mEfficiency;
44 std::default_random_engine mGenerator;
45 std::uniform_real_distribution<double> mRandom;
46};
47
48ChamberEfficiencyResponse createDefaultChamberEfficiencyResponse();
49
50} // namespace mid
51} // namespace o2
52
53#endif /* O2_MID_CHAMBERRESPONSE_H */
Chamber efficiency counters.
Measured values of the RPC efficiency.
bool isEfficient(int deId, int columnId, int line, bool &isEfficientBP, bool &isEfficientNBP)
void setSeed(unsigned int seed)
Sets the seed.
virtual ~ChamberEfficiencyResponse()=default
void setFromCounters(const std::vector< ChEffCounter > &counters)
Sets the chamber efficiency from the counters.
void setFromCounters(const std::vector< ChEffCounter > &counters)
GLint GLint GLsizei GLuint * counters
Definition glcorearb.h:3985
ChamberEfficiencyResponse createDefaultChamberEfficiencyResponse()
a couple of static helper functions to create timestamp values for CCDB queries or override obsolete ...