def configure ( self ) : mlog = logging.getLogger( self._name+'::configure :' ) muonIO = MuonAlignmentIOFiles() # create tool instance from __main__ import ToolSvc from MuonAlignGenTools.MuonAlignGenToolsConf import Muon__CscAlignDBTool muonAlignDBTool = Muon__CscAlignDBTool(OutputLevel = align.OutputLevel(), ABLineDbTool = ToolSvc.MGM_AlignmentDbTool, ASZTOutputFile = muonIO.asztOutputFile(), AlternateASZTFile = str(''), SigmaOutputFile = '', SigmaInputFile = '', UseMultiLevelDbTool = mualign.doMultiLevelAlignment()) if mualign.useAlternateASZT() : muonAlignDBTool.AlternateASZTFile = muonIO.asztInputFile() self._CscAlignDBToolHandle = muonAlignDBTool if mualign.doMultiLevelAlignment : MultiLevelAlignmentDbTool = ToolSvc.MultiLevelAlignmentDbTool else: from MuonCondTool.MuonCondToolConf import MultiLevelAlignmentDbTool MultiLevelAlignmentDbTool = MultiLevelAlignmentDbTool("MultiLevelAlignmentDbTool") MultiLevelAlignmentDbTool.ABLineDbTool = ToolSvc.MGM_AlignmentDbTool mlog.info(" leaving configure" ) return True
import os from TrkAlignGenTools.AlignmentFlags import AlignmentFlags as align from MuonAlignGenTools.MuonAlignmentFlags import MuonAlignmentFlags as mualign from AthenaCommon.Constants import * from AthenaCommon.AppMgr import ToolSvc # configure muon alignment from MuonAlignGenTools.ConfigureMuonAlignment import ConfigureMuonAlignment config = ConfigureMuonAlignment() config.configureAlignment(mualign.useAlternateASZT(), align.isMC()) if align.readEventList(): from TrkAlignGenAlgs.SelectEventNumberGetter import SelectEventNumberGetter selectEvtNumber = SelectEventNumberGetter().SelectEventNumberHandle() #selectEvtNumber.EventList = "goodEvts_"+align.fileRootName()+"_iter0.txt" #selectEvtNumber.EventList = "goodEvts_iter0.txt" selectEvtNumber.EventList = align.eventList() #selectEvtNumber.EventList = "goodEvts.txt" #if mualign.doLocalErrorScaling: if 'errorScaleDb' in dir() and errorScaleDb != '': errScaleDbName = errorScaleDb errScaleDbNameSplit = errScaleDbName.rsplit("/", 1) if len(errScaleDbNameSplit) > 1: errScaleDbName = errScaleDbNameSplit[1] from IOVDbSvc.CondDB import conddb IOVDbSvc.dbConnection = "sqlite://X;schema=mycool.db;dbname=OFLP200" conddb.addFolder(