Beispiel #1
0
    def configureReco(self):
        from AthenaCommon.DetFlags import DetFlags
        DetFlags.Muon_setOn()
        DetFlags.Calo_setOff()

        recAlgsFlags.doMuonIDStandAlone = False
        recAlgsFlags.doMuonIDCombined = False

        # add some more flags available for standalone running
        import MuonRecExample.MuonRecStandaloneFlags

        # configure flags so that only Muon Standalone reco is run
        import MuonRecExample.MuonRecStandaloneOnlySetup

        muonRecFlags.useAlignmentCorrections = mualign.useOpticalAlignment()

        # cosmics setup
        #if align.dataType()=='cosmic' or align.dataType()=='simCosmic':

        ##### no more flags after this line #####
        print "align.dataType()=", align.dataType()
        if align.dataType() == 'data' or align.dataType() == 'cosmic':
            muonRecTopOptions = "MuonAlignGenTools/MuonDataRec_myTopOptions.py"
        else:
            muonRecTopOptions = "MuonRecExample/MuonRec_topOptions.py"
        try:
            include(muonRecTopOptions)

        ###### put any user finetuning before this line #####
        except:
            # always write config so far for debugging
            from AthenaCommon.ConfigurationShelve import saveToAscii
            saveToAscii("config.txt")
            # but still exit with error
            raise
Beispiel #2
0
 def setFullReco(self, doFullReco=True):
     mualign.useFullReco = doFullReco
     from AthenaCommon.DetFlags import DetFlags
     DetFlags.Muon_setOn()
     if doFullReco:
         DetFlags.ID_setOn()
         # align.fitterType should be set by L1MdtEndcapOnlyFlags.py
         if align.fitterType == 'CombMuonTrackFitter':
             align.useSLFitter = False
     else:
         align.fitterType = 'MCTB'
Beispiel #3
0
# digitizationFlags.doInDetNoise=True
# digitizationFlags.doCaloNoise=True
# digitizationFlags.doMuonNoise=True
# digitizationFlags.doLowPtMinBias=True
# digitizationFlags.numberOfLowPtMinBias=2.3
# digitizationFlags.LowPtMinBiasInputCols=["", "", "" ]
# digitizationFlags.doCavern=True
# digitizationFlags.numberOfCavern=2
# digitizationFlags.cavernInputCols=["", ""]
# digitizationFlags.doBeamGas=True
# digitizationFlags.numberOfBeamGas=0.5
# digitizationFlags.beamGasInputCols=["", ""]

#--------------------------------------------------------------
# Global flags. Like eg the DD version:
#--------------------------------------------------------------
from AthenaCommon.GlobalFlags import globalflags
globalflags.DetDescrVersion = 'ATLAS-GEO-20-00-01'

#--------------------------------------------------------------------
# DetFlags. Use to turn on/off individual subdetector or LVL1 trigger
#--------------------------------------------------------------------
from AthenaCommon.DetFlags import DetFlags
DetFlags.ID_setOn()
DetFlags.Calo_setOn()
DetFlags.Muon_setOn()
DetFlags.Truth_setOn()
DetFlags.LVL1_setOn()

include("Digitization/Digitization.py")
Beispiel #4
0
if vp1FilterEvents:
    import DumpGeo.VP1EvtFilter
    vp1FilterEvents = DumpGeo.VP1EvtFilter.parseFilterString(vp1FilterEvents)
    DumpGeo.VP1EvtFilter.installEventFilter(vp1FilterEvents)

from AthenaCommon.AlgSequence import AlgSequence
topSequence = AlgSequence()

#Detector setup:
from AthenaCommon.DetFlags import DetFlags
if (vp1ID): DetFlags.ID_setOn()
else: DetFlags.ID_setOff()
if (vp1Calo): DetFlags.Calo_setOn()
else: DetFlags.Calo_setOff()
if (vp1Muon): DetFlags.Muon_setOn()
else: DetFlags.Muon_setOff()
if (vp1LUCID): DetFlags.Lucid_setOn()
else: DetFlags.Lucid_setOff()
if (vp1ALFA): DetFlags.ALFA_setOn()
else: DetFlags.ALFA_setOff()
if (vp1ForwardRegion): DetFlags.FwdRegion_setOn()
else: DetFlags.FwdRegion_setOff()
if (vp1ZDC): DetFlags.ZDC_setOn()
else: DetFlags.ZDC_setOff()
DetFlags.Print()
if (vp1CustomGeometry):
    print "Configuring Custom geometry."
if (vp1SLHC):
    print "Setting up SLHC configuration"
    rec.doTrigger.set_Value_and_Lock(False)
Beispiel #5
0
    def configureReco(self):

        from AthenaCommon.DetFlags import DetFlags
        DetFlags.Muon_setOn()
        DetFlags.ID_setOn()

        #==============================================================
        # Job Configuration parameters:
        #==============================================================
        # Signal to include file that this is not the postOptions,
        # in case the jobConfig is also the postOptions
        isPostOptions = False

        #--- Configuration part: ---------------------------------------
        doRestrictedESD = recConfig.restrictedESD
        doMinimalRec = recConfig.doMinimalRec
        doBackTracking = recConfig.doBackTracking

        indetRecos = ('xKalman', 'iPatRec', 'newTracking')
        doAODall = False  # TODO: = recConfig.<something>
        # set all known flags to False
        for reco in indetRecos:
            exec 'do%s = False' % reco

        #
        # set requested flags to True
        #
        recosOn = []
        recosAll = list(indetRecos)
        if 'all' in recConfig.doIndetReco:
            # add all known indet recos
            for reco in indetRecos:
                recosOn.append(reco)

        # add all requested recos (avoid doubles)
        for reco in recConfig.doIndetReco:
            if reco != 'all':
                if reco not in recosOn: recosOn.append(reco)
                if reco not in recosAll: recosAll.append(reco)
        for reco in recosOn:
            exec 'do%s = True' % reco

        # Determine doAODall flag
        doAODall = True
        for reco in indetRecos:
            if reco not in recosOn:
                doAODall = False
                break

        # Switch off some parts of combined reco
        if 'doObjMissingET' in recConfig.combinedRecoOff:
            doObjMissingET = False

        include("RecExCond/RecExCommon_flags.py")

        # Switch off sub-detectors
        for detOff in recConfig.detectorsOff:
            cmd = 'DetFlags.%s_setOff()' % detOff
            try:
                exec cmd
                recoLog.info(cmd)
            except AttributeError:
                recoLog.error("Can not switch off detector %s", detOff)
                raise

        if 'InDetFlags' in dir():
            InDetFlags.usePrimVertexZcoordinate(
                recConfig.usePrimVertexZcoordinate)
            InDetFlags.doSlimming = recConfig.enableTrackSlimming

        #--------------------------------------------------------------
        # Do the job!
        #--------------------------------------------------------------
        include("RecExCommon/RecExCommon_topOptions.py")

        #
        # Include user options
        #
        if recConfig.postOptionsESD:
            # Signal to include file that this is the postOptions,
            # in case the jobConfig is also the postOptions
            isPostOptions = True
            include(recConfig.postOptionsESD)