# Data Analysis! # # get a handle on the ServiceManager which holds all the services from AthenaCommon.AppMgr import ServiceMgr # the POOL converters include( "ParticleBuilderOptions/AOD_PoolCnv_jobOptions.py" ) include( "ParticleBuilderOptions/McAOD_PoolCnv_jobOptions.py" ) # Read in the AOD from POOL - AOD.pool.root # this file is produced by running the AOD builders of the RDO raw data # The AOD input file import AthenaPoolCnvSvc.ReadAthenaPool #DATAPATH = '/afs/cern.ch/user/m/mwielers/maxidisk/reprocessing/c59' #DATAPATH = '/afs/cern.ch/user/d/dhayden/ATLAS/testarea/15.6.0/Trigger/TrigAnalysis/TrigEgammaAnalysis/TrigEgammaNtuple/macro/7TeVData' #DATAPATH = '/scratch0/hayden/mc09/TEST/mc08.105616.Pythia_Gee_300.merge.AOD.e355_s462_r635_t53_tid' #DATAPATH = '/tmp/data10_7TeV.00155160.physics_L1Calo.merge.AOD.f255_m471' #from glob import glob #INPUT = glob('/dat*' + '/*AOD*') # or ESD #INPUT = glob(DATAPATH + '/c59' + '/Trig*') #INPUT = glob(DATAPATH + '/*AOD*') #INPUT = glob(DATAPATH + '/Trig*') #print INPUT #ServiceMgr.EventSelector.InputCollections = INPUT #ServiceMgr.EventSelector.InputCollections = [ "data10_7TeV.00152166.physics_L1CaloEM.merge.AOD.f235_m427/","data10_7TeV.00152221.physics_L1CaloEM.merge.AOD.f238_m427/","data10_7TeV.00152214.physics_L1CaloEM.merge.AOD.f238_m427/","data10_7TeV.00152345.physics_L1CaloEM.merge.AOD.f238_m427/"] #ServiceMgr.EventSelector.InputCollections = [ "/tmp/dhayden/mc08.105603.Pythia_Zprime_ee_SSM1000.merge.AOD.e352_s462_r635_t53/" ] ServiceMgr.EventSelector.InputCollections = [ "AOD.pool.root" ] #ServiceMgr.EventSelector.InputCollections = [ "Output.pool.root" ] ServiceMgr.EventSelector.BackNavigation = False from AthenaCommon.GlobalFlags import GlobalFlags GlobalFlags.DetGeo.set_atlas() #GlobalFlags.DataSource.set_data() GlobalFlags.DataSource.set_geant4() from IOVDbSvc.CondDB import conddb ########################### GOOD RUN LIST #################### # Configure the goodrunslist selector tool #from GoodRunsLists.GoodRunsListsConf import * #ToolSvc += GoodRunsListSelectorTool() #GoodRunsListSelectorTool.GoodRunsListVec = [ 'GRLFILES/Zee/data10_7TeV.periodE.160387-161948_LBSUMM_DetStatus-v03-pass1-analysis-2010E_data_Zeechannel.xml' ] ############################################################## ## This Athena job consists of algorithms that loop over events; ## here, the (default) top sequence is used: from AthenaCommon.AlgSequence import AlgSequence, AthSequencer topSequence = AlgSequence() seq = AthSequencer("AthFilterSeq") ## AthFilterSeq is always executed before the top sequence, and is configured such that ## any follow-up sequence (eg. top sequence) is not executed in case GRLTriggerAlg1 does ## not pass the event ## In short, the sequence AthFilterSeq makes sure that all algs in the job sequence ## are skipped when an event gets rejects ###from GoodRunsListsUser.GoodRunsListsUserConf import * ###seq += GRLTriggerSelectorAlg('GRLTriggerAlg1') ###seq.GRLTriggerAlg1.GoodRunsListArray = ['Zeechannel'] ## pick up correct name from inside xml file! ###seq.GRLTriggerAlg1.TriggerSelectionRegistration = 'L1_MBTS_1' ############################################################# from RecExConfig.RecFlags import rec rec.readESD=False rec.readRDO=False rec.readAOD=True from TriggerJobOpts.TriggerConfigGetter import TriggerConfigGetter cfg = TriggerConfigGetter() ##################################################################################################################################################### # TrigDecisionTool from TrigDecisionTool.TrigDecisionToolConf import Trig__TrigDecisionTool tdt = Trig__TrigDecisionTool("TrigDecisionTool") ToolSvc += tdt tdt.OutputLevel=WARNING ToolSvc.TrigDecisionTool.Navigation.OutputLevel = WARNING from AthenaCommon.AlgSequence import AlgSequence topSequence = AlgSequence() from AnalysisExamples.AnalysisExamplesConf import MCProduction topSequence += MCProduction() #include( "JiveXML/JiveXML_jobOptionBase.py" ) #include( "JiveXML/DataTypes_AOD.py" ) # The user analysis cuts - default values to changed by the user as needed # set the names of the particle containers to be retrieved from StoreGate # must be the same name used to build the AOD container # do not touch these if you do know what you are doing #e/gamma group standard is 15GeV and 2.47 # Also Crack Region Included is 1.37 < |Eta| < 1.52. # DeltaRCut < 0.02 # Electron Parameters topSequence.MCProduction.ElectronContainer = "AtlfastElectronCollection" #topSequence.MCProduction.ElectronContainer = "ElectronAODCollection" topSequence.MCProduction.TrackMatchContainer = "egDetailAOD" topSequence.MCProduction.ElectronPtCut = 25.0*GeV topSequence.MCProduction.ElectronEtaCut = 2.47 topSequence.MCProduction.ElectronTriggerFlag = "Off" topSequence.MCProduction.MCorData = "MC" topSequence.MCProduction.LatestOQ = 167521 topSequence.MCProduction.Scale = 1 topSequence.MCProduction.ElectronMassCut = 50.0*GeV # isEM is set to egammaPID::ElectronMedium, to change go to .cxx # message level for ZeeZmmOnAOD topSequence.MCProduction.OutputLevel = INFO # Set output level threshold (2=DEBUG, 3=INFO, 4=WARNING, 5=ERROR, 6=FATAL ) ServiceMgr.MessageSvc.OutputLevel = INFO # Number of Events to process theApp.EvtMax = -1 #topSequence.ZeeZmmOnAOD.EventMax = theApp.EvtMax # setup TTree registration Service # save ROOT histograms and Tuple from GaudiSvc.GaudiSvcConf import THistSvc ServiceMgr += THistSvc() ServiceMgr.THistSvc.Output = ["AANT DATAFILE='MCProductionOutput.root' OPT='RECREATE'"] from AnalysisTools.AnalysisToolsConf import AANTupleStream topSequence += AANTupleStream() topSequence.AANTupleStream.ExtraRefNames = [ "StreamESD","Stream1" ] topSequence.AANTupleStream.OutputName = 'MCProductionOutput.root' topSequence.AANTupleStream.WriteInputDataHeader = True topSequence.AANTupleStream.OutputLevel = WARNING # Root Ntuple output file and name #theApp.HistogramPersistency = "ROOT" #theApp.HistogramPersistencySvc.OutputFile = "ZeeZmmOnAOD.root" # Method to Process Multiple AOD's Singularly! # G AOD Files #ServiceMgr.EventSelector.InputCollections = [ "/scratch0/berry/v14atlas/mcDataV14/mc08.105616.Pythia_Gee_300.recon.AOD.e355_s462_r541/AOD.026884._00001.pool.root.1" ] #ServiceMgr.EventSelector.InputCollections += [ "/scratch0/berry/v14atlas/mcDataV14/mc08.105616.Pythia_Gee_300.recon.AOD.e355_s462_r541/AOD.026884._00002.pool.root.1" ] # Z' AOD Files #ServiceMgr.EventSelector.InputCollections += [ "/scratch0/berry/v14atlas/mcDataV14/mc08.105603.Pythia_Zprime_ee_SSM1000.recon.AOD.e352_s462_r541/AOD.026021._00002.pool.root.1" ] #ServiceMgr.EventSelector.InputCollections += [ "/scratch0/berry/v14atlas/mcDataV14/mc08.105603.Pythia_Zprime_ee_SSM1000.recon.AOD.e352_s462_r541/AOD.026021._00003.pool.root.1" ]