You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am trying to read a cylinder surface in from a json file. This seems to work in that I can create a cylinder surface and verify it has the dimensions of those in the json file. The problem I have is that I also have a transformation x,y,z stored in the file and when I go onto create a volume, using the surface, I am unable to take this into account.
which does not show any shift in coordinates of the cylinder (the transform is a linear shift in Z)
, so I presume the transform has not been taking into account.
I tested that the transform I read in has coordinates 0,0,0 rather than the values stored:
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hello,
I am trying to read a cylinder surface in from a json file. This seems to work in that I can create a cylinder surface and verify it has the dimensions of those in the json file. The problem I have is that I also have a transformation x,y,z stored in the file and when I go onto create a volume, using the surface, I am unable to take this into account.
I create a "nominal" cylinder here:
https://github.com/shefmarkh/acts/blob/pflowSurfaces/Tests/UnitTests/Core/Detector/PFlowSurfaces.cpp#L82
using the transform identity. ReadRadius etc are defined from the surface:
https://github.com/shefmarkh/acts/blob/pflowSurfaces/Tests/UnitTests/Core/Detector/PFlowSurfaces.cpp#L60
The test json file I have is attached, which is where the surface has been read from.
PFlowSurfaces.json
The next thing I tried is to create a volume using the transform read from the json file:
https://github.com/shefmarkh/acts/blob/pflowSurfaces/Tests/UnitTests/Core/Detector/PFlowSurfaces.cpp#L109
which does not show any shift in coordinates of the cylinder (the transform is a linear shift in Z)
, so I presume the transform has not been taking into account.
I tested that the transform I read in has coordinates 0,0,0 rather than the values stored:
https://github.com/shefmarkh/acts/blob/pflowSurfaces/Tests/UnitTests/Core/Detector/PFlowSurfaces.cpp#L102
so I suppose this is where I am going wrong. The transform was read as shown here:
https://github.com/shefmarkh/acts/blob/pflowSurfaces/Tests/UnitTests/Core/Detector/PFlowSurfaces.cpp#L44
( I also tried using the key "transform" initially, which had the same result).
Is it obvious to anyone where I am going wrong?
Thanks,
Mark
Beta Was this translation helpful? Give feedback.
All reactions