コード例 #1
0
ファイル: Sample.py プロジェクト: mzarucki/RootTools
 def combineWithSampleWeight(self, weightString):
     if weightString is None: return self.weightString
     if not type(weightString)==type(""): raise ValueError( "Need 'None' or string for weightString, got %s" % weightString )
     if self.__weightStrings:
         logger.debug("For Sample %s: Combining weightString %s with sample weightString %s", \
             self.name, weightString, self.weightString )
         return helpers.combineStrings( [weightString]+self.__weightStrings, stringOperator = "*")
     else:
         logger.debug("For Sample %s: Return weightString %s because sample has no weightString", \
             self.name, weightString )
         return weightString
コード例 #2
0
ファイル: Sample.py プロジェクト: GhentAnalysis/RootTools
 def combineWithSampleWeight(self, weightString):
     if weightString is None: return self.weightString
     if not type(weightString)==type(""): raise ValueError( "Need 'None' or string for weightString, got %s" % weightString )
     if self.__weightStrings:
         logger.debug("For Sample %s: Combining weightString %s with sample weightString %s", \
             self.name, weightString, self.weightString )
         return helpers.combineStrings( [weightString]+self.__weightStrings, stringOperator = "*")
     else:
         logger.debug("For Sample %s: Return weightString %s because sample has no weightString", \
             self.name, weightString )
         return weightString
コード例 #3
0
ファイル: Sample.py プロジェクト: mzarucki/RootTools
 def combineWithSampleSelection(self, selectionString):
     if selectionString is None: return self.selectionString
     if not type(selectionString)==type(""): raise ValueError( "Need 'None' or string for selectionString, got %s" % selectionString )
     if self.__selectionStrings:
         logger.debug("For Sample %s: Combining selectionString %s with sample selectionString %s", \
             self.name, selectionString, self.selectionString )
         return helpers.combineStrings( [selectionString]+self.__selectionStrings, stringOperator = "&&")
     else:
         logger.debug("For Sample %s: Return selectionString %s because sample has no selectionString", \
             self.name, selectionString )
         return selectionString
コード例 #4
0
ファイル: Sample.py プロジェクト: GhentAnalysis/RootTools
 def combineWithSampleSelection(self, selectionString):
     if selectionString is None: return self.selectionString
     if not type(selectionString)==type(""): raise ValueError( "Need 'None' or string for selectionString, got %s" % selectionString )
     if self.__selectionStrings:
         logger.debug("For Sample %s: Combining selectionString %s with sample selectionString %s", \
             self.name, selectionString, self.selectionString )
         return helpers.combineStrings( [selectionString]+self.__selectionStrings, stringOperator = "&&")
     else:
         logger.debug("For Sample %s: Return selectionString %s because sample has no selectionString", \
             self.name, selectionString )
         return selectionString
コード例 #5
0
ファイル: Sample.py プロジェクト: mzarucki/RootTools
 def weightString(self):
     return self.__weightStrings if type(self.__weightStrings)==type("") else helpers.combineStrings(self.__weightStrings, stringOperator = "*") 
コード例 #6
0
ファイル: Sample.py プロジェクト: mzarucki/RootTools
 def selectionString(self):
     return self.__selectionStrings if type(self.__selectionStrings)==type("") else helpers.combineStrings(self.__selectionStrings, stringOperator = "&&") 
コード例 #7
0
ファイル: Sample.py プロジェクト: GhentAnalysis/RootTools
 def weightString(self):
     return self.__weightStrings if type(self.__weightStrings)==type("") else helpers.combineStrings(self.__weightStrings, stringOperator = "*") 
コード例 #8
0
ファイル: Sample.py プロジェクト: GhentAnalysis/RootTools
 def selectionString(self):
     return self.__selectionStrings if type(self.__selectionStrings)==type("") else helpers.combineStrings(self.__selectionStrings, stringOperator = "&&")