Public Member Functions | |
def | __init__ |
def | initCrab |
def | initProcess |
def | run |
def | writeCfg |
Public Attributes | |
config | |
crab_cfg | |
dir | |
inputdb | |
outputfile | |
process | |
project | |
pset_name | |
pset_template | |
task |
Definition at line 6 of file DTTTrigValid.py.
def DTTTrigValid::DTTTrigValid::__init__ | ( | self, | |
run, | |||
dir, | |||
input_db, | |||
config | |||
) |
Definition at line 7 of file DTTTrigValid.py.
00008 : 00009 self.pset_name = 'dtCalibValidation_cfg.py' 00010 #self.outputfile = 'residuals.root,DQM.root' 00011 self.outputfile = 'DQM.root' 00012 self.config = config 00013 self.dir = dir 00014 self.inputdb = input_db 00015 00016 self.pset_template = 'CalibMuon.DTCalibration.dtCalibValidation_cfg' 00017 if hasattr(self.config,'runOnCosmics') and self.config.runOnCosmics: 00018 self.pset_template = 'CalibMuon.DTCalibration.dtCalibValidation_cosmics_cfg' 00019 00020 self.process = None 00021 self.crab_cfg = None 00022 self.initProcess() 00023 self.initCrab() 00024 self.task = CrabTask(self.dir,self.crab_cfg)
def DTTTrigValid::DTTTrigValid::initCrab | ( | self | ) |
Definition at line 62 of file DTTTrigValid.py.
00063 : 00064 crab_cfg_parser = loadCrabCfg() 00065 loadCrabDefault(crab_cfg_parser,self.config) 00066 crab_cfg_parser.set('CMSSW','pset',self.pset_name) 00067 crab_cfg_parser.set('CMSSW','output_file',self.outputfile) 00068 crab_cfg_parser.remove_option('USER','additional_input_files') 00069 if self.inputdb: 00070 addCrabInputFile(crab_cfg_parser,self.inputdb) 00071 00072 if hasattr(self.config,'inputVDriftDB') and self.config.inputVDriftDB: 00073 addCrabInputFile(crab_cfg_parser,self.config.inputVDriftDB) 00074 00075 self.crab_cfg = crab_cfg_parser
def DTTTrigValid::DTTTrigValid::initProcess | ( | self | ) |
Definition at line 25 of file DTTTrigValid.py.
00026 : 00027 self.process = loadCmsProcess(self.pset_template) 00028 self.process.GlobalTag.globaltag = self.config.globaltag 00029 #self.process.dtCalibValidation.OutputMEsInRootFile = True 00030 00031 if hasattr(self.config,'inputDBTag') and self.config.inputDBTag: 00032 tag = self.config.inputDBTag 00033 record = self.config.inputDBRcd 00034 connect = self.config.connectStrDBTag 00035 moduleName = 'customDB%s' % record 00036 addPoolDBESSource(process = self.process, 00037 moduleName = moduleName,record = record,tag = tag, 00038 connect = connect) 00039 00040 if hasattr(self.config,'inputVDriftDB') and self.config.inputVDriftDB: 00041 addPoolDBESSource(process = self.process, 00042 moduleName = 'vDriftDB',record = 'DTMtimeRcd',tag = 'vDrift', 00043 connect = 'sqlite_file:%s' % os.path.basename(self.config.inputVDriftDB)) 00044 00045 if(self.inputdb): 00046 label = '' 00047 if hasattr(self.config,'runOnCosmics') and self.config.runOnCosmics: label = 'cosmics' 00048 addPoolDBESSource(process = self.process, 00049 moduleName = 'calibDB',record = 'DTTtrigRcd',tag = 'ttrig',label=label, 00050 connect = 'sqlite_file:%s' % os.path.basename(self.inputdb)) 00051 00052 if hasattr(self.config,'runOnRAW') and self.config.runOnRAW: 00053 if hasattr(self.config,'runOnMC') and self.config.runOnMC: 00054 getattr(self.process,self.config.digilabel).inputLabel = 'rawDataCollector' 00055 prependPaths(self.process,self.config.digilabel) 00056 00057 if hasattr(self.config,'preselection') and self.config.preselection: 00058 pathsequence = self.config.preselection.split(':')[0] 00059 seqname = self.config.preselection.split(':')[1] 00060 self.process.load(pathsequence) 00061 prependPaths(self.process,seqname)
def DTTTrigValid::DTTTrigValid::run | ( | self | ) |
Definition at line 80 of file DTTTrigValid.py.
def DTTTrigValid::DTTTrigValid::writeCfg | ( | self | ) |
Definition at line 76 of file DTTTrigValid.py.
Definition at line 7 of file DTTTrigValid.py.
Definition at line 7 of file DTTTrigValid.py.
Definition at line 7 of file DTTTrigValid.py.
Definition at line 7 of file DTTTrigValid.py.
Definition at line 7 of file DTTTrigValid.py.
Definition at line 7 of file DTTTrigValid.py.
Definition at line 80 of file DTTTrigValid.py.
Definition at line 7 of file DTTTrigValid.py.
Definition at line 7 of file DTTTrigValid.py.
Definition at line 7 of file DTTTrigValid.py.