]>
Commit | Line | Data |
---|---|---|
54c3cb53 | 1 | /************************************************************************** |
2 | * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * | |
3 | * * | |
4 | * Author: The ALICE Off-line Project. * | |
5 | * Contributors are mentioned in the code where appropriate. * | |
6 | * * | |
7 | * Permission to use, copy, modify and distribute this software and its * | |
8 | * documentation strictly for non-commercial purposes is hereby granted * | |
9 | * without fee, provided that the above copyright notice appears in all * | |
10 | * copies and that both the copyright notice and this permission notice * | |
11 | * appear in the supporting documentation. The authors make no claims * | |
12 | * about the suitability of this software for any purpose. It is * | |
13 | * provided "as is" without express or implied warranty. * | |
14 | **************************************************************************/ | |
15 | ||
16 | /* $Id: AliTRDCalDCS.cxx 18952 2007-06-08 11:36:12Z cblume $ */ | |
17 | ||
18 | /////////////////////////////////////////////////////////////////////////////// | |
19 | // // | |
20 | // TRD calibration class for TRD DCS parameters // | |
21 | // // | |
22 | /////////////////////////////////////////////////////////////////////////////// | |
23 | ||
24 | #include "AliTRDCalDCS.h" | |
1b2ec594 | 25 | #include "AliTRDCalDCSFEE.h" |
3821ce70 | 26 | #include "AliTRDCalDCSGTU.h" |
54c3cb53 | 27 | |
28 | ClassImp(AliTRDCalDCS) | |
1b2ec594 | 29 | |
54c3cb53 | 30 | //_____________________________________________________________________________ |
31 | AliTRDCalDCS::AliTRDCalDCS() | |
32 | :TNamed() | |
1b2ec594 | 33 | ,fGNumberOfTimeBins(-1) |
34 | ,fGConfigTag(-1) | |
35 | ,fGSingleHitThres(-1) | |
36 | ,fGThreePadClustThres(-1) | |
37 | ,fGSelNoZS(-1) | |
38 | ,fGTCFilterWeight(-1) | |
39 | ,fGTCFilterShortDecPar(-1) | |
40 | ,fGTCFilterLongDecPar(-1) | |
41 | ,fGFastStatNoise(-1) | |
42 | ,fGConfigVersion(0) | |
43 | ,fGConfigName(0) | |
44 | ,fGFilterType(0) | |
45 | ,fGReadoutParam(0) | |
46 | ,fGTestPattern(0) | |
47 | ,fGTrackletMode(0) | |
48 | ,fGTrackletDef(0) | |
49 | ,fGTriggerSetup(0) | |
50 | ,fGAddOptions(0) | |
8f7e6c0b | 51 | ,fRunType("") |
52 | ,fStartTime(0) | |
53 | ,fEndTime(0) | |
67abca5c | 54 | ,fFEEArr(0) |
55 | ,fPTRArr(0) | |
56 | ,fGTUObj(0) | |
54c3cb53 | 57 | { |
58 | // | |
59 | // AliTRDCalDCS default constructor | |
60 | // | |
67abca5c | 61 | |
54c3cb53 | 62 | } |
63 | ||
64 | //_____________________________________________________________________________ | |
65 | AliTRDCalDCS::AliTRDCalDCS(const Text_t *name, const Text_t *title) | |
66 | :TNamed(name,title) | |
1b2ec594 | 67 | ,fGNumberOfTimeBins(-1) |
68 | ,fGConfigTag(-1) | |
69 | ,fGSingleHitThres(-1) | |
70 | ,fGThreePadClustThres(-1) | |
71 | ,fGSelNoZS(-1) | |
72 | ,fGTCFilterWeight(-1) | |
73 | ,fGTCFilterShortDecPar(-1) | |
74 | ,fGTCFilterLongDecPar(-1) | |
75 | ,fGFastStatNoise(-1) | |
76 | ,fGConfigVersion(0) | |
77 | ,fGConfigName(0) | |
78 | ,fGFilterType(0) | |
79 | ,fGReadoutParam(0) | |
80 | ,fGTestPattern(0) | |
81 | ,fGTrackletMode(0) | |
82 | ,fGTrackletDef(0) | |
83 | ,fGTriggerSetup(0) | |
84 | ,fGAddOptions(0) | |
8f7e6c0b | 85 | ,fRunType("") |
86 | ,fStartTime(0) | |
87 | ,fEndTime(0) | |
7e563f5e | 88 | ,fFEEArr(new TObjArray(540)) |
89 | ,fPTRArr(new TObjArray(6)) | |
90 | ,fGTUObj(new AliTRDCalDCSGTU()) | |
54c3cb53 | 91 | { |
92 | // | |
93 | // AliTRDCalDCS constructor | |
94 | // | |
67abca5c | 95 | |
54c3cb53 | 96 | } |
97 | ||
98 | //_____________________________________________________________________________ | |
99 | AliTRDCalDCS::AliTRDCalDCS(const AliTRDCalDCS &cd) | |
100 | :TNamed(cd) | |
1b2ec594 | 101 | ,fGNumberOfTimeBins(-1) |
102 | ,fGConfigTag(-1) | |
103 | ,fGSingleHitThres(-1) | |
104 | ,fGThreePadClustThres(-1) | |
105 | ,fGSelNoZS(-1) | |
106 | ,fGTCFilterWeight(-1) | |
107 | ,fGTCFilterShortDecPar(-1) | |
108 | ,fGTCFilterLongDecPar(-1) | |
109 | ,fGFastStatNoise(-1) | |
110 | ,fGConfigVersion(0) | |
111 | ,fGConfigName(0) | |
112 | ,fGFilterType(0) | |
113 | ,fGReadoutParam(0) | |
114 | ,fGTestPattern(0) | |
115 | ,fGTrackletMode(0) | |
116 | ,fGTrackletDef(0) | |
117 | ,fGTriggerSetup(0) | |
118 | ,fGAddOptions(0) | |
8f7e6c0b | 119 | ,fRunType("") |
120 | ,fStartTime(0) | |
121 | ,fEndTime(0) | |
7e563f5e | 122 | ,fFEEArr(new TObjArray(540)) |
123 | ,fPTRArr(new TObjArray(6)) | |
124 | ,fGTUObj(new AliTRDCalDCSGTU()) | |
54c3cb53 | 125 | { |
126 | // | |
127 | // AliTRDCalDCS copy constructor | |
128 | // | |
67abca5c | 129 | |
54c3cb53 | 130 | } |
131 | ||
132 | //_____________________________________________________________________________ | |
133 | AliTRDCalDCS &AliTRDCalDCS::operator=(const AliTRDCalDCS &cd) | |
134 | { | |
135 | // | |
136 | // Assignment operator | |
137 | // | |
138 | if (&cd == this) return *this; | |
139 | ||
140 | new (this) AliTRDCalDCS(cd); | |
141 | return *this; | |
142 | } | |
143 | ||
1b2ec594 | 144 | //_____________________________________________________________________________ |
145 | void AliTRDCalDCS::EvaluateGlobalParameters() | |
146 | { | |
2e32a5ae | 147 | // |
148 | // Do an evaluation of all global parameters | |
149 | // | |
150 | ||
1b2ec594 | 151 | for(Int_t i=0; i<540; i++) { |
152 | AliTRDCalDCSFEE *iDCSFEEObj; | |
153 | iDCSFEEObj = GetCalDCSFEEObj(i); | |
154 | if(iDCSFEEObj != NULL) { | |
155 | if(iDCSFEEObj->GetStatusBit() == 0) { | |
156 | // first, set the parameters of the first good ROC as global | |
157 | fGNumberOfTimeBins = iDCSFEEObj->GetNumberOfTimeBins(); | |
158 | fGConfigTag = iDCSFEEObj->GetConfigTag(); | |
159 | fGSingleHitThres = iDCSFEEObj->GetSingleHitThres(); | |
160 | fGThreePadClustThres = iDCSFEEObj->GetThreePadClustThres(); | |
161 | fGSelNoZS = iDCSFEEObj->GetSelectiveNoZS(); | |
162 | fGTCFilterWeight = iDCSFEEObj->GetTCFilterWeight(); | |
163 | fGTCFilterShortDecPar = iDCSFEEObj->GetTCFilterShortDecPar(); | |
164 | fGTCFilterLongDecPar = iDCSFEEObj->GetTCFilterLongDecPar(); | |
165 | fGFastStatNoise = iDCSFEEObj->GetFastStatNoise(); | |
166 | fGConfigVersion = iDCSFEEObj->GetConfigVersion(); | |
167 | fGConfigName = iDCSFEEObj->GetConfigName(); | |
168 | fGFilterType = iDCSFEEObj->GetFilterType(); | |
169 | fGReadoutParam = iDCSFEEObj->GetReadoutParam(); | |
170 | fGTestPattern = iDCSFEEObj->GetTestPattern(); | |
171 | fGTrackletMode = iDCSFEEObj->GetTrackletMode(); | |
172 | fGTrackletDef = iDCSFEEObj->GetTrackletDef(); | |
173 | fGTriggerSetup = iDCSFEEObj->GetTriggerSetup(); | |
174 | fGAddOptions = iDCSFEEObj->GetAddOptions(); | |
175 | break; | |
176 | } | |
177 | } | |
178 | } | |
179 | ||
180 | for(Int_t i=0; i<540; i++) { | |
181 | AliTRDCalDCSFEE *iDCSFEEObj; | |
182 | iDCSFEEObj = GetCalDCSFEEObj(i); | |
183 | if(iDCSFEEObj != NULL) { | |
184 | if(iDCSFEEObj->GetStatusBit() == 0) { | |
185 | // second, if any of the other good chambers differ, set the global value to -1/"" | |
186 | if(fGNumberOfTimeBins != iDCSFEEObj->GetNumberOfTimeBins()) fGNumberOfTimeBins = -2; | |
187 | if(fGConfigTag != iDCSFEEObj->GetConfigTag()) fGConfigTag = -2; | |
188 | if(fGSingleHitThres != iDCSFEEObj->GetSingleHitThres()) fGSingleHitThres = -2; | |
189 | if(fGThreePadClustThres != iDCSFEEObj->GetThreePadClustThres()) fGThreePadClustThres = -2; | |
190 | if(fGSelNoZS != iDCSFEEObj->GetSelectiveNoZS()) fGSelNoZS = -2; | |
191 | if(fGTCFilterWeight != iDCSFEEObj->GetTCFilterWeight()) fGTCFilterWeight = -2; | |
192 | if(fGTCFilterShortDecPar != iDCSFEEObj->GetTCFilterShortDecPar()) fGTCFilterShortDecPar = -2; | |
193 | if(fGTCFilterLongDecPar != iDCSFEEObj->GetTCFilterLongDecPar()) fGTCFilterLongDecPar = -2; | |
194 | if(fGFastStatNoise != iDCSFEEObj->GetFastStatNoise()) fGFastStatNoise = -2; | |
195 | if(fGConfigVersion != iDCSFEEObj->GetConfigVersion()) fGConfigVersion = "mixed"; | |
196 | if(fGConfigName != iDCSFEEObj->GetConfigName()) fGConfigName = "mixed"; | |
197 | if(fGFilterType != iDCSFEEObj->GetFilterType()) fGFilterType = "mixed"; | |
198 | if(fGReadoutParam != iDCSFEEObj->GetReadoutParam()) fGReadoutParam = "mixed"; | |
199 | if(fGTestPattern != iDCSFEEObj->GetTestPattern()) fGTestPattern = "mixed"; | |
200 | if(fGTrackletMode != iDCSFEEObj->GetTrackletMode()) fGTrackletMode = "mixed"; | |
201 | if(fGTrackletDef != iDCSFEEObj->GetTrackletDef()) fGTrackletDef = "mixed"; | |
202 | if(fGTriggerSetup != iDCSFEEObj->GetTriggerSetup()) fGTriggerSetup = "mixed"; | |
203 | if(fGAddOptions != iDCSFEEObj->GetAddOptions()) fGAddOptions = "mixed"; | |
204 | } | |
205 | } | |
206 | } | |
207 | } | |
208 | ||
8f7e6c0b | 209 |