CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Public Attributes | Static Public Attributes
options.ConnectionHLTMenu Class Reference
Inheritance diagram for options.ConnectionHLTMenu:

Public Member Functions

def __init__
 

Public Attributes

 database
 
 name
 
 run
 
 version
 

Static Public Attributes

dictionary compatibility = { 'hltdev': ('v1', 'offline'), 'orcoff': ('v2', 'adg') }
 
string valid_databases = 'online'
 
string valid_versions = 'v1'
 

Detailed Description

Definition at line 46 of file options.py.

Constructor & Destructor Documentation

def options.ConnectionHLTMenu.__init__ (   self,
  value 
)

Definition at line 51 of file options.py.

51 
52  def __init__(self, value):
53  self.version = None
54  self.database = None
55  self.name = None
56  self.run = None
57 
58  if not value:
59  return
60 
61  if not ':' in value:
62  # default to 'v1/offline'
63  self.version = 'v1'
64  self.database = 'offline'
65  self.name = value
66  return
67 
68  # extract the version, database and configuration name
69  tokens = value.split(':')
70  if len(tokens) != 2:
71  raise Exception('Invalid HLT menu specification "%s"' % value)
72  (db, name) = tokens
73  # check if the menu should be automatically determined based on the run number
74  if db == 'run':
75  self.version = 'v2'
76  self.database = 'adg'
77  self.run = name
78  # check for backward compatibility names
79  elif db in self.compatibility:
80  self.version, self.database = self.compatibility[db]
81  self.name = name
82  else:
83  if '/' in db:
84  # extract the version and database
85  tokens = db.split('/')
86  if len(tokens) != 2:
87  raise Exception('Invalid HLT menu specification "%s"' % value)
88  (v, db) = tokens
89  if v not in self.valid_versions:
90  raise Exception('Invalid HLT database version "%s", valid values are "%s"' % (v, '", "'.join(self.valid_versions)))
91  if db not in self.valid_databases:
92  raise Exception('Invalid HLT database "%s", valid values are "%s"' % (db, '", "'.join(self.valid_databases)))
93  self.version = v
94  self.database = db
95  self.name = name
96  else:
97  # use the default version for the given database
98  if db not in self.valid_databases:
99  raise Exception('Invalid HLT database "%s", valid values are "%s"' % (db, '", "'.join(self.valid_databases)))
100  self.database = db
101  if db == 'offline' :
102  self.version = 'v1'
103  else:
104  self.version = 'v2'
105  self.name = name
106 
# options marked with a (*) only apply when creating a whole process configuration
dictionary compatibility
Definition: options.py:49
static std::string join(char **cmd)
Definition: RemoteFile.cc:18

Member Data Documentation

dictionary options.ConnectionHLTMenu.compatibility = { 'hltdev': ('v1', 'offline'), 'orcoff': ('v2', 'adg') }
static

Definition at line 49 of file options.py.

options.ConnectionHLTMenu.database

Definition at line 53 of file options.py.

options.ConnectionHLTMenu.name

Definition at line 54 of file options.py.

Referenced by ElectronMVAID.ElectronMVAID.__call__(), dirstructure.Directory.__create_pie_image(), dqm_interfaces.DirID.__eq__(), dirstructure.Directory.__get_full_path(), dirstructure.Comparison.__get_img_name(), dataset.Dataset.__getDataType(), dataset.Dataset.__getFileInfoList(), cuy.divideElement.__init__(), cuy.plotElement.__init__(), cuy.additionElement.__init__(), cuy.superimposeElement.__init__(), cuy.graphElement.__init__(), 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.CFG.__str__(), counter.Counter.__str__(), average.Average.__str__(), core.autovars.NTupleObjectType.addSubObjects(), core.autovars.NTupleObjectType.addVariables(), core.autovars.NTupleObjectType.allVars(), dirstructure.Directory.calcStats(), validation.Sample.digest(), python.rootplot.utilities.Hist.divide(), python.rootplot.utilities.Hist.divide_wilson(), 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(), VIDSelectorBase.VIDSelectorBase.initialize(), 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(), production_tasks.MonitorJobs.run(), python.rootplot.utilities.Hist.TGraph(), python.rootplot.utilities.Hist.TH1F(), Vispa.Views.PropertyView.Property.valueChanged(), counter.Counter.write(), and average.Average.write().

options.ConnectionHLTMenu.run

Definition at line 55 of file options.py.

Referenced by Types.EventID.cppID(), Types.LuminosityBlockID.cppID(), and dqm_interfaces.DirWalkerFile.walk().

string options.ConnectionHLTMenu.valid_databases = 'online'
static

Definition at line 48 of file options.py.

string options.ConnectionHLTMenu.valid_versions = 'v1'
static

Definition at line 47 of file options.py.

options.ConnectionHLTMenu.version

Definition at line 52 of file options.py.

Referenced by python.rootplot.argparse._VersionAction.__call__(), validation.Sample.datasetpattern(), validation.Sample.filename(), argparse.ArgumentParser.format_version(), and python.rootplot.argparse.ArgumentParser.format_version().