Skip to content

Commit

Permalink
Merge pull request #45832 from bsunanda/Phase2-sim158
Browse files Browse the repository at this point in the history
Phase2-sim158 Modify the scripts in SimG4Core/PrintGeomInfo to use the right era definitions
  • Loading branch information
cmsbuild authored Aug 31, 2024
2 parents 81d28f2 + 7450e26 commit 1ccd187
Show file tree
Hide file tree
Showing 6 changed files with 252 additions and 32 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -40,12 +40,58 @@

from Configuration.Eras.Era_Phase2C17I13M9_cff import Phase2C17I13M9

if (options.geometry == "D115"):
from Configuration.Eras.Era_Phase2C20I13M9_cff import Phase2C20I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C20I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C20I13M9)
elif (options.geometry == "D104"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C22I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
elif (options.geometry == "D106"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C22I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
elif (options.geometry == "D109"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C22I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
elif (options.geometry == "D111"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C22I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
elif (options.geometry == "D112"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C22I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
elif (options.geometry == "D113"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C22I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
else:
from Configuration.Eras.Era_Phase2C17I13M9_cff import Phase2C17I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C17I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C17I13M9)

if (options.type == "DDD"):
process = cms.Process("PrintMaterialBudget",Phase2C17I13M9)
geomFile = "Configuration.Geometry.GeometryExtended2026" + options.geometry + "Reco_cff"
else:
from Configuration.ProcessModifiers.dd4hep_cff import dd4hep
process = cms.Process("PrintMaterialBudget",Phase2C17I13M9,dd4hep)
geomFile = "Configuration.Geometry.GeometryDD4hepExtended2026" + options.geometry + "Reco_cff"

print("Geometry file Name: ", geomFile)
Expand Down
61 changes: 49 additions & 12 deletions SimG4Core/PrintGeomInfo/test/python/runPrintG4Solids_cfg.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,22 +35,59 @@
# Use the options
from Configuration.ProcessModifiers.dd4hep_cff import dd4hep

if (options.geometry == "D115"):
from Configuration.Eras.Era_Phase2C20I13M9_cff import Phase2C20I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C20I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C20I13M9)
elif (options.geometry == "D104"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C22I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
elif (options.geometry == "D106"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C22I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
elif (options.geometry == "D109"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C22I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
elif (options.geometry == "D111"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C22I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
elif (options.geometry == "D112"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C22I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
elif (options.geometry == "D113"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C22I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
else:
from Configuration.Eras.Era_Phase2C17I13M9_cff import Phase2C17I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C17I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C17I13M9)

if (options.type == "DD4hep"):
geomFile = "Configuration.Geometry.GeometryDD4hepExtended2026" + options.geometry + "Reco_cff"
if (options.geometry == "D115"):
from Configuration.Eras.Era_Phase2C20I13M9_cff import Phase2C20I13M9
process = cms.Process('PrintG4Solids',Phase2C20I13M9,dd4hep)
else:
from Configuration.Eras.Era_Phase2C17I13M9_cff import Phase2C17I13M9
process = cms.Process('PrintG4Solids',Phase2C17I13M9,dd4hep)
else:
geomFile = "Configuration.Geometry.GeometryExtended2026" + options.geometry + "Reco_cff"
if (options.geometry == "D115"):
from Configuration.Eras.Era_Phase2C20I13M9_cff import Phase2C20I13M9
process = cms.Process('PrintG4Solids',Phase2C20I13M9)
else:
from Configuration.Eras.Era_Phase2C17I13M9_cff import Phase2C17I13M9
process = cms.Process('PrintG4Solids',Phase2C17I13M9)

print("Geometry file Name: ", geomFile)

Expand Down
61 changes: 49 additions & 12 deletions SimG4Core/PrintGeomInfo/test/python/runPrintG4Touch2026_cfg.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,22 +35,59 @@
# Use the options
from Configuration.ProcessModifiers.dd4hep_cff import dd4hep

if (options.geometry == "D115"):
from Configuration.Eras.Era_Phase2C20I13M9_cff import Phase2C20I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C20I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C20I13M9)
elif (options.geometry == "D104"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C22I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
elif (options.geometry == "D106"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C22I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
elif (options.geometry == "D109"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C22I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
elif (options.geometry == "D111"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C22I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
elif (options.geometry == "D112"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C22I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
elif (options.geometry == "D113"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C22I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
else:
from Configuration.Eras.Era_Phase2C17I13M9_cff import Phase2C17I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C17I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C17I13M9)

if (options.type == "DD4hep"):
geomFile = "Configuration.Geometry.GeometryDD4hepExtended2026" + options.geometry + "Reco_cff"
if (options.geometry == "D115"):
from Configuration.Eras.Era_Phase2C20I13M9_cff import Phase2C20I13M9
process = cms.Process('PrintG4Solids',Phase2C20I13M9,dd4hep)
else:
from Configuration.Eras.Era_Phase2C17I13M9_cff import Phase2C17I13M9
process = cms.Process('PrintG4Solids',Phase2C17I13M9,dd4hep)
else:
geomFile = "Configuration.Geometry.GeometryExtended2026" + options.geometry + "Reco_cff"
if (options.geometry == "D115"):
from Configuration.Eras.Era_Phase2C20I13M9_cff import Phase2C20I13M9
process = cms.Process('PrintG4Solids',Phase2C20I13M9)
else:
from Configuration.Eras.Era_Phase2C17I13M9_cff import Phase2C17I13M9
process = cms.Process('PrintG4Solids',Phase2C17I13M9)

print("Geometry file Name: ", geomFile)

Expand Down
56 changes: 51 additions & 5 deletions SimG4Core/PrintGeomInfo/test/python/runPrintSolid2026_cfg.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,15 +36,61 @@

from Configuration.Eras.Era_Phase2C17I13M9_cff import Phase2C17I13M9

if (options.geometry == "D115"):
from Configuration.Eras.Era_Phase2C20I13M9_cff import Phase2C20I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C20I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C20I13M9)
elif (options.geometry == "D104"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C22I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
elif (options.geometry == "D106"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C22I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
elif (options.geometry == "D109"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C22I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
elif (options.geometry == "D111"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C22I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
elif (options.geometry == "D112"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C22I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
elif (options.geometry == "D113"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C22I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
else:
from Configuration.Eras.Era_Phase2C17I13M9_cff import Phase2C17I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C17I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C17I13M9)

if (options.type == "DDD"):
process = cms.Process('G4PrintGeometry',Phase2C17I13M9)
geomFile = "Configuration.Geometry.GeometryExtended2026" + options.geometry + "Reco_cff"
process.load(geomFile)
else:
from Configuration.ProcessModifiers.dd4hep_cff import dd4hep
process = cms.Process('G4PrintGeometry',Phase2C17I13M9,dd4hep)
geomFile = "Configuration.Geometry.GeometryDD4hepExtended2026" + options.geometry + "Reco_cff"
process.load(geomFile)

process.load(geomFile)

print("Geometry file Name: ", geomFile)

Expand Down
36 changes: 36 additions & 0 deletions SimG4Core/PrintGeomInfo/test/python/runSens2026_cfg.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,42 @@
process = cms.Process('G4PrintGeometry',Phase2C20I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C20I13M9)
elif (options.geometry == "D104"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C22I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
elif (options.geometry == "D106"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C22I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
elif (options.geometry == "D109"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C22I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
elif (options.geometry == "D111"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C22I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
elif (options.geometry == "D112"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C22I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
elif (options.geometry == "D113"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
if (options.type == "DD4hep"):
process = cms.Process('G4PrintGeometry',Phase2C22I13M9,dd4hep)
else:
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
else:
from Configuration.Eras.Era_Phase2C17I13M9_cff import Phase2C17I13M9
if (options.type == "DD4hep"):
Expand Down
18 changes: 18 additions & 0 deletions SimG4Core/PrintGeomInfo/test/python/runSummary2026_cfg.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,24 @@
if (options.geometry == "D115"):
from Configuration.Eras.Era_Phase2C20I13M9_cff import Phase2C20I13M9
process = cms.Process('G4PrintGeometry',Phase2C20I13M9)
elif (options.geometry == "D104"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
elif (options.geometry == "D106"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
elif (options.geometry == "D109"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
elif (options.geometry == "D111"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
elif (options.geometry == "D112"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
elif (options.geometry == "D113"):
from Configuration.Eras.Era_Phase2C22I13M9_cff import Phase2C22I13M9
process = cms.Process('G4PrintGeometry',Phase2C22I13M9)
else:
from Configuration.Eras.Era_Phase2C17I13M9_cff import Phase2C17I13M9
process = cms.Process('G4PrintGeometry',Phase2C17I13M9)
Expand Down

0 comments on commit 1ccd187

Please sign in to comment.