Example #1
0
## load POOL support
import AthenaPoolCnvSvc.ReadAthenaPool
svcMgr.AthenaSealSvc.OutputLevel = Lvl.ERROR

## general job configuration
from AthenaCommon.AlgSequence import AlgSequence
topSequence = AlgSequence()

#from AthenaCommon.BeamFlags import jobproperties
#jobproperties.Beam.numberOfCollisions = 8.0


## configure object key store to recognize calo cells 
from RecExConfig.ObjKeyStore import ObjKeyStore, objKeyStore
oks = ObjKeyStore()
oks.addStreamESD('CaloCellContainer', ['AllCalo'] )

## re-do topo clusters on EM scale
from CaloRec.CaloTopoClusterFlags import jobproperties
jobproperties.CaloTopoClusterFlags.doTopoClusterLocalCalib = False
jobproperties.CaloTopoClusterFlags.doCellWeightCalib = False
from CaloRec.CaloClusterTopoGetter import CaloClusterTopoGetter
CaloClusterTopoGetter()

topSequence.CaloTopoCluster.TopoCalibMoments.MomentsNames += ["ENG_CALIB_OUT_L","ENG_CALIB_FRAC_EM"]
topSequence.CaloTopoCluster.TopoCalibMoments.MatchDmType = 1 # 1=loose, 2=medium (default), 3=tight

theApp.EvtMax = -1

#--------------------------------------------------------------
# Set output level threshold (2=DEBUG, 3=INFO, 4=WARNING, 5=ERROR, 6=FATAL )
Example #2
0
## MC15a e vs p+- at 100 GeV (50k events for each dataset)
#svcMgr.EventSelector.InputCollections = ["/afs/cern.ch/user/j/jolsson/work/datasets/mc15_13TeV.422008.ParticleGun_single_ele_Pt100.recon.ESD.e4459_s2726_r7143/ESD.06642056._000019.pool.root.1"]
#svcMgr.EventSelector.InputCollections = ["/afs/cern.ch/user/j/jolsson/work/datasets/mc15_13TeV.422015.ParticleGun_single_pion_Pt100.recon.ESD.e4459_s2726_r7143/ESD.06642133._000031.pool.root.1"]

# MC16 pi- (testing dataset)
#svcMgr.EventSelector.InputCollections = ["/eos/user/m/mswiatlo/esd/mc16_13TeV.428002.ParticleGun_single_piminus_logE0p2to2000.recon.ESD.e7279_s3411_r11281/ESD.17269624._000146.pool.root.1"]
#svcMgr.EventSelector.InputCollections = ["/afs/cern.ch/work/a/angerami/private/JetML/mc16_13TeV.428000.ParticleGun_single_pi0_logE0p2to2000.recon.ESD.e7279_s3411_r11281/ESD.17269610._001596.pool.root.1"]
svcMgr.EventSelector.InputCollections = [
    "/eos/user/m/mswiatlo/esd/mc16_13TeV.428001.ParticleGun_single_piplus_logE0p2to2000.recon.ESD.e7279_s3411_r11281/ESD.17269616._000058.pool.root.1"
]
from AthenaCommon.GlobalFlags import jobproperties
jobproperties.Global.DetDescrVersion = "ATLAS-R2-2016-01-00-01"  # For MC16

from RecExConfig.ObjKeyStore import ObjKeyStore, objKeyStore
oks = ObjKeyStore()
oks.addStreamESD("CaloCellContainer", ["AllCalo"])

#Rerun topocluseters to produce calib hit moments
from CaloRec.CaloTopoClusterFlags import jobproperties
jobproperties.CaloTopoClusterFlags.doCalibHitMoments = True
from CaloRec.CaloClusterTopoGetter import CaloClusterTopoGetter
CaloClusterTopoGetter()

from AthenaCommon.AlgSequence import AlgSequence
topSequence = AlgSequence()
topSequence.CaloTopoCluster.TopoCalibMoments.MomentsNames += [
    "ENG_CALIB_TOT", "ENG_CALIB_OUT_T", "ENG_CALIB_DEAD_TOT"
]
topSequence.CaloTopoCluster.TopoCalibMoments.DMCalibrationHitContainerNames = [
    "LArCalibrationHitDeadMaterial_DEAD", "TileCalibHitDeadMaterial"
]
Example #3
0
## testing singleton-ness
m = ObjKeyStore()
b = ObjKeyStore()

assert m is b
assert m is ObjKeyStore()
assert m is objKeyStore

print("empty")
print(":" * 80)
m.Print()

print("now use addStreamESD")
print(":" * 80)

m.addStreamESD('McEventCollection', ['GEN_EVENT', 'GEN_AOD', 'TruthEvent'])
m.addStreamESD('JetCollection',
               ['Cone4Jets', 'Cone7Jets', 'KtJets', 'Cone4TruthJets'])
print("." * 80)
m.Print()

print("now merge in: addMany takes a dictionary as argument")
m.addManyTypesStreamESD(thed)
print("." * 80)
m.Print()
print("now merge in: addMany with a dictionary generated on the fly")
m.addManyTypesStreamAOD({
    'JetCollection': ['Cone4Jets', 'Paraboloid'],
    'Cacatoes': 'Yellow'
})
print("." * 80)
Example #4
0
## load POOL support
import AthenaPoolCnvSvc.ReadAthenaPool

## general job configuration
from AthenaCommon.AlgSequence import AlgSequence
topSequence = AlgSequence()

from AthenaCommon.GlobalFlags import jobproperties
jobproperties.Global.DetDescrVersion = "ATLAS-R2-2016-01-00-01"

from RecExConfig.ObjKeyStore import ObjKeyStore, objKeyStore
oks = ObjKeyStore()
#oks.addStreamESD('CaloCellContainer', ['AllCalo'] )
oks.addStreamESD('CaloCalibrationHitContainer', [
    'LArCalibrationHitActive', 'LArCalibrationHitInactive',
    'LArCalibrationHitDeadMaterial_DEAD', 'TileCalibHitActiveCell',
    'TileCalibHitInactiveCell', 'TileCalibHitDeadMaterial'
])

## re-do topo clusters on EM scale
#from CaloRec.CaloRecFlags import jobproperties
#from CaloRec.CaloTopoClusterFlags import jobproperties
#jobproperties.CaloTopoClusterFlags.doTopoClusterLocalCalib = True
#jobproperties.CaloTopoClusterFlags.doCellWeightCalib = False
#from CaloRec.CaloClusterTopoGetter import CaloClusterTopoGetter, addSnapshot
#CaloClusterTopoGetter()

from AthenaCommon.DetFlags import DetFlags
DetFlags.all_setOff()
DetFlags.LAr_setOn()
DetFlags.Tile_setOn()