monMan.ManualRunLBSetup = True
monMan.Run = 1
monMan.LumiBlock = 1

from MuonCalibMonitoring.MuonCalibMonitoringConf import CscCalibMonToolSlope
CscCalibMonTool = CscCalibMonToolSlope(name="CscCalibMonToolSlope")
ToolSvc += CscCalibMonTool
##CscCalibMonTool.OutputLevel = DEBUG
monMan.AthenaMonTools += [CscCalibMonTool]
#Conditions DB service
#from IOVDbSvc.CondDB import conddb
#conddb.setGlobalTag("COMCOND-003-00")
from MuonCondSvc.CscCondDB import cscCondDB
cscCondDB.addPedFolders(
)  #Set to read pedestal and noise folders from the database
cscCondDB.addPSlopeFolder()  #Set to read slope folder from database
#if(ToolSvc.CscRdoContByteStreamTool.IsCosmicData) :
#    cscCondDB.overrideBaseTag('Csc-cosmic-DEFAULTCOND')

svcMgr.MessageSvc.Format = "% F%30W%S%7W%R%T %0W%M"
svcMgr.MessageSvc.defaultLimit = 1000000

#--------------------------------------------------------------
# Set output level threshold (1=VERBOSE, 2=DEBUG, 3=INFO, 4=WARNING, 5=ERROR, 6=FATAL )
#--------------------------------------------------------------

#---------------------------------------------------------------------------
print "List all DLL"
print theApp.Dlls
print "List all ExtSvc"
print theApp.ExtSvc
示例#2
0
from MuonCondSvc.CscCoolFolders import dict as coolFolders

#Set pedestals
#Note if override strings are "", no overide will occur
if ("ped" in readPars):
    cscCondDB.addPedFolder(pedOverride)
if ("noise" in readPars):
    cscCondDB.addNoiseFolder(noiseOverride)
if ("rms" in readPars):
    cscCondDB.addRmsFolder(rmsOverride)
if ("f001" in readPars):
    cscCondDB.addF001Folder(f001Override)
if ("status" in readPars):
    cscCondDB.addStatusFolder(statOverride)
if ("pslope" in readPars):
    cscCondDB.addPSlopeFolder(pslopeOverride)
if ("t0phase" in readPars):
    cscCondDB.addT0PhaseFolder(t0phaseOverride)
if ("t0base" in readPars):
    cscCondDB.addT0BaseFolder(t0baseOverride)

#--------------------------------------------------------------
# Set output level threshold (1=VERBOSE, 2=DEBUG, 3=INFO, 4=WARNING, 5=ERROR, 6=FATAL )
#--------------------------------------------------------------
#import AthenaPoolCnvSvc.ReadAthenaPool
#ServiceMgr.MessageSvc.OutputLevel      = VERBOSE
#IOVDbSvc = Service( "IOVDbSvc" )
#IOVDbSvc.OutputLevel        = 2
#ServiceMgr.EventSelector.RunNumber		= 0
#ServiceMgr.EventSelector.FirstEvent	= 0
from IOVDbSvc.CondDB import conddb
include("RecExCond/RecExCommon_flags.py")
DetFlags.ID_setOff(
)  #speeds up and prevents problems in commissioning database
DetFlags.Calo_setOff()
include("RecExCond/AllDet_detDescr.py")

#Set up IOVDbService
#Pick a database tag. Should correspond with DetDescrVersion. See AtlasGeomDBTags page on twiki
conddb.setGlobalTag('COMCOND-ES1C-003-00')
Service("IOVDbSvc").forceRunNumber = runNumber
Service("IOVDbSvc").forceLumiblockNumber = 1

from MuonCondSvc.CscCondDB import cscCondDB
#Read from local file. Must use before "addPedFolders"
cscCondDB.addPSlopeFolder()

if ('pslopeTag' in dir()):
    print "Will override pusler slope to " + pslopeTag
    conddb.addOverride('/CSC/PSLOPE', pslopeTag)

#--------------------------------------------------------------
# Set output level threshold (1=VERBOSE, 2=DEBUG, 3=INFO, 4=WARNING, 5=ERROR, 6=FATAL )
#--------------------------------------------------------------
#import AthenaPoolCnvSvc.ReadAthenaPool
#ServiceMgr.MessageSvc.OutputLevel      = VERBOSE
#ServiceMgr.MessageSvc.verboseLimit = 20000
#ServiceMgr.MessageSvc.debugLimit = 0
#IOVDbSvc = Service( "IOVDbSvc" )
#IOVDbSvc.OutputLevel        = 2
#ServiceMgr.EventSelector.RunNumber		= 0
示例#4
0
def setupCscCondDB():
    # Access to the CSC calibration database
    # Copied and modified from:
    # include( "CscCalibTools/CscCalibTool_jobOptions.py" )
    from MuonCondSvc.CscCondDB import cscCondDB

    ## Load Ped File
    if cscCalibFlags.CscPedFromLocalFile():
        cscCondDB.useLocalFile(
            True)  #All following "add" db folder commands are from local files
        cscCondDB.addPedFolder()  #<--- Adds pedestal and noise folders
        cscCondDB.useLocalFile(
            False)  #To make sure to stop refering to local sqlite DB file
    else:
        cscCondDB.addPedFolder()  #<--- Adds pedestal and noise folders

    ## Load Noise File
    if cscCalibFlags.CscNoiseFromLocalFile():
        cscCondDB.useLocalFile(
            True)  #All following "add" db folder commands are from local files
        cscCondDB.addNoiseFolder()  #<--- Adds pedestal and noise folders
        cscCondDB.useLocalFile(
            False)  #To make sure to stop refering to local sqlite DB file
    else:
        cscCondDB.addNoiseFolder()  #<--- Adds pedestal and noise folders

    ## Load PSlope File
    if cscCalibFlags.CscPSlopeFromLocalFile():
        cscCondDB.useLocalFile(
            True)  #All following "add" db folder commands are from local files
        cscCondDB.addPSlopeFolder()  #<--- Adds pedestal and noise folders
        cscCondDB.useLocalFile(
            False)  #To make sure to stop refering to local sqlite DB file
    else:
        cscCondDB.addPSlopeFolder()  #<--- Adds pedestal and noise folders

    ## Load Status File
    if cscCalibFlags.CscStatusFromLocalFile():
        cscCondDB.useLocalFile(
            True)  #All following "add" db folder commands are from local files
        cscCondDB.addStatusFolder()  #<--- Adds pedestal and noise folders
        cscCondDB.useLocalFile(
            False)  #To make sure to stop refering to local sqlite DB file
    else:
        cscCondDB.addStatusFolder()  #<--- Adds pedestal and noise folders

    ## Load Rms File
    if cscCalibFlags.CscRmsFromLocalFile():
        cscCondDB.useLocalFile(
            True)  #All following "add" db folder commands are from local files
        cscCondDB.addRmsFolder()  #<--- Adds pedestal and noise folders
        cscCondDB.useLocalFile(
            False)  #To make sure to stop refering to local sqlite DB file
    else:
        cscCondDB.addRmsFolder()  #<--- Adds pedestal and noise folders

    ## Load F001 File
    if cscCalibFlags.CscF001FromLocalFile():
        cscCondDB.useLocalFile(
            True)  #All following "add" db folder commands are from local files
        cscCondDB.addF001Folder()
        cscCondDB.useLocalFile(
            False)  #To make sure to stop refering to local sqlite DB file
    else:
        cscCondDB.addF001Folder()

    if not athenaCommonFlags.isOnline():
        log = logging.getLogger(__name__ + ".setupCscCondDB()")
        log.info(
            "This is for OffLine so T0Base and T0Phase folders are added!!")

        ## Load T0Base File
        if cscCalibFlags.CscT0BaseFromLocalFile():
            cscCondDB.useLocalFile(
                True
            )  #All following "add" db folder commands are from local files
            cscCondDB.addT0BaseFolder()
            cscCondDB.useLocalFile(
                False)  #To make sure to stop refering to local sqlite DB file
        else:
            cscCondDB.addT0BaseFolder()

        ## Load T0Phase File
        if cscCalibFlags.CscT0PhaseFromLocalFile():
            cscCondDB.useLocalFile(
                True
            )  #All following "add" db folder commands are from local files
            cscCondDB.addT0PhaseFolder()
            cscCondDB.useLocalFile(
                False)  #To make sure to stop refering to local sqlite DB file
        else:
            cscCondDB.addT0PhaseFolder()