ATLAS Offline Software
Loading...
Searching...
No Matches
beamspotman Namespace Reference

Classes

class  BeamSpotOption

Functions

 check_commsep (option, opt, value)
 getT0DbConnection ()
 getTaskManager ()
 fail (message)
 dataset_from_run_and_tag (run, tag)
 run_jobs (script, ds_name, task_name, params, *args)

Variables

list __authors__ = ['Juerg Beringer', 'Carl Suster']
str __version__ = 'beamspotman.py atlas/athena'
str __usage__
str proddir = '/afs/cern.ch/user/a/atlidbs/jobs'
str produserfile = '/afs/cern.ch/user/a/atlidbs/private/produsers.dat'
str prodcoolpasswdfile = '/afs/cern.ch/user/a/atlidbs/private/coolinfo.dat'
str flaskcoolpasswdfile = '/afs/cern.ch/user/a/atlidbs/private/flaskinfo.dat'
str proddqcoolpasswdfile = '/afs/cern.ch/user/a/atlidbs/private/cooldqinfo.dat'
str tier0dbinfofile = '/afs/cern.ch/user/a/atlidbs/private/t0dbinfo.dat'
str beamspottag = ''
str backuppath = '/eos/atlas/atlascerngroupdisk/phys-beamspot/jobs/backup'
str archivepath = '/eos/atlas/atlascerngroupdisk/phys-beamspot/jobs/archive'
 parser = OptionParser(usage=__usage__, version=__version__, option_class=BeamSpotOption)
 g_input = OptionGroup(parser, 'Input file options')
 dest
 default
 False
 action
 help
 None
 g_mode = OptionGroup(parser, 'Mode flags')
 type
 g_deprecated = OptionGroup(parser, 'Deprecated Options')
 options
 args
 cmd = args[0]
 cmdargs = args[1:]
 dbfile = args[1]
 passwd = passwdfile.read().strip()
 flaskpasswd = flaskpasswdfile.read().strip()
 stat
 run = args[1]
 tag = args[2]
 dataset
 dsname = cmdargs[0]
bool lbinfoinfiles = True
str lboptions = '--lbperjob=10' if lbinfoinfiles else '--files-per-job=10'
str queue = options.batch_queue or '"tomorrow"'
dict params
 p = s.split('=',1)
 tmplist = glob.glob(args[1]+'/')
list dirlist = []
 d = dslash[:-1]
str baklog = d+'/backup.log'
 status = status >> 8
 output
 a = input('\nARE YOU SURE [n] ? ')
str tmpdir = '/tmp'
 outname = d.replace('/','-')+time.strftime('-%G_%m_%d.tar.gz')
str path = archivepath
 fs
 qual = ["where DSNAME like '%s' and TASKNAME like '%s'" % (dssel,tasksel)]
 taskname = cmdargs[1]
int steps = options.postprocsteps if len(cmdargs) < 3 else cmdargs[2].split(',')
 taskList
 t = taskman.getTaskDict(taskName[0], taskName[1])
 taskman
 BeamSpotPostProcessing
 forceRun
 requireSingleTask
 True
 confirmWithUser
 batch
 addWildCards
str ignoremode = '--passopt="--appendlocked --ignoremode %s"' % options.ignoremode
str batchmode = '--batch'
str uploadflag = dbfile[0]+'.uploaded'
str cooltags = options.beamspottag
str nextbeamspot = ''
str dir = os.path.join(dsname, task)
str griddsname = '%s.%s-%s' % (options.griduser,dsname,task)
 statfile = glob.glob('%s/000/*.status.SUBMITTED' % (dir))
 basename = statfile[0][:-17]
 tags = task.split('.')[-1]
str t0TaskName = '%s.recon.ESD.%s.beamspotproc.task' % (dsname,tags)
 oracle = getT0DbConnection()
 cur = oracle.cursor()
 sql = str("SELECT status FROM tasks WHERE taskname='%s' AND tasktype='beamspotproc'" % t0TaskName)
 r = cur.fetchall()
 dssel = args[1]
 tasksel = args[2]
 runnr = t['RUNNR']
 n = taskman.getNTasks(["where DSNAME ='%s' and TASKNAME like '%s'" % (dsname,options.excludeiftask)])
 excludeList = options.excludeds.split(',')
 out
 fullcmd = cmd % t
 earliestUpdateTime = time.time()-float(args[1])
 onDiskCode = TaskManager.OnDiskCodes['ALLONDISK']
 taskName = t['TASKNAME']
 datatag = taskName.split('.')[-1].split('_')[0]
str monTaskName = 'MON.%s.%s' % (taskName,datatag)
bool useRun = True
 m = next(taskman.taskIterDict('*',["where RUNNR =",DbParam(runnr),"and DSNAME =",DbParam(dsname),"and TASKNAME =",DbParam(monTaskName),"order by UPDATED desc"]))
 ptag = dsname.split('.')[0]
 stream = dsname.split('.')[2]
 fulldatatag = taskName.split('.')[-1]
str bstag = cooltags.split()[0]
str filter = 'AOD'
str t0dsname = '%s.merge.AOD.%s%%' % (dsname, datatag)
 c = getJobConfig('.',dsname,taskName)
bool submitjob = True
 eospath = options.eospath
str origt0TaskName = '%s.recon.AOD.%s%%.aodmerge.task' % (dsname,datatag)
str paramValues = ''
str testFlag = ''
 archivedCode = TaskManager.OnDiskCodes.get('RESULTSONDISK',None) if options.resultsondisk else TaskManager.OnDiskCodes.get('ARCHIVED',None)
list exceptList = ['*dqflags.txt', '*.gif', '*.pdf', '*.config.py*', '*.argdict.gpickle', '*.AveBeamSpot.log', '*.PlotBeamSpotCompareReproc.log', '*.sh', '*.BeamSpotNt*', '*.BeamSpotGlobalNt.log', '*.status.*', '*.exit.*']
str oscmd = r"find %s ! \‍( -name '%s' \‍) -type f -exec rm {} \;" % (dir, "' -or -name '".join(exceptList))
str basepath = os.path.join(os.getcwd(), dsname, taskname)
 dircontents = os.listdir(basepath)
str condorScriptTemplate
str jobname = dir
str fullpath = os.path.join(basepath, dir)
bool isRunning = False
bool isFailed = False
dict jobConfig
str condorScript = condorScriptTemplate % jobConfig
 script = open('condorSubmit.sub','w')
str batchCmd = 'condor_submit condorSubmit.sub'
 jobopts = args[1]
 inputdata = args[4]
 lbperjob = options.lbperjob
list files = []
dict lbMap = {}
 backend = DiskUtils.EOS() if options.eos else None
dict jobFileDict = {}
dict jobLBDict = {}
int jobId = 1
 lbs = sorted(lbMap[f.split('/')[-1]])
int jobnr = i*lbperjob+1
list intlbs = []
 runner
 comment
dict jobParams = {}
 coolQuery = COOLQuery()
 lbTimes = coolQuery.getLbTimes( getRunFromName(dsname, None, True) )
 tokens = line.split()
 plbnr
 tstart
 tend
list rlbs = [lb for (lb,time) in lbTimes.items() if (time[0] - tend/1e9)*(time[1] - tstart/1e9) < 0]
list filenames = []
str bcidTaskName = 'BCID.%s.%s' % (taskName,datatag)
 folderHandle = openBeamSpotDbFile(dbfile, dbName = 'OFLP200', forceNew = True)
int runMin = options.runMin if options.runMin is not None else 0
int runMax = options.runMax if options.runMax is not None else (1 << 31)-1
 posX
 posY
 posZ
 sigmaX
 sigmaY
 sigmaZ
 tiltX
 tiltY
 sigmaXY
 posXErr
 posYErr
 posZErr
 sigmaXErr
 sigmaYErr
 sigmaZErr
 tiltXErr
 tiltYErr
 sigmaXYErr
 dbName = options.destdbname

Detailed Description

beamspotman is a command line utility to do typical beam spot related tasks.

Function Documentation

◆ check_commsep()

beamspotman.check_commsep ( option,
opt,
value )

Definition at line 72 of file beamspotman.py.

72def check_commsep(option, opt, value):
73 return re.split(r'\s*,\s*|\s+', value)

◆ dataset_from_run_and_tag()

beamspotman.dataset_from_run_and_tag ( run,
tag )
Given a run number and tag, check input dataset and work out name. 

Definition at line 202 of file beamspotman.py.

202def dataset_from_run_and_tag(run, tag):
203 ''' Given a run number and tag, check input dataset and work out name. '''
204 fs = DiskUtils.FileSet.from_ds_info(run,
205 project=options.project,
206 stream=options.stream,
207 base=options.eospath)
208 datasets = list(fs
209 .strict_mode()
210 .use_files_from(options.filelist)
211 .matching(options.filter + tag + '.*')
212 .excluding(r'.*\.TMP\.log.*')
213 .only_single_dataset())
214 dataset = os.path.dirname(datasets[0])
215 dsname = '.'.join(os.path.basename(datasets[0]).split('.')[:3])
216 return (dataset, dsname)
217
std::vector< std::string > split(const std::string &s, const std::string &t=":")
Definition hcg.cxx:177

◆ fail()

beamspotman.fail ( message)

Definition at line 197 of file beamspotman.py.

197def fail(message):
198 print()
199 print ('ERROR:', message)
200 sys.exit(1)
201
void print(char *figname, TCanvas *c1)

◆ getT0DbConnection()

beamspotman.getT0DbConnection ( )

Definition at line 165 of file beamspotman.py.

165def getT0DbConnection():
166 try:
167 with open(tier0dbinfofile, 'r') as dbinfofile:
168 connstring = dbinfofile.read().strip()
169 except:
170 sys.exit('ERROR: Unable to read connection information for Tier-0 database')
171 dbtype, dbname = connstring.split(':',1)
172 if dbtype!='oracle':
173 sys.exit('ERROR: Invalid T0 connection string')
174 import cx_Oracle
175 try:
176 oracle = cx_Oracle.connect(dbname)
177 except:
178 print ('ERROR: First connection attempt to Tier-0 Oracle database failed; will retry in 10s ...')
179 try:
180 time.sleep(10)
181 oracle = cx_Oracle.connect(dbname)
182 except Exception as e:
183 print (e)
184 sys.exit('ERROR: Unable to connect to Tier-0 Oracle database')
185 if not oracle:
186 sys.exit('ERROR: Unable to connect to Tier-0 Oracle database (invalid cx_Oracle connection)')
187 return oracle
188

◆ getTaskManager()

beamspotman.getTaskManager ( )
Open task manager (used by all following commands, at the very least through subcommands) 

Definition at line 189 of file beamspotman.py.

189def getTaskManager():
190 ''' Open task manager (used by all following commands, at the very least through subcommands) '''
191 try:
192 return TaskManager(options.dbconn)
193 except:
194 print ('ERROR: Unable to access task manager database %s' % options.dbconn)
195 sys.exit(1)
196

◆ run_jobs()

beamspotman.run_jobs ( script,
ds_name,
task_name,
params,
* args )
Invoke runJobs.py 

Definition at line 218 of file beamspotman.py.

218def run_jobs(script, ds_name, task_name, params, *args):
219 ''' Invoke runJobs.py '''
220 arg_list = ['runJobs']
221 arg_list.extend(map(str, args))
222 if params:
223 param_args = []
224 for k,v in params.items():
225 param_args.append("{}={}".format(k,repr(v)))
226 arg_list.extend(['--params', ', '.join(param_args)])
227 if options.testonly:
228 arg_list.append('--test')
229 arg_list.extend([script, ds_name, task_name])
230
231 print (subprocess.list2cmdline(arg_list))
232 subprocess.check_call(arg_list)
233
234#
235# Upload any SQLite file to COOL (independent of task, w/o book keeping)
236#
STL class.

Variable Documentation

◆ __authors__

list beamspotman.__authors__ = ['Juerg Beringer', 'Carl Suster']
private

Definition at line 9 of file beamspotman.py.

◆ __usage__

str beamspotman.__usage__
private

Definition at line 11 of file beamspotman.py.

◆ __version__

str beamspotman.__version__ = 'beamspotman.py atlas/athena'
private

Definition at line 10 of file beamspotman.py.

◆ a

beamspotman.a = input('\nARE YOU SURE [n] ? ')

Definition at line 404 of file beamspotman.py.

◆ action

beamspotman.action

Definition at line 82 of file beamspotman.py.

◆ addWildCards

beamspotman.addWildCards

Definition at line 532 of file beamspotman.py.

◆ archivedCode

beamspotman.archivedCode = TaskManager.OnDiskCodes.get('RESULTSONDISK',None) if options.resultsondisk else TaskManager.OnDiskCodes.get('ARCHIVED',None)

Definition at line 946 of file beamspotman.py.

◆ archivepath

str beamspotman.archivepath = '/eos/atlas/atlascerngroupdisk/phys-beamspot/jobs/archive'

Definition at line 56 of file beamspotman.py.

◆ args

beamspotman.args

Definition at line 144 of file beamspotman.py.

◆ backend

beamspotman.backend = DiskUtils.EOS() if options.eos else None

Definition at line 1130 of file beamspotman.py.

◆ backuppath

str beamspotman.backuppath = '/eos/atlas/atlascerngroupdisk/phys-beamspot/jobs/backup'

Definition at line 55 of file beamspotman.py.

◆ baklog

str beamspotman.baklog = d+'/backup.log'

Definition at line 382 of file beamspotman.py.

◆ basename

beamspotman.basename = statfile[0][:-17]

Definition at line 636 of file beamspotman.py.

◆ basepath

str beamspotman.basepath = os.path.join(os.getcwd(), dsname, taskname)

Definition at line 1014 of file beamspotman.py.

◆ batch

beamspotman.batch

Definition at line 532 of file beamspotman.py.

◆ batchCmd

str beamspotman.batchCmd = 'condor_submit condorSubmit.sub'

Definition at line 1083 of file beamspotman.py.

◆ batchmode

str beamspotman.batchmode = '--batch'

Definition at line 566 of file beamspotman.py.

◆ bcidTaskName

str beamspotman.bcidTaskName = 'BCID.%s.%s' % (taskName,datatag)

Definition at line 1537 of file beamspotman.py.

◆ BeamSpotPostProcessing

beamspotman.BeamSpotPostProcessing

Definition at line 520 of file beamspotman.py.

◆ beamspottag

beamspotman.beamspottag = ''

Definition at line 54 of file beamspotman.py.

◆ bstag

str beamspotman.bstag = cooltags.split()[0]

Definition at line 854 of file beamspotman.py.

◆ c

beamspotman.c = getJobConfig('.',dsname,taskName)

Definition at line 862 of file beamspotman.py.

◆ cmd

str beamspotman.cmd = args[0]

Definition at line 146 of file beamspotman.py.

◆ cmdargs

beamspotman.cmdargs = args[1:]

Definition at line 147 of file beamspotman.py.

◆ comment

beamspotman.comment

Definition at line 1212 of file beamspotman.py.

◆ condorScript

str beamspotman.condorScript = condorScriptTemplate % jobConfig

Definition at line 1076 of file beamspotman.py.

◆ condorScriptTemplate

str beamspotman.condorScriptTemplate
Initial value:
1= """executable = %(scriptfile)s
2arguments = $(ClusterID) $(ProcId)
3output = %(logfile)s.out
4error = %(logfile)s.err
5log = %(logfile)s.log
6universe = vanilla
7+JobFlavour = %(batchqueue)s
8queue
9"""

Definition at line 1017 of file beamspotman.py.

◆ confirmWithUser

beamspotman.confirmWithUser

Definition at line 532 of file beamspotman.py.

◆ coolQuery

beamspotman.coolQuery = COOLQuery()

Definition at line 1271 of file beamspotman.py.

◆ cooltags

beamspotman.cooltags = options.beamspottag

Definition at line 583 of file beamspotman.py.

◆ cur

beamspotman.cur = oracle.cursor()

Definition at line 667 of file beamspotman.py.

◆ d

beamspotman.d = dslash[:-1]

Definition at line 380 of file beamspotman.py.

◆ dataset

beamspotman.dataset

Definition at line 282 of file beamspotman.py.

◆ datatag

beamspotman.datatag = taskName.split('.')[-1].split('_')[0]

Definition at line 812 of file beamspotman.py.

◆ dbfile

str beamspotman.dbfile = args[1]

Definition at line 238 of file beamspotman.py.

◆ dbName

beamspotman.dbName = options.destdbname

Definition at line 1649 of file beamspotman.py.

◆ default

beamspotman.default

Definition at line 82 of file beamspotman.py.

◆ dest

beamspotman.dest

Definition at line 82 of file beamspotman.py.

◆ dir

str beamspotman.dir = os.path.join(dsname, task)

Definition at line 619 of file beamspotman.py.

◆ dircontents

beamspotman.dircontents = os.listdir(basepath)

Definition at line 1015 of file beamspotman.py.

◆ dirlist

list beamspotman.dirlist = []

Definition at line 378 of file beamspotman.py.

◆ dsname

beamspotman.dsname = cmdargs[0]

Definition at line 282 of file beamspotman.py.

◆ dssel

beamspotman.dssel = args[1]

Definition at line 692 of file beamspotman.py.

◆ earliestUpdateTime

int beamspotman.earliestUpdateTime = time.time()-float(args[1])

Definition at line 791 of file beamspotman.py.

◆ eospath

str beamspotman.eospath = options.eospath

Definition at line 870 of file beamspotman.py.

◆ exceptList

list beamspotman.exceptList = ['*dqflags.txt', '*.gif', '*.pdf', '*.config.py*', '*.argdict.gpickle', '*.AveBeamSpot.log', '*.PlotBeamSpotCompareReproc.log', '*.sh', '*.BeamSpotNt*', '*.BeamSpotGlobalNt.log', '*.status.*', '*.exit.*']

Definition at line 947 of file beamspotman.py.

◆ excludeList

beamspotman.excludeList = options.excludeds.split(',')

Definition at line 735 of file beamspotman.py.

◆ False

beamspotman.False

Definition at line 82 of file beamspotman.py.

◆ filenames

list beamspotman.filenames = []

Definition at line 1294 of file beamspotman.py.

◆ files

dict beamspotman.files = []

Definition at line 1110 of file beamspotman.py.

◆ filter

str beamspotman.filter = 'AOD'

Definition at line 856 of file beamspotman.py.

◆ flaskcoolpasswdfile

str beamspotman.flaskcoolpasswdfile = '/afs/cern.ch/user/a/atlidbs/private/flaskinfo.dat'

Definition at line 51 of file beamspotman.py.

◆ flaskpasswd

beamspotman.flaskpasswd = flaskpasswdfile.read().strip()

Definition at line 249 of file beamspotman.py.

◆ folderHandle

beamspotman.folderHandle = openBeamSpotDbFile(dbfile, dbName = 'OFLP200', forceNew = True)

Definition at line 1612 of file beamspotman.py.

◆ forceRun

beamspotman.forceRun

Definition at line 520 of file beamspotman.py.

◆ fs

beamspotman.fs
Initial value:
1= DiskUtils.FileSet.from_ds_info(run,
2 project=options.project,
3 stream=options.stream,
4 base=options.eospath)

Definition at line 466 of file beamspotman.py.

◆ fullcmd

beamspotman.fullcmd = cmd % t

Definition at line 777 of file beamspotman.py.

◆ fulldatatag

beamspotman.fulldatatag = taskName.split('.')[-1]

Definition at line 846 of file beamspotman.py.

◆ fullpath

str beamspotman.fullpath = os.path.join(basepath, dir)

Definition at line 1035 of file beamspotman.py.

◆ g_deprecated

beamspotman.g_deprecated = OptionGroup(parser, 'Deprecated Options')

Definition at line 140 of file beamspotman.py.

◆ g_input

beamspotman.g_input = OptionGroup(parser, 'Input file options')

Definition at line 81 of file beamspotman.py.

◆ g_mode

beamspotman.g_mode = OptionGroup(parser, 'Mode flags')

Definition at line 94 of file beamspotman.py.

◆ griddsname

str beamspotman.griddsname = '%s.%s-%s' % (options.griduser,dsname,task)

Definition at line 620 of file beamspotman.py.

◆ help

beamspotman.help

Definition at line 82 of file beamspotman.py.

◆ ignoremode

str beamspotman.ignoremode = '--passopt="--appendlocked --ignoremode %s"' % options.ignoremode

Definition at line 562 of file beamspotman.py.

◆ inputdata

beamspotman.inputdata = args[4]

Definition at line 1105 of file beamspotman.py.

◆ intlbs

list beamspotman.intlbs = []

Definition at line 1181 of file beamspotman.py.

◆ isFailed

bool beamspotman.isFailed = False

Definition at line 1038 of file beamspotman.py.

◆ isRunning

bool beamspotman.isRunning = False

Definition at line 1037 of file beamspotman.py.

◆ jobConfig

dict beamspotman.jobConfig
Initial value:
1= {
2 'test': 'this',
3 'batchqueue' : queue,
4 'jobname' : jobname,
5 'jobdir' : fullpath,
6 }

Definition at line 1067 of file beamspotman.py.

◆ jobFileDict

dict beamspotman.jobFileDict = {}

Definition at line 1139 of file beamspotman.py.

◆ jobId

beamspotman.jobId = 1

Definition at line 1144 of file beamspotman.py.

◆ jobLBDict

dict beamspotman.jobLBDict = {}

Definition at line 1140 of file beamspotman.py.

◆ jobname

str beamspotman.jobname = dir

Definition at line 1032 of file beamspotman.py.

◆ jobnr

int beamspotman.jobnr = i*lbperjob+1

Definition at line 1176 of file beamspotman.py.

◆ jobopts

beamspotman.jobopts = args[1]

Definition at line 1102 of file beamspotman.py.

◆ jobParams

dict beamspotman.jobParams = {}

Definition at line 1266 of file beamspotman.py.

◆ lbinfoinfiles

bool beamspotman.lbinfoinfiles = True

Definition at line 325 of file beamspotman.py.

◆ lbMap

dict beamspotman.lbMap = {}

Definition at line 1129 of file beamspotman.py.

◆ lboptions

str beamspotman.lboptions = '--lbperjob=10' if lbinfoinfiles else '--files-per-job=10'

Definition at line 330 of file beamspotman.py.

◆ lbperjob

beamspotman.lbperjob = options.lbperjob

Definition at line 1107 of file beamspotman.py.

◆ lbs

beamspotman.lbs = sorted(lbMap[f.split('/')[-1]])

Definition at line 1150 of file beamspotman.py.

◆ lbTimes

beamspotman.lbTimes = coolQuery.getLbTimes( getRunFromName(dsname, None, True) )

Definition at line 1273 of file beamspotman.py.

◆ m

beamspotman.m = next(taskman.taskIterDict('*',["where RUNNR =",DbParam(runnr),"and DSNAME =",DbParam(dsname),"and TASKNAME =",DbParam(monTaskName),"order by UPDATED desc"]))

Definition at line 822 of file beamspotman.py.

◆ monTaskName

str beamspotman.monTaskName = 'MON.%s.%s' % (taskName,datatag)

Definition at line 813 of file beamspotman.py.

◆ n

beamspotman.n = taskman.getNTasks(["where DSNAME ='%s' and TASKNAME like '%s'" % (dsname,options.excludeiftask)])

Definition at line 727 of file beamspotman.py.

◆ nextbeamspot

str beamspotman.nextbeamspot = ''

Definition at line 589 of file beamspotman.py.

◆ None

beamspotman.None

Definition at line 90 of file beamspotman.py.

◆ onDiskCode

beamspotman.onDiskCode = TaskManager.OnDiskCodes['ALLONDISK']

Definition at line 801 of file beamspotman.py.

◆ options

beamspotman.options

Definition at line 144 of file beamspotman.py.

◆ oracle

beamspotman.oracle = getT0DbConnection()

Definition at line 666 of file beamspotman.py.

◆ origt0TaskName

str beamspotman.origt0TaskName = '%s.recon.AOD.%s%%.aodmerge.task' % (dsname,datatag)

Definition at line 885 of file beamspotman.py.

◆ oscmd

str beamspotman.oscmd = r"find %s ! \‍( -name '%s' \‍) -type f -exec rm {} \;" % (dir, "' -or -name '".join(exceptList))

Definition at line 986 of file beamspotman.py.

◆ out

beamspotman.out

Definition at line 742 of file beamspotman.py.

◆ outname

str beamspotman.outname = d.replace('/','-')+time.strftime('-%G_%m_%d.tar.gz')

Definition at line 410 of file beamspotman.py.

◆ output

beamspotman.output

Definition at line 385 of file beamspotman.py.

◆ p

dict beamspotman.p = s.split('=',1)

Definition at line 356 of file beamspotman.py.

◆ params

dict beamspotman.params
Initial value:
1= {
2 'cmdjobpreprocessing' : 'export STAGE_SVCCLASS=atlcal; export ATLAS_LOCAL_ROOT_BASE=/cvmfs/atlas.cern.ch/repo/ATLASLocalRootBase',
3 'useBeamSpot' : True,
4 'beamspottag' : options.beamspottag
5 }

Definition at line 346 of file beamspotman.py.

◆ paramValues

str beamspotman.paramValues = ''

Definition at line 903 of file beamspotman.py.

◆ parser

beamspotman.parser = OptionParser(usage=__usage__, version=__version__, option_class=BeamSpotOption)

Definition at line 79 of file beamspotman.py.

◆ passwd

beamspotman.passwd = passwdfile.read().strip()

Definition at line 243 of file beamspotman.py.

◆ path

str beamspotman.path = archivepath

Definition at line 411 of file beamspotman.py.

◆ plbnr

beamspotman.plbnr

Definition at line 1281 of file beamspotman.py.

◆ posX

beamspotman.posX

Definition at line 1620 of file beamspotman.py.

◆ posXErr

beamspotman.posXErr

Definition at line 1625 of file beamspotman.py.

◆ posY

beamspotman.posY

Definition at line 1620 of file beamspotman.py.

◆ posYErr

beamspotman.posYErr

Definition at line 1625 of file beamspotman.py.

◆ posZ

beamspotman.posZ

Definition at line 1620 of file beamspotman.py.

◆ posZErr

beamspotman.posZErr

Definition at line 1625 of file beamspotman.py.

◆ prodcoolpasswdfile

str beamspotman.prodcoolpasswdfile = '/afs/cern.ch/user/a/atlidbs/private/coolinfo.dat'

Definition at line 50 of file beamspotman.py.

◆ proddir

beamspotman.proddir = '/afs/cern.ch/user/a/atlidbs/jobs'

Definition at line 48 of file beamspotman.py.

◆ proddqcoolpasswdfile

str beamspotman.proddqcoolpasswdfile = '/afs/cern.ch/user/a/atlidbs/private/cooldqinfo.dat'

Definition at line 52 of file beamspotman.py.

◆ produserfile

str beamspotman.produserfile = '/afs/cern.ch/user/a/atlidbs/private/produsers.dat'

Definition at line 49 of file beamspotman.py.

◆ ptag

beamspotman.ptag = dsname.split('.')[0]

Definition at line 843 of file beamspotman.py.

◆ qual

list beamspotman.qual = ["where DSNAME like '%s' and TASKNAME like '%s'" % (dssel,tasksel)]

Definition at line 477 of file beamspotman.py.

◆ queue

str beamspotman.queue = options.batch_queue or '"tomorrow"'

Definition at line 343 of file beamspotman.py.

◆ r

list beamspotman.r = cur.fetchall()

Definition at line 672 of file beamspotman.py.

◆ requireSingleTask

beamspotman.requireSingleTask

Definition at line 532 of file beamspotman.py.

◆ rlbs

list beamspotman.rlbs = [lb for (lb,time) in lbTimes.items() if (time[0] - tend/1e9)*(time[1] - tstart/1e9) < 0]

Definition at line 1291 of file beamspotman.py.

◆ run

beamspotman.run = args[1]

Definition at line 280 of file beamspotman.py.

◆ runMax

int beamspotman.runMax = options.runMax if options.runMax is not None else (1 << 31)-1

Definition at line 1615 of file beamspotman.py.

◆ runMin

int beamspotman.runMin = options.runMin if options.runMin is not None else 0

Definition at line 1614 of file beamspotman.py.

◆ runner

beamspotman.runner
Initial value:
1= HTCondorJobRunner.HTCondorJobRunner(
2 jobnr=jobnr,
3 jobdir=os.path.join(os.getcwd(), dsname, taskname, jobname),
4 jobname=jobname,
5 inputds='',
6 inputfiles=files,
7 joboptionpath=jobopts,
8 filesperjob=len(files),
9 batchqueue=queue,
10 addinputtopoolcatalog=True,
11 taskpostprocsteps='ReprocVertexDefaultProcessing',
12 #outputfilelist=['dpd.root', 'nt.root', 'monitoring,root', 'beamspot.db'],
13 autoconfparams='DetDescrVersion',
14 returnstatuscode=True,
15 comment=cmd,
16 **params)

Definition at line 1188 of file beamspotman.py.

◆ runnr

beamspotman.runnr = t['RUNNR']

Definition at line 720 of file beamspotman.py.

◆ script

beamspotman.script = open('condorSubmit.sub','w')

Definition at line 1078 of file beamspotman.py.

◆ sigmaX

beamspotman.sigmaX

Definition at line 1621 of file beamspotman.py.

◆ sigmaXErr

beamspotman.sigmaXErr

Definition at line 1626 of file beamspotman.py.

◆ sigmaXY

beamspotman.sigmaXY

Definition at line 1624 of file beamspotman.py.

◆ sigmaXYErr

beamspotman.sigmaXYErr

Definition at line 1628 of file beamspotman.py.

◆ sigmaY

beamspotman.sigmaY

Definition at line 1621 of file beamspotman.py.

◆ sigmaYErr

beamspotman.sigmaYErr

Definition at line 1626 of file beamspotman.py.

◆ sigmaZ

beamspotman.sigmaZ

Definition at line 1621 of file beamspotman.py.

◆ sigmaZErr

beamspotman.sigmaZErr

Definition at line 1626 of file beamspotman.py.

◆ sql

beamspotman.sql = str("SELECT status FROM tasks WHERE taskname='%s' AND tasktype='beamspotproc'" % t0TaskName)

Definition at line 670 of file beamspotman.py.

◆ stat

beamspotman.stat
Initial value:
1= os.system('/afs/cern.ch/user/a/atlcond/utilsproxy/AtlCoolMerge.py --flask --nobackup --client_id cool-flask-beamspot-client --client_secret %s --nomail %s %s --folder /Indet/Beampos --tag %s --retag %s --destdb %s %s %s ATONR_COOLOFL_GPN ATLAS_COOLOFL_INDET_W %s' % (
2 flaskpasswd,
3 '--batch' if options.batch else '',
4 ('--ignoremode %s' % options.ignoremode) if options.ignoremode else '',
5 options.srctag,
6 options.beamspottag,
7 options.destdbname,
8 dbfile,
9 options.srcdbname,
10 passwd))

Definition at line 262 of file beamspotman.py.

◆ statfile

beamspotman.statfile = glob.glob('%s/000/*.status.SUBMITTED' % (dir))

Definition at line 630 of file beamspotman.py.

◆ status

int beamspotman.status = status >> 8

Definition at line 385 of file beamspotman.py.

◆ steps

beamspotman.steps = options.postprocsteps if len(cmdargs) < 3 else cmdargs[2].split(',')

Definition at line 501 of file beamspotman.py.

◆ stream

beamspotman.stream = dsname.split('.')[2]

Definition at line 844 of file beamspotman.py.

◆ submitjob

bool beamspotman.submitjob = True

Definition at line 869 of file beamspotman.py.

◆ t

beamspotman.t = taskman.getTaskDict(taskName[0], taskName[1])

Definition at line 518 of file beamspotman.py.

◆ t0dsname

str beamspotman.t0dsname = '%s.merge.AOD.%s%%' % (dsname, datatag)

Definition at line 858 of file beamspotman.py.

◆ t0TaskName

str beamspotman.t0TaskName = '%s.recon.ESD.%s.beamspotproc.task' % (dsname,tags)

Definition at line 658 of file beamspotman.py.

◆ tag

beamspotman.tag = args[2]

Definition at line 281 of file beamspotman.py.

◆ tags

beamspotman.tags = task.split('.')[-1]

Definition at line 655 of file beamspotman.py.

◆ taskList

list beamspotman.taskList
Initial value:
1= getFullTaskNames(taskman,
2 dsname,
3 taskname,
4 confirmWithUser=not options.batch,
5 addWildCards=not options.nowildcards)

Definition at line 510 of file beamspotman.py.

◆ taskman

beamspotman.taskman

Definition at line 520 of file beamspotman.py.

◆ taskName

beamspotman.taskName = t['TASKNAME']

Definition at line 811 of file beamspotman.py.

◆ taskname

beamspotman.taskname = cmdargs[1]

Definition at line 496 of file beamspotman.py.

◆ tasksel

beamspotman.tasksel = args[2]

Definition at line 693 of file beamspotman.py.

◆ tend

beamspotman.tend

Definition at line 1281 of file beamspotman.py.

◆ testFlag

str beamspotman.testFlag = ''

Definition at line 906 of file beamspotman.py.

◆ tier0dbinfofile

str beamspotman.tier0dbinfofile = '/afs/cern.ch/user/a/atlidbs/private/t0dbinfo.dat'

Definition at line 53 of file beamspotman.py.

◆ tiltX

beamspotman.tiltX

Definition at line 1622 of file beamspotman.py.

◆ tiltXErr

beamspotman.tiltXErr

Definition at line 1627 of file beamspotman.py.

◆ tiltY

beamspotman.tiltY

Definition at line 1623 of file beamspotman.py.

◆ tiltYErr

beamspotman.tiltYErr

Definition at line 1627 of file beamspotman.py.

◆ tmpdir

str beamspotman.tmpdir = '/tmp'

Definition at line 408 of file beamspotman.py.

◆ tmplist

beamspotman.tmplist = glob.glob(args[1]+'/')

Definition at line 377 of file beamspotman.py.

◆ tokens

beamspotman.tokens = line.split()

Definition at line 1280 of file beamspotman.py.

◆ True

beamspotman.True

Definition at line 532 of file beamspotman.py.

◆ tstart

beamspotman.tstart

Definition at line 1281 of file beamspotman.py.

◆ type

beamspotman.type

Definition at line 120 of file beamspotman.py.

◆ uploadflag

str beamspotman.uploadflag = dbfile[0]+'.uploaded'

Definition at line 578 of file beamspotman.py.

◆ useRun

bool beamspotman.useRun = True

Definition at line 814 of file beamspotman.py.