CMS 3D CMS Logo

Functions | Variables

lumiCalc2 Namespace Reference

Functions

def parseInputFiles

Variables

string action = 'store_true'
list allowedActions = ['overview', 'delivered', 'recorded', 'lumibyls','lumibylsXing']
list amodetagChoices = [ "PROTPHYS","IONPHYS",'PAPHYS' ]
list beamChoices = ['PROTPHYS','IONPHYS','PAPHYS']
list beamModeChoices = [ "stable"]
tuple c = checkforupdate.checkforupdate()
 choices = amodetagChoices,
 ls filter
list cmsswWorkingBase = os.environ['CMSSW_BASE']
tuple dataidmap = lumiCalcAPI.runList(session.nominalSchema(),datatagid,runmin=reqrunmin,runmax=reqrunmax,fillmin=reqfillmin,fillmax=reqfillmax,startT=reqtimemin,stopT=reqtimemax,l1keyPattern=None,hltkeyPattern=None,amodetag=options.amodetag,nominalEnergy=options.beamenergy,energyFlut=options.beamfluctuation,requiretrg=reqTrg,requirehlt=reqHlt,preselectedruns=filerunlist)
tuple datatagid = revisionDML.getDataTagId(session.nominalSchema(),datatagname)
 datatagname = options.datatag
 check datatag #############################################################
string default = 'frontier://LumiCalc/CMS_LUMI_PROD'
 arg to select exact hltpath or pattern
string dest = 'withoutNorm'
 switches
 filerunlist = None
tuple GrunsummaryData = lumiCalcAPI.runsummaryMap(session.nominalSchema(),irunlsdict,dataidmap,lumitype='HF')
 ls level #
string help = 'command actions'
 basic arguments
 hltname = options.hltpath
 hltpat = None
list iresults = []
dictionary irunlsdict = {}
 check run/ls list
tuple lute = lumiTime.lumiTime()
int normid = 0
tuple normmap = normDML.normIdByType(session.nominalSchema(),lumitype='HF',defaultonly=True)
string normname = 'NONE'
 check normtag and get norm values if required
dictionary normvalueDict = {}
 noWarning = options.nowarning
tuple options = parser.parse_args()
 outfile = options.outputfile
tuple parser = argparse.ArgumentParser(prog=os.path.basename(sys.argv[0]),description = "Lumi Calculation",formatter_class=argparse.ArgumentDefaultsHelpFormatter)
 ######################## ## ## ################## ## ## ## ## Main Program ## ## ## ## ################## ## ## ######################## ##
 pbeammode = None
 reqfillmax = None
 reqfillmin = None
 reqHlt = False
 reqrunmax = None
 reqrunmin = None
 reqtimemax = None
tuple reqtimemaxT = lute.StrToDatetime(reqtimemax,customfm='%m/%d/%y %H:%M:%S')
 reqtimemin = None
tuple reqtimeminT = lute.StrToDatetime(reqtimemin,customfm='%m/%d/%y %H:%M:%S')
 reqTrg = False
 required = False,
 arg to select exact run and ls
tuple result = lumiCalcAPI.deliveredLumiForIds(session.nominalSchema(),irunlsdict,dataidmap,runsummaryMap=GrunsummaryData,beamstatusfilter=pbeammode,timeFilter=timeFilter,normmap=normvalueDict,lumitype='HF')
list rruns = []
tuple session = svc.openSession(isReadOnly=True,cpp2sqltype=[('unsigned int','NUMBER(10)'),('unsigned long long','NUMBER(20)')])
tuple svc
 pre-check option compatibility
list thiscmmd = sys.argv[0]
list timeFilter = [None,None]
 type = int,
 global scale factor
string updateversion = 'NONE'
tuple updateversionList = c.checkforupdate(workingversion,isverbose=False)
string workingversion = 'UNKNOWN'
 check working environment
list xingAlgoChoices = [ "OCC1","OCC2","ET"]

Function Documentation

def lumiCalc2::parseInputFiles (   inputfilename)
output ({run:[cmsls,cmsls,...]},[[resultlines]])

Definition at line 14 of file lumiCalc2.py.

00015                                   :
00016     '''
00017     output ({run:[cmsls,cmsls,...]},[[resultlines]])
00018     '''
00019     selectedrunlsInDB={}
00020     resultlines=[]
00021     p=inputFilesetParser.inputFilesetParser(inputfilename)
00022     runlsbyfile=p.runsandls()
00023     selectedProcessedRuns=p.selectedRunsWithresult()
00024     selectedNonProcessedRuns=p.selectedRunsWithoutresult()
00025     resultlines=p.resultlines()
00026     for runinfile in selectedNonProcessedRuns:
00027         selectedrunlsInDB[runinfile]=runlsbyfile[runinfile]
00028     return (selectedrunlsInDB,resultlines)


Variable Documentation

string lumiCalc2::action = 'store_true'

Definition at line 173 of file lumiCalc2.py.

list lumiCalc2::allowedActions = ['overview', 'delivered', 'recorded', 'lumibyls','lumibylsXing']

Definition at line 39 of file lumiCalc2.py.

list lumiCalc2::amodetagChoices = [ "PROTPHYS","IONPHYS",'PAPHYS' ]

Definition at line 41 of file lumiCalc2.py.

list lumiCalc2::beamChoices = ['PROTPHYS','IONPHYS','PAPHYS']

Definition at line 12 of file lumiCalc2.py.

list lumiCalc2::beamModeChoices = [ "stable"]

Definition at line 40 of file lumiCalc2.py.

Definition at line 270 of file lumiCalc2.py.

ls filter

Definition at line 96 of file lumiCalc2.py.

list lumiCalc2::cmsswWorkingBase = os.environ['CMSSW_BASE']

Definition at line 266 of file lumiCalc2.py.

tuple lumiCalc2::dataidmap = lumiCalcAPI.runList(session.nominalSchema(),datatagid,runmin=reqrunmin,runmax=reqrunmax,fillmin=reqfillmin,fillmax=reqfillmax,startT=reqtimemin,stopT=reqtimemax,l1keyPattern=None,hltkeyPattern=None,amodetag=options.amodetag,nominalEnergy=options.beamenergy,energyFlut=options.beamfluctuation,requiretrg=reqTrg,requirehlt=reqHlt,preselectedruns=filerunlist)

Definition at line 324 of file lumiCalc2.py.

tuple lumiCalc2::datatagid = revisionDML.getDataTagId(session.nominalSchema(),datatagname)

Definition at line 322 of file lumiCalc2.py.

lumiCalc2::datatagname = options.datatag

check datatag #############################################################

Definition at line 318 of file lumiCalc2.py.

float lumiCalc2::default = 'frontier://LumiCalc/CMS_LUMI_PROD'

arg to select exact hltpath or pattern

command configuration

run filters

Definition at line 55 of file lumiCalc2.py.

string lumiCalc2::dest = 'withoutNorm'

switches

Definition at line 172 of file lumiCalc2.py.

tuple lumiCalc2::filerunlist = None

Definition at line 302 of file lumiCalc2.py.

tuple lumiCalc2::GrunsummaryData = lumiCalcAPI.runsummaryMap(session.nominalSchema(),irunlsdict,dataidmap,lumitype='HF')

ls level #

Definition at line 377 of file lumiCalc2.py.

string lumiCalc2::help = 'command actions'

basic arguments

Definition at line 51 of file lumiCalc2.py.

lumiCalc2::hltname = options.hltpath

Definition at line 389 of file lumiCalc2.py.

Referenced by LumiCalculator::beginRun(), and LumiCalculator::endLuminosityBlock().

Definition at line 390 of file lumiCalc2.py.

Definition at line 210 of file lumiCalc2.py.

check run/ls list

Definition at line 299 of file lumiCalc2.py.

Definition at line 237 of file lumiCalc2.py.

Referenced by EcalTPGParamBuilder::analyze().

tuple lumiCalc2::normid = 0

Definition at line 353 of file lumiCalc2.py.

tuple lumiCalc2::normmap = normDML.normIdByType(session.nominalSchema(),lumitype='HF',defaultonly=True)

Definition at line 358 of file lumiCalc2.py.

tuple lumiCalc2::normname = 'NONE'

check normtag and get norm values if required

Definition at line 352 of file lumiCalc2.py.

Definition at line 354 of file lumiCalc2.py.

lumiCalc2::noWarning = options.nowarning

Definition at line 206 of file lumiCalc2.py.

tuple lumiCalc2::options = parser.parse_args()

Definition at line 196 of file lumiCalc2.py.

string lumiCalc2::outfile = options.outputfile

Definition at line 411 of file lumiCalc2.py.

tuple lumiCalc2::parser = argparse.ArgumentParser(prog=os.path.basename(sys.argv[0]),description = "Lumi Calculation",formatter_class=argparse.ArgumentDefaultsHelpFormatter)

######################## ## ## ################## ## ## ## ## Main Program ## ## ## ## ################## ## ## ######################## ##

Definition at line 38 of file lumiCalc2.py.

string lumiCalc2::pbeammode = None

Definition at line 207 of file lumiCalc2.py.

Definition at line 203 of file lumiCalc2.py.

Definition at line 200 of file lumiCalc2.py.

Definition at line 212 of file lumiCalc2.py.

Definition at line 202 of file lumiCalc2.py.

Definition at line 199 of file lumiCalc2.py.

Definition at line 204 of file lumiCalc2.py.

tuple lumiCalc2::reqtimemaxT = lute.StrToDatetime(reqtimemax,customfm='%m/%d/%y %H:%M:%S')

Definition at line 252 of file lumiCalc2.py.

Definition at line 201 of file lumiCalc2.py.

tuple lumiCalc2::reqtimeminT = lute.StrToDatetime(reqtimemin,customfm='%m/%d/%y %H:%M:%S')

Definition at line 238 of file lumiCalc2.py.

Definition at line 211 of file lumiCalc2.py.

arg to select exact run and ls

versions control

Definition at line 53 of file lumiCalc2.py.

tuple lumiCalc2::result = lumiCalcAPI.deliveredLumiForIds(session.nominalSchema(),irunlsdict,dataidmap,runsummaryMap=GrunsummaryData,beamstatusfilter=pbeammode,timeFilter=timeFilter,normmap=normvalueDict,lumitype='HF')

Definition at line 379 of file lumiCalc2.py.

list lumiCalc2::rruns = []

Definition at line 300 of file lumiCalc2.py.

tuple lumiCalc2::session = svc.openSession(isReadOnly=True,cpp2sqltype=[('unsigned int','NUMBER(10)'),('unsigned long long','NUMBER(20)')])

Definition at line 294 of file lumiCalc2.py.

Initial value:
00001 sessionManager.sessionManager(options.connect,
00002                                       authpath=options.authpath,
00003                                       siteconfpath=options.siteconfpath,
00004                                       debugON=options.debug)

pre-check option compatibility

Definition at line 290 of file lumiCalc2.py.

list lumiCalc2::thiscmmd = sys.argv[0]

Definition at line 263 of file lumiCalc2.py.

list lumiCalc2::timeFilter = [None,None]

Definition at line 205 of file lumiCalc2.py.

tuple lumiCalc2::type = int,

global scale factor

Definition at line 60 of file lumiCalc2.py.

list lumiCalc2::updateversion = 'NONE'

Definition at line 262 of file lumiCalc2.py.

tuple lumiCalc2::updateversionList = c.checkforupdate(workingversion,isverbose=False)

Definition at line 273 of file lumiCalc2.py.

tuple lumiCalc2::workingversion = 'UNKNOWN'

check working environment

Definition at line 261 of file lumiCalc2.py.

list lumiCalc2::xingAlgoChoices = [ "OCC1","OCC2","ET"]

Definition at line 42 of file lumiCalc2.py.