diff --git a/calibrationSuite/psanaBase.py b/calibrationSuite/psanaBase.py index 3bd2bcd..18fb09d 100755 --- a/calibrationSuite/psanaBase.py +++ b/calibrationSuite/psanaBase.py @@ -73,11 +73,11 @@ def setupPsana(self): def get_ds(self, run=None): if run is None: run = self.run - if psanaBaseNum == 1: - return DataSource("exp=%s:run=%d:smd" % (self.exp, run)) - else: + if psanaBaseNum == 2: return DataSource(exp=self.exp, run=run, intg_det=self.experimentHash['detectorType'], max_events=self.maxNevents) - + else: + return DataSource("exp=%s:run=%d:smd" % (self.exp, run)) + def isKicked(self, evt): if psanaBaseNum == 2: allcodes = self.getEventCodes(evt) @@ -93,9 +93,9 @@ def getFlux(self, evt): def getEvt(self): if psanaBaseNum == 2: - return self.getEvtPsana2 + return self.getEvtPsana2() else: - return self.getEvtPsana1 + return self.getEvtPsana1() def getStepGen(self): if psanaBaseNum == 2: @@ -120,6 +120,7 @@ def getScanValue(self, step=-1, useStringInfo=False): # for psana1, where we don't specify a step arg if step == -1: #psana1 return self.controlData().pvControls()[0].value() + ##print(self.step_value(step),self.step_docstring(step),useStringInfo) if useStringInfo: payload = self.step_docstring(step) diff --git a/calibrationSuite/suiteBase.py b/calibrationSuite/suiteBase.py index 28adc0e..d8e7401 100644 --- a/calibrationSuite/suiteBase.py +++ b/calibrationSuite/suiteBase.py @@ -132,7 +132,8 @@ def setupValuesFromArgs(self): self.location = self.args.location self.maxNevents = self.args.maxNevents self.skipNevents = self.args.skipNevents - self.path = self.args.path + if self.outputDir == None: + self.outputDir = self.args.path # if set, output folders will be relative to OUTPUT_ROOT # if not, they will be relative to the current script file