-
Notifications
You must be signed in to change notification settings - Fork 4.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Run3-gex110 Recover BHM placements in the dd4hep scenario #36648
Merged
Merged
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
There are no files selected for viewing
59 changes: 59 additions & 0 deletions
59
Geometry/ForwardCommonData/data/dd4hep/testForwardGeometry.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
<?xml version="1.0"?> | ||
<DDDefinition> | ||
<debug> | ||
<!-- | ||
<debug_rotations/> | ||
<debug_includes/> | ||
<debug_volumes/> | ||
<debug_constants/> | ||
<debug_shapes/> | ||
<debug_includes/> | ||
<debug_materials/> | ||
<debug_namespaces/> | ||
<debug_placements/> | ||
<debug_algorithms/> | ||
<debug_materials/> | ||
<debug_visattr/> | ||
--> | ||
</debug> | ||
|
||
<open_geometry/> | ||
<close_geometry/> | ||
|
||
<IncludeSection> | ||
<Include ref="Geometry/CMSCommonData/data/materials/2021/v3/materials.xml"/> | ||
<Include ref="Geometry/CMSCommonData/data/rotations.xml"/> | ||
<Include ref="Geometry/CMSCommonData/data/extend/v3/cmsextent.xml"/> | ||
<Include ref="Geometry/CMSCommonData/data/cavernData/2021/v1/cavernData.xml"/> | ||
<Include ref="Geometry/CMSCommonData/data/cms/2021/v3/cms.xml"/> | ||
<Include ref="Geometry/CMSCommonData/data/cmsMother.xml"/> | ||
<Include ref="Geometry/CMSCommonData/data/eta3/etaMax.xml"/> | ||
<Include ref="Geometry/TrackerCommonData/data/pixfwdCommon.xml"/> | ||
<Include ref="Geometry/ForwardCommonData/data/pixfwd.xml"/> | ||
<Include ref="Geometry/HcalCommonData/data/average/hcalforwardmaterial.xml"/> | ||
<Include ref="Geometry/ForwardCommonData/data/forward/2021/v1/forward.xml"/> | ||
<Include ref="Geometry/ForwardCommonData/data/totemt2/2021/v1/totemt2.xml"/> | ||
<Include ref="Geometry/ForwardCommonData/data/forwardshield/2021/v1/forwardshield.xml"/> | ||
<Include ref="Geometry/ForwardCommonData/data/bhm.xml"/> | ||
<Include ref="Geometry/ForwardCommonData/data/pltbcm/2021/v1/pltbcm.xml"/> | ||
<Include ref="Geometry/ForwardCommonData/data/bcm1f/2021/v1/bcm1f.xml"/> | ||
<Include ref="Geometry/ForwardCommonData/data/plt/2021/v1/plt.xml"/> | ||
<Include ref="Geometry/ForwardSimData/data/bcm1fsens.xml"/> | ||
<Include ref="Geometry/ForwardCommonData/data/zdcmaterials/2021/v1/zdcmaterials.xml"/> | ||
<Include ref="Geometry/ForwardCommonData/data/lumimaterials.xml"/> | ||
<Include ref="Geometry/ForwardCommonData/data/zdcrotations.xml"/> | ||
<Include ref="Geometry/ForwardCommonData/data/lumirotations.xml"/> | ||
<Include ref="Geometry/ForwardCommonData/data/zdc/2021/v1/zdc.xml"/> | ||
<Include ref="Geometry/ForwardCommonData/data/zdclumi/2021/v2/zdclumi.xml"/> | ||
<Include ref="Geometry/ForwardCommonData/data/cmszdc.xml"/> | ||
<Include ref="Geometry/ForwardSimData/data/pltsens.xml"/> | ||
<Include ref="Geometry/ForwardSimData/data/bcm1fsens.xml"/> | ||
<Include ref="Geometry/ForwardSimData/data/totemsensT2/2021/totemsensT2.xml"/> | ||
<Include ref="Geometry/ForwardSimData/data/zdcsens.xml"/> | ||
<Include ref="Geometry/ForwardSimData/data/bhmProdCuts/2021/v1/bhmProdCuts.xml"/> | ||
<Include ref="Geometry/ForwardSimData/data/zdcProdCuts/2021/v2/zdcProdCuts.xml"/> | ||
<Include ref="Geometry/ForwardSimData/data/ForwardShieldProdCuts.xml"/> | ||
<Include ref="Geometry/CMSCommonData/data/FieldParameters.xml"/> | ||
</IncludeSection> | ||
|
||
</DDDefinition> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,63 @@ | ||
<?xml version="1.0"?> | ||
<DDDefinition> | ||
|
||
<ConstantsSection label="pixfwd.xml" eval="true"> | ||
<Constant name="CylindersOuterRmin" value="168.00*mm"/> | ||
<Constant name="CylindersOuterRmax" value="174.50*mm"/> | ||
<Constant name="CylindersOuterLength" value="2101.09*mm"/> | ||
<Constant name="CylindersEndFlangeLength" value="41.30*mm"/> | ||
<Constant name="RootRadius" value="[CylindersOuterRmax]"/> | ||
<Constant name="RootHalfLength" value="[CylindersOuterLength]/2. + [CylindersEndFlangeLength]/2."/> | ||
<Constant name="AnchorZ" value="0.*mm"/> | ||
<Constant name="ZPixelForward" value="291.*mm"/> | ||
<Constant name="RootStartZ" value="-4*mm"/> | ||
<Constant name="RootMidZ1" value="[cms:TrackLumiZ1]-[ZPixelForward]"/> | ||
<Constant name="RootMidZ2" value="[cms:TrackLumiZ2]-[ZPixelForward]"/> | ||
<Constant name="RootMidZ3" value="[cms:TrackBeamZ1]-[ZPixelForward]"/> | ||
<Constant name="RootEndZ" value="2*[RootHalfLength]"/> | ||
<Constant name="DiskHalfWidth" value="36.625*mm"/> <!-- 37.5*mm --> | ||
<Constant name="Disk1Z" value="[DiskHalfWidth]"/> | ||
</ConstantsSection> | ||
|
||
<SolidSection label="pixfwd.xml"> | ||
<Polycone name="PixelForwardZplus" startPhi="0*deg" deltaPhi="360*deg" > | ||
<ZSection z="[RootStartZ]" rMin="[cms:TrackBeamR1]" rMax="[RootRadius]"/> | ||
<ZSection z="[RootMidZ1]" rMin="[cms:TrackBeamR11]" rMax="[RootRadius]"/> | ||
<ZSection z="[RootMidZ2]" rMin="[cms:TrackBeamR11]" rMax="[RootRadius]"/> | ||
<ZSection z="[RootMidZ3]" rMin="[cms:TrackBeamR12]" rMax="[RootRadius]"/> | ||
<ZSection z="[RootEndZ]" rMin="[cms:TrackBeamR2]" rMax="[RootRadius]"/> | ||
</Polycone> | ||
<Polycone name="PixelForwardZminus" startPhi="0*deg" deltaPhi="360*deg" > | ||
<ZSection z="-[RootEndZ]" rMin="[cms:TrackBeamR2]" rMax="[RootRadius]"/> | ||
<ZSection z="-[RootMidZ3]" rMin="[cms:TrackBeamR12]" rMax="[RootRadius]"/> | ||
<ZSection z="-[RootMidZ2]" rMin="[cms:TrackBeamR11]" rMax="[RootRadius]"/> | ||
<ZSection z="-[RootMidZ1]" rMin="[cms:TrackBeamR11]" rMax="[RootRadius]"/> | ||
<ZSection z="-[RootStartZ]" rMin="[cms:TrackBeamR1]" rMax="[RootRadius]"/> | ||
</Polycone> | ||
</SolidSection> | ||
|
||
<LogicalPartSection label="pixfwd.xml"> | ||
<LogicalPart name="PixelForwardZplus" category="envelope"> | ||
<rSolid name="PixelForwardZplus"/> | ||
<rMaterial name="materials:Air"/> | ||
</LogicalPart> | ||
<LogicalPart name="PixelForwardZminus" category="envelope"> | ||
<rSolid name="PixelForwardZminus"/> | ||
<rMaterial name="materials:Air"/> | ||
</LogicalPart> | ||
</LogicalPartSection> | ||
|
||
<PosPartSection label="pixfwd.xml"> | ||
<PosPart copyNumber="1"> | ||
<rParent name="cms:CMSE"/> | ||
<rChild name="pixfwd:PixelForwardZplus"/> | ||
<Translation x="0*mm" y="0*mm" z="[ZPixelForward]"/> | ||
</PosPart> | ||
<PosPart copyNumber="2"> | ||
<rParent name="cms:CMSE"/> | ||
<rChild name="pixfwd:PixelForwardZminus"/> | ||
<Translation x="0*mm" y="0*mm" z="-[ZPixelForward]"/> | ||
</PosPart> | ||
</PosPartSection> | ||
|
||
</DDDefinition> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
import FWCore.ParameterSet.Config as cms | ||
|
||
XMLIdealGeometryESSource = cms.ESSource("XMLIdealGeometryESSource", | ||
geomXMLFiles = cms.vstring( | ||
'Geometry/CMSCommonData/data/materials/2021/v3/materials.xml', | ||
'Geometry/CMSCommonData/data/rotations.xml', | ||
'Geometry/CMSCommonData/data/extend/v3/cmsextent.xml', | ||
'Geometry/CMSCommonData/data/cavernData/2021/v1/cavernData.xml', | ||
'Geometry/CMSCommonData/data/cms/2021/v3/cms.xml', | ||
'Geometry/CMSCommonData/data/cmsMother.xml', | ||
'Geometry/CMSCommonData/data/eta3/etaMax.xml', | ||
'Geometry/TrackerCommonData/data/pixfwdCommon.xml', | ||
'Geometry/ForwardCommonData/data/pixfwd.xml', | ||
'Geometry/HcalCommonData/data/average/hcalforwardmaterial.xml', | ||
'Geometry/ForwardCommonData/data/forward/2021/v1/forward.xml', | ||
'Geometry/ForwardCommonData/data/totemt2/2021/v1/totemt2.xml', | ||
'Geometry/ForwardCommonData/data/forwardshield/2021/v1/forwardshield.xml', | ||
'Geometry/ForwardCommonData/data/bhm.xml', | ||
'Geometry/ForwardCommonData/data/pltbcm/2021/v1/pltbcm.xml', | ||
'Geometry/ForwardCommonData/data/bcm1f/2021/v1/bcm1f.xml', | ||
'Geometry/ForwardCommonData/data/plt/2021/v1/plt.xml', | ||
'Geometry/ForwardSimData/data/bcm1fsens.xml', | ||
'Geometry/ForwardCommonData/data/zdcmaterials/2021/v1/zdcmaterials.xml', | ||
'Geometry/ForwardCommonData/data/lumimaterials.xml', | ||
'Geometry/ForwardCommonData/data/zdcrotations.xml', | ||
'Geometry/ForwardCommonData/data/lumirotations.xml', | ||
'Geometry/ForwardCommonData/data/zdc/2021/v1/zdc.xml', | ||
'Geometry/ForwardCommonData/data/zdclumi/2021/v2/zdclumi.xml', | ||
'Geometry/ForwardCommonData/data/cmszdc.xml', | ||
'Geometry/ForwardSimData/data/pltsens.xml', | ||
'Geometry/ForwardSimData/data/bcm1fsens.xml', | ||
'Geometry/ForwardSimData/data/totemsensT2/2021/totemsensT2.xml', | ||
'Geometry/ForwardSimData/data/zdcsens.xml', | ||
'Geometry/ForwardSimData/data/bhmProdCuts/2021/v1/bhmProdCuts.xml', | ||
'Geometry/ForwardSimData/data/zdcProdCuts/2021/v2/zdcProdCuts.xml', | ||
'Geometry/ForwardSimData/data/ForwardShieldProdCuts.xml', | ||
'Geometry/CMSCommonData/data/FieldParameters.xml', | ||
), | ||
rootNodeName = cms.string('cms:OCMS') | ||
) |
53 changes: 53 additions & 0 deletions
53
Geometry/ForwardCommonData/test/g4OverlapCheckForwardDD4hep_cfg.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
import FWCore.ParameterSet.Config as cms | ||
from Configuration.ProcessModifiers.dd4hep_cff import dd4hep | ||
|
||
process = cms.Process("G4PrintGeometry",dd4hep) | ||
|
||
process.DDDetectorESProducer = cms.ESSource("DDDetectorESProducer", | ||
confGeomXMLFiles = cms.FileInPath('Geometry/ForwardCommonData/data/dd4hep/testForwardGeometry.xml'), | ||
appendToDataLabel = cms.string('') | ||
) | ||
process.DDSpecParRegistryESProducer = cms.ESProducer("DDSpecParRegistryESProducer", | ||
appendToDataLabel = cms.string('') | ||
) | ||
process.DDVectorRegistryESProducer = cms.ESProducer("DDVectorRegistryESProducer", | ||
appendToDataLabel = cms.string('')) | ||
process.DDCompactViewESProducer = cms.ESProducer("DDCompactViewESProducer", | ||
appendToDataLabel = cms.string('') | ||
) | ||
|
||
process.load('FWCore.MessageService.MessageLogger_cfi') | ||
|
||
if 'MessageLogger' in process.__dict__: | ||
process.MessageLogger.SimG4CoreApplication=dict() | ||
process.MessageLogger.G4cout=dict() | ||
process.MessageLogger.ForwardGeom=dict() | ||
|
||
from SimG4Core.PrintGeomInfo.g4TestGeometry_cfi import * | ||
process = checkOverlap(process) | ||
|
||
# enable Geant4 overlap check | ||
process.g4SimHits.CheckGeometry = True | ||
|
||
# Geant4 geometry check | ||
process.g4SimHits.G4CheckOverlap.OutputBaseName = cms.string("forward") | ||
process.g4SimHits.G4CheckOverlap.OverlapFlag = cms.bool(True) | ||
process.g4SimHits.G4CheckOverlap.Tolerance = cms.double(0.0) | ||
process.g4SimHits.G4CheckOverlap.Resolution = cms.int32(10000) | ||
# tells if NodeName is G4Region or G4PhysicalVolume | ||
process.g4SimHits.G4CheckOverlap.RegionFlag = cms.bool(False) | ||
# list of names | ||
process.g4SimHits.G4CheckOverlap.NodeNames = cms.vstring('cms:CMSE_1') | ||
# enable dump gdml file | ||
process.g4SimHits.G4CheckOverlap.gdmlFlag = cms.bool(False) | ||
# if defined a G4PhysicsVolume info is printed | ||
process.g4SimHits.G4CheckOverlap.PVname = '' | ||
# if defined a list of daughter volumes is printed | ||
process.g4SimHits.G4CheckOverlap.LVname = '' | ||
|
||
# extra output files, created if a name is not empty | ||
process.g4SimHits.FileNameField = '' | ||
process.g4SimHits.FileNameGDML = '' | ||
process.g4SimHits.FileNameRegions = '' | ||
# | ||
process.g4SimHits.OnlySDs = cms.vstring('ZdcSensitiveDetector', 'TotemT2ScintSensitiveDetector', 'TotemSensitiveDetector', 'BCM1FSensitiveDetector', 'BHMSensitiveDetector', 'PLTSensitiveDetector') |
40 changes: 40 additions & 0 deletions
40
Geometry/ForwardCommonData/test/g4OverlapCheckForwardDDD_cfg.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
import FWCore.ParameterSet.Config as cms | ||
|
||
process = cms.Process("G4PrintGeometry") | ||
|
||
process.load("Geometry.ForwardCommonData.testForwardXML_cfi") | ||
process.load('FWCore.MessageService.MessageLogger_cfi') | ||
|
||
if 'MessageLogger' in process.__dict__: | ||
process.MessageLogger.SimG4CoreApplication=dict() | ||
process.MessageLogger.G4cout=dict() | ||
process.MessageLogger.ForwardGeom=dict() | ||
|
||
from SimG4Core.PrintGeomInfo.g4TestGeometry_cfi import * | ||
process = checkOverlap(process) | ||
|
||
# enable Geant4 overlap check | ||
process.g4SimHits.CheckGeometry = True | ||
|
||
# Geant4 geometry check | ||
process.g4SimHits.G4CheckOverlap.OutputBaseName = cms.string("forward") | ||
process.g4SimHits.G4CheckOverlap.OverlapFlag = cms.bool(True) | ||
process.g4SimHits.G4CheckOverlap.Tolerance = cms.double(0.0) | ||
process.g4SimHits.G4CheckOverlap.Resolution = cms.int32(10000) | ||
# tells if NodeName is G4Region or G4PhysicalVolume | ||
process.g4SimHits.G4CheckOverlap.RegionFlag = cms.bool(False) | ||
# list of names | ||
process.g4SimHits.G4CheckOverlap.NodeNames = cms.vstring('CMSE') | ||
# enable dump gdml file | ||
process.g4SimHits.G4CheckOverlap.gdmlFlag = cms.bool(False) | ||
# if defined a G4PhysicsVolume info is printed | ||
process.g4SimHits.G4CheckOverlap.PVname = '' | ||
# if defined a list of daughter volumes is printed | ||
process.g4SimHits.G4CheckOverlap.LVname = '' | ||
|
||
# extra output files, created if a name is not empty | ||
process.g4SimHits.FileNameField = '' | ||
process.g4SimHits.FileNameGDML = '' | ||
process.g4SimHits.FileNameRegions = '' | ||
# | ||
process.g4SimHits.OnlySDs = cms.vstring('ZdcSensitiveDetector', 'TotemT2ScintSensitiveDetector', 'TotemSensitiveDetector', 'BCM1FSensitiveDetector', 'BHMSensitiveDetector', 'PLTSensitiveDetector') |
File renamed without changes.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This file should have a version number in the directory name, maybe
Geometry/ForwardCommonData/data/forward/2021/v1/pixfwd.xml
?