SetRegion in ConstructSDandField

Hello All,

My simulation code uses GDML files and I assign sensitive detectors based on the name of the volumes. The detectors also have a region associated with them. The current implementation defines the region and sets the sensitive detector volume within the ConstructSDandField. Is creating the region in ConstructSDandField bad practice?
Should I instead be looping through the GDMLfile and setting the region in the Construct method and performing the same task once again in the ConstructSDandField for setting the sensitive detector volume?

Many thanks
Michael

1 Like