-
Notifications
You must be signed in to change notification settings - Fork 100
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
RegexSD: change ddsim interface to use a dictionary instead of a list
Too much hassle to ensure that the list was not duplicating the entries in the list The original implementation also caused infinite loop by appending to the list that was iterated over causing ddsim to use up all the memory and not do anything Added a test with an example ddsim steering file
- Loading branch information
1 parent
e1017e3
commit 9c6040c
Showing
3 changed files
with
47 additions
and
32 deletions.
There are no files selected for viewing
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
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,16 @@ | ||
from DDSim.DD4hepSimulation import DD4hepSimulation | ||
SIM = DD4hepSimulation() | ||
|
||
# make ddsim find the sensitive detector for box of straws | ||
SIM.action.calorimeterSDTypes = ['sensitive'] | ||
|
||
SIM.filter.calo = "" | ||
|
||
# Configure the regexSD for the BoxOfStraws gas_ | ||
SIM.geometry.regexSensitiveDetector['BoxOfStrawsDet'] = {'Match': ['gas_'], | ||
'OutputLevel': 4, | ||
} | ||
|
||
|
||
# Disable userParticleHander for box of straws | ||
SIM.part.userParticleHandler = "" |