add angle conditioning
- extend Geometry interface with
localDirection(G4FastTrack const& aFastTrack)
- to compute the local direction in a right handed coordinate system where the z-axis points into the calorimeter, normal to the calorimeter planes - add
localDir
toModelInterface::prepareInput(...)
andModelInterface::convertOutput(...)
to allow for angular conditioning on one or two angles - implement this in RegularGridBIBAEModel
- using condition angle as local theta (polar angle) and rotate output of inference model by local azimuth angle phi
- use angular conditioning in Par04VAE
- add property
CorrectForAngle
to geometry modelsPolyhedraBarrelGeometry
andEndcapGeometry
- use
true
for GAN and Par04VAE,false
for BIB-AE
- use
Merge request reports
Activity
19 23 20 24 public: 21 25 virtual ~GeometryInterface(){}; 22 23 26 24 /** convert the local spacepoints to global spacepoints 27 /** compute local direction in coordinate system that has the z-axis pointing into the calorimeter, 28 * normal to the layers 29 */ 30 virtual G4ThreeVector localDirection(G4FastTrack const& aFastTrack) = 0; Since it doesn't mutate any internal state we might as well mark it as such. It looks like we haven't been doing this consistently for other methods which also fit this description, so maybe we should go over this again at some point.
Good point, indeed we can compute the
phiSector
andlocalDirection
w/o theinitialize
, as this is only needed for the actual layer positions. Not sure if we can call theinitialize
in the c'tor as the geometry construction might have not yet been done. Could give it a try, however, as this would clearly simplify things...changed this line in version 4 of the diff
I am not yet entirely sure if I like the design of singling out the local direction in a separate API and changing other APIs to consume the result of that. Technically we could probably hide that and keep the APIs slightly more general. However, I do see the advantage of not having to compute this over and over again.
I would suggest to keep the interfaces as proposed and revisit later, once we have a more complete picture.
added 1 commit
- 3b9a9107 - make geometry methods const where applicable
mentioned in commit 8d528355