149 def getTree(self, drawer=None, var=None,lastOnly=False,firstAndLast=False):
152 varList = self.parseVarExpression(self.varExp+
" "+self.cutExp)
156 t = self.dataGrabber.getDCSTree(self.iovBeg, self.iovEnd, self.drawer.
split(
","), varList, lastOnly, firstAndLast)
159 t = self.dataGrabber.getDCSTree(self.iovBeg, self.iovEnd, drl, varList, lastOnly, firstAndLast)
163 t = self.dataGrabber.getDCSTree(self.iovBeg, self.iovEnd, drl, varl, lastOnly, firstAndLast)
165 if t.GetEntries()==0:
166 print (
"ERROR: No data in time interval!")
169 print (
"Found number of entries: ", t.GetEntries())
172 if self.cmd!=
"tree" and drawer
is None and var
is None:
174 if "," in self.drawer:
177 if var
in self.cutExp:
181 for dr
in self.drawer.
split(
","):
182 newvar += dr+
"."+var+
","
184 newcut += dr+
"."+cut+
","
185 self.varExp = self.varExp.
replace(var,newvar[:-1])
187 self.cutExp = newcut[:-1]
188 self.varExp = self.varExp.
replace(
"Set."+newvar[:-1],
"Set."+var)
189 if cut
and "Set." in cut
and "Set." not in var:
192 self.varExp = self.varExp.
replace(var,self.drawer+
"."+var)
193 self.cutExp = self.cutExp.
replace(var,self.drawer+
"."+var)
194 self.varExp = self.varExp.
replace(self.drawer+
"."+self.drawer,self.drawer)
195 self.cutExp = self.cutExp.
replace(self.drawer+
"."+self.drawer,self.drawer)
196 self.varExp = self.varExp.
replace(
"Set."+self.drawer,
"Set")
197 self.cutExp = self.cutExp.
replace(
"Set."+self.drawer,
"Set")
198 if "ALL_LVPS_AI" in self.varExp:
200 for dr
in self.drawer.
split(
","):
201 for var
in list(self.info.vars_LVPS_AI.keys()):
202 newvar += dr+
"."+var+
","
203 self.varExp = self.varExp.
replace(
"ALL_LVPS_AI",newvar[:-1])
205 if "ALL_LVPS_STATES" in self.varExp:
207 for dr
in self.drawer.
split(
","):
208 for var
in list(self.info.vars_LVPS_STATES.keys()):
209 newvar += dr+
"."+var+
","
210 self.varExp = self.varExp.
replace(
"ALL_LVPS_STATES",newvar[:-1])
212 if "ALL_HV-ALL_SETHV" in self.varExp
or "ALL_HV-ALL_HVSET" in self.varExp:
214 for dr
in self.drawer.
split(
","):
215 for var
in list(self.info.vars_HVSET.keys()):
216 if not (
"Set.vFix" in var
or "Set.hvIn" in var
or "Set.volt" in var
or "Set.temp" in var):
217 newvar += dr+
"."+var.replace(
"Set.",
"")+
"-"+dr+
"."+var+
","
218 self.varExp = self.varExp.
replace(
"ALL_HV-ALL_SETHV",newvar[:-1])
219 self.varExp = self.varExp.
replace(
"ALL_HV-ALL_HVSET",newvar[:-1])
220 if "ALL_HVSET" in self.varExp
or "ALL_SETHV" in self.varExp:
222 for dr
in self.drawer.
split(
","):
223 for var
in list(self.info.vars_HVSET.keys()):
224 if not self.useCool
or not (
"Set.vFix" in var
or "Set.hvIn" in var
or "Set.volt" in var
or "Set.temp" in var):
225 newvar += dr+
"."+var+
","
226 self.varExp = self.varExp.
replace(
"ALL_HVSET",newvar[:-1])
227 self.varExp = self.varExp.
replace(
"ALL_SETHV",newvar[:-1])
228 if "ALL_HV" in self.varExp
and "ALL_HVSET" not in self.varExp :
230 for dr
in self.drawer.
split(
","):
231 for var
in list(self.info.vars_HV.keys()):
232 if not self.useCool
or not (
"hvIn" in var
or "volt" in var
or "temp" in var):
233 newvar += dr+
"."+var+
","
234 self.varExp = self.varExp.
replace(
"ALL_HV",newvar[:-1])
236 print (
"self.drawer: ", self.drawer)
237 print (
"self.varExp: ", self.varExp)
238 print (
"self.cutExp: ", self.cutExp)