CMS 3D CMS Logo

List of all members | Public Member Functions | Public Attributes | Static Public Attributes
preexistingValidation.PreexistingValidation Class Reference
Inheritance diagram for preexistingValidation.PreexistingValidation:
genericValidation.GenericValidation genericValidation.ValidationMetaClass preexistingValidation.PreexistingGeometryComparison preexistingValidation.PreexistingMonteCarloValidation preexistingValidation.PreexistingOfflineValidation preexistingValidation.PreexistingPrimaryVertexValidation preexistingValidation.PreexistingTrackSplittingValidation preexistingValidation.PreexistingZMuMuValidation

Public Member Functions

def __init__ (self, valName, config)
 
def createConfiguration (self, *args, **kwargs)
 
def createCrabCfg (self, *args, **kwargs)
 
def createFiles (self, *args, **kwargs)
 
def createScript (self, *args, **kwargs)
 
def filesToCompare (self)
 
def getRepMap (self)
 
- Public Member Functions inherited from genericValidation.GenericValidation
def __init__ (self, valName, alignment, config)
 
def createConfiguration (self, fileContents, path, schedule=None, repMap=None, repMaps=None)
 
def createCrabCfg (self, fileContents, path)
 
def createFiles (self, fileContents, path, repMap=None, repMaps=None)
 
def createScript (self, fileContents, path, downloadFiles=[], repMap=None, repMaps=None)
 
def getCompareStrings (self, requestId=None, plain=False)
 
def getRepMap (self, alignment=None)
 
- Public Member Functions inherited from genericValidation.ValidationMetaClass
def __new__ (cls, clsname, bases, dct)
 

Public Attributes

 config
 
 general
 
 jobid
 
 jobmode
 
 name
 
 needsproxy
 
 originalValName
 
 title
 
- Public Attributes inherited from genericValidation.GenericValidation
 alignmentToValidate
 
 AutoAlternates
 
 cmssw
 
 cmsswreleasebase
 
 config
 
 configFiles
 
 crabConfigFiles
 
 general
 
 jobid
 
 jobmode
 
 name
 
 needsproxy
 
 NJobs
 
 packages
 
 randomWorkdirPart
 
 scramarch
 
 scriptFiles
 

Static Public Attributes

dictionary defaults = {"title": ".oO[name]Oo."}
 
dictionary mandatories = {"file", "color", "style", "originalValName", "eosdirName", "multiIOV"}
 
dictionary removemandatories = {"dataset", "maxevents", "trackcollection"}
 
- Static Public Attributes inherited from genericValidation.GenericValidation
string defaultReferenceName = "DEFAULT"
 
dictionary defaults
 
 mandatories = set()
 
dictionary needpackages = {"Alignment/OfflineValidation"}
 
dictionary optionals = {"jobmode"}
 
- Static Public Attributes inherited from genericValidation.ValidationMetaClass
list dicts = ["defaults"]
 
list sets = ["mandatories", "optionals", "needpackages"]
 

Detailed Description

Object representing a validation that has already been run,
but should be included in plots.

Definition at line 14 of file preexistingValidation.py.

Constructor & Destructor Documentation

◆ __init__()

def preexistingValidation.PreexistingValidation.__init__ (   self,
  valName,
  config 
)

Reimplemented in preexistingValidation.PreexistingOfflineValidation.

Definition at line 22 of file preexistingValidation.py.

22  def __init__(self, valName, config):
23  self.general = config.getGeneral()
24  self.name = self.general["name"] = valName
25  self.config = config
26 
27  theUpdate = config.getResultingSection("preexisting"+self.valType+":"+self.name,
28  defaultDict = self.defaults,
29  demandPars = self.mandatories)
30  self.general.update(theUpdate)
31 
32  self.originalValName = self.general["originalValName"]
33  self.title = self.general["title"]
34  if "|" in self.title or "," in self.title or '"' in self.title:
35  msg = "The characters '|', '\"', and ',' cannot be used in the alignment title!"
36  raise AllInOneError(msg)
37  self.needsproxy = boolfromstring(self.general["needsproxy"], "needsproxy")
38  self.jobid = self.general["jobid"]
39  if self.jobid:
40  try: #make sure it's actually a valid jobid
41  output = getCommandOutput2("bjobs %(jobid)s 2>&1"%self.general)
42  if "is not found" in output: raise RuntimeError
43  except RuntimeError:
44  raise AllInOneError("%s is not a valid jobid.\nMaybe it finished already?"%self.jobid)
45 
46  knownOpts = set(self.defaults.keys())|self.mandatories|self.optionals
47  ignoreOpts = []
48  config.checkInput("preexisting"+self.valType+":"+self.name,
49  knownSimpleOptions = knownOpts,
50  ignoreOptions = ignoreOpts)
51  self.jobmode = None
52 
53  try: #initialize plotting options for this validation type
54  result = PlottingOptions(self.config, self.valType)
55  except KeyError:
56  pass
57 

Member Function Documentation

◆ createConfiguration()

def preexistingValidation.PreexistingValidation.createConfiguration (   self,
args,
**  kwargs 
)

Definition at line 77 of file preexistingValidation.py.

77  def createConfiguration(self, *args, **kwargs):
78  pass

◆ createCrabCfg()

def preexistingValidation.PreexistingValidation.createCrabCfg (   self,
args,
**  kwargs 
)

Definition at line 81 of file preexistingValidation.py.

81  def createCrabCfg(self, *args, **kwargs):
82  raise AllInOneError("Shouldn't be here...")
83 

◆ createFiles()

def preexistingValidation.PreexistingValidation.createFiles (   self,
args,
**  kwargs 
)

Definition at line 75 of file preexistingValidation.py.

75  def createFiles(self, *args, **kwargs):
76  raise AllInOneError("Shouldn't be here...")

◆ createScript()

def preexistingValidation.PreexistingValidation.createScript (   self,
args,
**  kwargs 
)

Definition at line 79 of file preexistingValidation.py.

79  def createScript(self, *args, **kwargs):
80  raise AllInOneError("Shouldn't be here...")

◆ filesToCompare()

def preexistingValidation.PreexistingValidation.filesToCompare (   self)

Reimplemented from genericValidation.GenericValidation.

Definition at line 59 of file preexistingValidation.py.

59  def filesToCompare(self):
60  return {self.defaultReferenceName: self.general["file"]}
61 

References genericValidation.GenericValidation.defaultReferenceName, and genericValidation.GenericValidation.general.

◆ getRepMap()

def preexistingValidation.PreexistingValidation.getRepMap (   self)

Member Data Documentation

◆ config

preexistingValidation.PreexistingValidation.config

◆ defaults

dictionary preexistingValidation.PreexistingValidation.defaults = {"title": ".oO[name]Oo."}
static

Definition at line 19 of file preexistingValidation.py.

Referenced by tree.Tree.reset(), and tree.Tree.var().

◆ general

preexistingValidation.PreexistingValidation.general

Definition at line 23 of file preexistingValidation.py.

◆ jobid

preexistingValidation.PreexistingValidation.jobid

Definition at line 38 of file preexistingValidation.py.

◆ jobmode

preexistingValidation.PreexistingValidation.jobmode

Definition at line 51 of file preexistingValidation.py.

◆ mandatories

dictionary preexistingValidation.PreexistingValidation.mandatories = {"file", "color", "style", "originalValName", "eosdirName", "multiIOV"}
static

Definition at line 20 of file preexistingValidation.py.

◆ name

preexistingValidation.PreexistingValidation.name

Definition at line 24 of file preexistingValidation.py.

Referenced by ElectronMVAID.ElectronMVAID.__call__(), FWLite.ElectronMVAID.__call__(), dirstructure.Directory.__create_pie_image(), DisplayManager.DisplayManager.__del__(), dqm_interfaces.DirID.__eq__(), BeautifulSoup.Tag.__eq__(), dirstructure.Directory.__get_full_path(), dirstructure.Comparison.__get_img_name(), dataset.Dataset.__getDataType(), dataset.Dataset.__getFileInfoList(), dirstructure.Comparison.__make_image(), core.autovars.NTupleVariable.__repr__(), core.autovars.NTupleObjectType.__repr__(), core.autovars.NTupleObject.__repr__(), core.autovars.NTupleCollection.__repr__(), dirstructure.Directory.__repr__(), dqm_interfaces.DirID.__repr__(), dirstructure.Comparison.__repr__(), config.Service.__setattr__(), config.CFG.__str__(), counter.Counter.__str__(), average.Average.__str__(), BeautifulSoup.Tag.__str__(), BeautifulSoup.SoupStrainer.__str__(), FWLite.WorkingPoints._reformat_cut_definitions(), core.autovars.NTupleObjectType.addSubObjects(), core.autovars.NTupleObjectType.addVariables(), core.autovars.NTupleObjectType.allVars(), dataset.CMSDataset.buildListOfFiles(), dataset.LocalDataset.buildListOfFiles(), dataset.CMSDataset.buildListOfFilesDBS(), dirstructure.Directory.calcStats(), crabFunctions.CrabTask.crabConfig(), crabFunctions.CrabTask.crabFolder(), validation.Sample.digest(), python.rootplot.utilities.Hist.divide(), python.rootplot.utilities.Hist.divide_wilson(), DisplayManager.DisplayManager.Draw(), TreeCrawler.Package.dump(), core.autovars.NTupleVariable.fillBranch(), core.autovars.NTupleObject.fillBranches(), core.autovars.NTupleCollection.fillBranchesScalar(), core.autovars.NTupleCollection.fillBranchesVector(), core.autovars.NTupleCollection.get_cpp_declaration(), core.autovars.NTupleCollection.get_cpp_wrapper_class(), core.autovars.NTupleCollection.get_py_wrapper_class(), utils.StatisticalTest.get_status(), production_tasks.Task.getname(), dataset.CMSDataset.getPrimaryDatasetEntries(), dataset.PrivateDataset.getPrimaryDatasetEntries(), crabFunctions.CrabTask.handleNoState(), VIDSelectorBase.VIDSelectorBase.initialize(), crabFunctions.CrabTask.isData(), personalPlayback.Applet.log(), core.autovars.NTupleVariable.makeBranch(), core.autovars.NTupleObject.makeBranches(), core.autovars.NTupleCollection.makeBranchesScalar(), core.autovars.NTupleCollection.makeBranchesVector(), dirstructure.Directory.print_report(), dataset.BaseDataset.printInfo(), dataset.Dataset.printInfo(), crabFunctions.CrabTask.resubmit_failed(), production_tasks.MonitorJobs.run(), BeautifulSoup.SoupStrainer.searchTag(), python.rootplot.utilities.Hist.TGraph(), python.rootplot.utilities.Hist.TH1F(), crabFunctions.CrabTask.update(), crabFunctions.CrabTask.updateJobStats(), counter.Counter.write(), and average.Average.write().

◆ needsproxy

preexistingValidation.PreexistingValidation.needsproxy

Definition at line 37 of file preexistingValidation.py.

◆ originalValName

preexistingValidation.PreexistingValidation.originalValName

Definition at line 32 of file preexistingValidation.py.

◆ removemandatories

dictionary preexistingValidation.PreexistingValidation.removemandatories = {"dataset", "maxevents", "trackcollection"}
static

Definition at line 21 of file preexistingValidation.py.

◆ title

preexistingValidation.PreexistingValidation.title
helperFunctions.boolfromstring
def boolfromstring(string, name)
Definition: helperFunctions.py:170
relativeConstraints.keys
keys
Definition: relativeConstraints.py:89
plottingOptions.PlottingOptions
def PlottingOptions(config, valType)
Definition: plottingOptions.py:240
str
#define str(s)
Definition: TestProcessor.cc:48
helperFunctions.parsestyle
def parsestyle(style)
Definition: helperFunctions.py:136
helperFunctions.getCommandOutput2
def getCommandOutput2(command)
Definition: helperFunctions.py:52
helperFunctions.parsecolor
def parsecolor(color)
Definition: helperFunctions.py:109
update
#define update(a, b)
Definition: TrackClassifier.cc:10