Skip to content
Snippets Groups Projects
Commit 7fef34e7 authored by Dave Casper's avatar Dave Casper
Browse files

Merge branch 'master-py3' into 'master'

Minor edits for (future) Python 3 compatibility

See merge request faser/calypso!73
parents df1edc3f 35c5f4a8
No related branches found
No related tags found
No related merge requests found
Showing
with 26 additions and 25 deletions
......@@ -52,7 +52,7 @@ if __name__ == "__main__":
#acc.getService("StoreGateSvc").Dump=True
acc.getService("ConditionStore").Dump=True
acc.printConfig(withDetails=True)
f=open('DipoleGMCfg2.pkl','w')
f=open('DipoleGMCfg2.pkl','wb')
acc.store(f)
f.close()
ConfigFlags.dump()
......
......@@ -52,6 +52,6 @@ if __name__ == "__main__":
ConfigFlags.lock()
acc = GeoModelCfg( ConfigFlags )
acc.store( file( "test.pkl", "w" ), useBootStrapFile = False )
acc.store( open("test.pkl", "wb"), useBootStrapFile = False )
print("All OK")
......@@ -43,7 +43,7 @@ if __name__ == "__main__":
#acc.getService("StoreGateSvc").Dump=True
acc.getService("ConditionStore").Dump=True
acc.printConfig(withDetails=True)
f=open('TrackerGMCfg2.pkl','w')
f=open('TrackerGMCfg2.pkl','wb')
acc.store(f)
f.close()
ConfigFlags.dump()
......
......@@ -52,7 +52,7 @@ if __name__ == "__main__":
#acc.getService("StoreGateSvc").Dump=True
acc.getService("ConditionStore").Dump=True
acc.printConfig(withDetails=True)
f=open('ScintGMCfg2.pkl','w')
f=open('ScintGMCfg2.pkl','wb')
acc.store(f)
f.close()
ConfigFlags.dump()
......
# Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
from __future__ import print_function
from AthenaCommon.JobProperties import jobproperties
#from AthenaCommon.DetFlags import DetFlags
......@@ -20,5 +21,5 @@ relversion = rel_metadata['release'].split('.')
if len(relversion) < 3:
relversion = rel_metadata['base release'].split('.')
print "SetGeometryVersion.py obtained major release version %s" % relversion[0]
print("SetGeometryVersion.py obtained major release version ", relversion[0])
GeoModelSvc.SupportedGeometry = int(relversion[0])
......@@ -48,7 +48,7 @@ if __name__ == "__main__":
acc.foreach_component("*ClassID*").OutputLevel = INFO
acc.printConfig(withDetails=True)
f=open('FaserGeoModelCfg_EVNT.pkl','w')
f=open('FaserGeoModelCfg_EVNT.pkl','wb')
acc.store(f)
f.close()
ConfigFlags.dump()
......
......@@ -117,6 +117,6 @@ if __name__=="__main__":
f=open("MagneticFieldSvc.pkl","w")
f=open("MagneticFieldSvc.pkl","wb")
cfg.store(f)
f.close()
......@@ -20,6 +20,6 @@ if __name__ == "__main__":
from AthenaConfiguration.ComponentAccumulator import ComponentAccumulator
from PreshowerGeoModel.PreshowerGeoModelConfig import PreshowerGeometryCfg
acc = PreshowerGeometryCfg(ConfigFlags)
f=open('PreshowerGeometryCfg.pkl','w')
f=open('PreshowerGeometryCfg.pkl','wb')
acc.store(f)
f.close()
......@@ -20,6 +20,6 @@ if __name__ == "__main__":
from AthenaConfiguration.ComponentAccumulator import ComponentAccumulator
from TriggerGeoModel.TriggerGeoModelConfig import TriggerGeometryCfg
acc = TriggerGeometryCfg(ConfigFlags)
f=open('TriggerGeometryCfg.pkl','w')
f=open('TriggerGeometryCfg.pkl','wb')
acc.store(f)
f.close()
......@@ -20,6 +20,6 @@ if __name__ == "__main__":
from AthenaConfiguration.ComponentAccumulator import ComponentAccumulator
from VetoGeoModel.VetoGeoModelConfig import VetoGeometryCfg
acc = VetoGeometryCfg(ConfigFlags)
f=open('VetoGeometryCfg.pkl','w')
f=open('VetoGeometryCfg.pkl','wb')
acc.store(f)
f.close()
......@@ -44,11 +44,11 @@ if __name__ == '__main__':
cfg.printConfig(withDetails=True, summariseProps = True)
ConfigFlags.dump()
f=open("test.pkl","w")
f=open("test.pkl","wb")
cfg.store(f)
f.close()
print cfg._publicTools
print "-----------------finished----------------------"
print(cfg._publicTools)
print("-----------------finished----------------------")
......@@ -44,11 +44,11 @@ if __name__ == '__main__':
cfg.printConfig(withDetails=True, summariseProps = True)
ConfigFlags.dump()
f=open("test.pkl","w")
f=open("test.pkl","wb")
cfg.store(f)
f.close()
print cfg._publicTools
print "-----------------finished----------------------"
print (cfg._publicTools)
print ("-----------------finished----------------------")
......@@ -44,11 +44,11 @@ if __name__ == '__main__':
cfg.printConfig(withDetails=True, summariseProps = True)
ConfigFlags.dump()
f=open("test.pkl","w")
f=open("test.pkl","wb")
cfg.store(f)
f.close()
print cfg._publicTools
print "-----------------finished----------------------"
print (cfg._publicTools)
print ("-----------------finished----------------------")
......@@ -128,7 +128,7 @@ if __name__ == "__main__":
# acc.getService("StoreGateSvc").Dump=True
# acc.getService("ConditionStore").Dump=True
# acc.printConfig()
f=open('FaserG4AppCfg_EVNT.pkl','w')
f=open('FaserG4AppCfg_EVNT.pkl','wb')
acc.store(f)
f.close()
#
......
......@@ -18,6 +18,6 @@ if __name__ == "__main__":
from AthenaConfiguration.ComponentAccumulator import ComponentAccumulator
from DipoleGeoModel.DipoleGeoModelConfig import DipoleGeometryCfg
acc = DipoleGeometryCfg(ConfigFlags)
f=open('DipoleGeometryCfg.pkl','w')
f=open('DipoleGeometryCfg.pkl','wb')
acc.store(f)
f.close()
......@@ -18,6 +18,6 @@ if __name__ == "__main__":
from AthenaConfiguration.ComponentAccumulator import ComponentAccumulator
from FaserSCT_GeoModel.FaserSCT_GeoModelConfig import FaserSCT_GeometryCfg
acc = FaserSCT_GeometryCfg(ConfigFlags)
f=open('FaserSCT_GeometryCfg.pkl','w')
f=open('FaserSCT_GeometryCfg.pkl','wb')
acc.store(f)
f.close()
......@@ -44,11 +44,11 @@ if __name__ == '__main__':
cfg.printConfig(withDetails=True, summariseProps = True)
ConfigFlags.dump()
f=open("test.pkl","w")
f=open("test.pkl","wb")
cfg.store(f)
f.close()
print cfg._publicTools
print "-----------------finished----------------------"
print(cfg._publicTools)
print("-----------------finished----------------------")
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment