]>
Commit | Line | Data |
---|---|---|
1 | #ifndef ALIFMDCALIBPEDESTAL_H | |
2 | #define ALIFMDCALIBPEDESTAL_H | |
3 | /* Copyright(c) 1998-2000, ALICE Experiment at CERN, All rights | |
4 | * reserved. | |
5 | * | |
6 | * See cxx source for full Copyright notice | |
7 | */ | |
8 | //____________________________________________________________________ | |
9 | // | |
10 | // This class stores a pedestal and pedestal width for each strip in | |
11 | // the FMD detectors. | |
12 | // The values are stored as floats, since they may be results from a | |
13 | // fit. | |
14 | // Need to make algorithm that makes this data | |
15 | /** @file AliFMDCalibPedestal.h | |
16 | @author Christian Holm Christensen <cholm@nbi.dk> | |
17 | @date Sun Mar 26 18:30:51 2006 | |
18 | @brief Per strip pedestal calibration | |
19 | @ingroup FMD_base | |
20 | */ | |
21 | #ifndef ALIFMDFLOATMAP_H | |
22 | # include <AliFMDFloatMap.h> | |
23 | #endif | |
24 | #include <iosfwd> | |
25 | class AliFMDBoolMap; | |
26 | ||
27 | //____________________________________________________________________ | |
28 | /** @brief Pedestal value and width for each strip in the FMD | |
29 | @ingroup FMD_base | |
30 | */ | |
31 | class AliFMDCalibPedestal : public TObject | |
32 | { | |
33 | public: | |
34 | /** CTOR */ | |
35 | AliFMDCalibPedestal(); | |
36 | /** DTOR */ | |
37 | ~AliFMDCalibPedestal() {} | |
38 | /** | |
39 | * Copy ctor | |
40 | * | |
41 | * @param o Object to copy from | |
42 | */ | |
43 | AliFMDCalibPedestal(const AliFMDCalibPedestal& o); | |
44 | /** | |
45 | * Assignment | |
46 | * | |
47 | * @param o Object to assign from | |
48 | * @return Reference to this object | |
49 | */ | |
50 | AliFMDCalibPedestal& operator=(const AliFMDCalibPedestal& o); | |
51 | /** | |
52 | * Set the values for a strip. | |
53 | * | |
54 | * @param det Detector | |
55 | * @param ring Ring | |
56 | * @param sec Sector | |
57 | * @param str Strip | |
58 | * @param ped Value of pedestal | |
59 | * @param pedW Width of pedestal | |
60 | */ | |
61 | void Set(UShort_t det, Char_t ring, UShort_t sec, UShort_t str, | |
62 | Float_t ped, Float_t pedW); | |
63 | /** | |
64 | * Get pedestal for a strip. | |
65 | * | |
66 | * @param det Detector | |
67 | * @param ring Ring | |
68 | * @param sec Sector | |
69 | * @param str Strip | |
70 | * @return Pedestal for strip | |
71 | */ | |
72 | Float_t Value(UShort_t det, Char_t ring, UShort_t sec, UShort_t str); | |
73 | /** Get pedestal width for a strip. | |
74 | @param det Detector | |
75 | @param ring Ring | |
76 | @param sec Sector | |
77 | @param str Strip | |
78 | @return Pedestal width for strip */ | |
79 | Float_t Width(UShort_t det, Char_t ring, UShort_t sec, UShort_t str); | |
80 | ||
81 | /** | |
82 | * Read information from file and set values | |
83 | * | |
84 | * @param inFile inputFile | |
85 | */ | |
86 | Bool_t ReadFromFile(std::istream & inFile); | |
87 | /** | |
88 | * Make a dead map based on the noise of the channels. If the noise | |
89 | * of a paraticular channel is larger than @a maxW, then the channel | |
90 | * is marked as dead. | |
91 | * | |
92 | * If the argument @a dead is non-null, then the map passed is | |
93 | * modified. That is, channels marked as dead in the map will | |
94 | * remain marked. Channels that meat the criterion (noise larger | |
95 | * than @a maxW) will in addition be marked as dead. | |
96 | * | |
97 | * If the argument @a dead is null, then a new map is created and a | |
98 | * pointer to this will be returned. | |
99 | * | |
100 | * @param maxW Maximum value of noise for a channel before it is | |
101 | * marked as dead. | |
102 | * @param dead If non-null, then modify this map. | |
103 | * | |
104 | * @return A pointer to possibly newly allocated dead map. | |
105 | */ | |
106 | AliFMDBoolMap* MakeDeadMap(Float_t maxW, AliFMDBoolMap* dead=0) const; | |
107 | ||
108 | const AliFMDFloatMap& Values() const { return fValue; } | |
109 | const AliFMDFloatMap& Widths() const { return fWidth; } | |
110 | private: | |
111 | AliFMDFloatMap fValue; /** Pedestal */ | |
112 | AliFMDFloatMap fWidth; /** Pedestal width */ | |
113 | ClassDef(AliFMDCalibPedestal, 1) // Pedestal data for the FMD | |
114 | }; | |
115 | ||
116 | ||
117 | #endif | |
118 | //____________________________________________________________________ | |
119 | // | |
120 | // Local Variables: | |
121 | // mode: C++ | |
122 | // End: | |
123 | // | |
124 | ||
125 |