snake.core.handlers.motion.image
#
Motion in the image domain.
TODO: Add constraints on maximal displacements TODO: Use FOV displacements
Module Contents#
Classes#
Add Random Motion in Image. |
Functions#
Apply motion to the phantom. |
API#
- class snake.core.handlers.motion.image.RandomMotionImageHandler[source]#
Bases:
snake.core.handlers.base.AbstractHandler
Add Random Motion in Image.
- Parameters:
ts_std_mm β Translation standard deviation, in mm/s.
rs_std_mm β Rotation standard deviation, in radians/s.
motion_file (str) β If provided, the motion file is loaded and resampled to match the number of frames in the simulation. The motion is then added to the data.
motion_file_tr (float) β Original TR of the motion file, in seconds.
Notes
The motion is generated by drawing from a normal distribution with standard deviation for the 6 motion parameters (3 translations and 3 rotations, in this order). Then the cumulative motion is computed by summing the motion at each frame.
The handlers is parametrized with speed in mm/s and rad/s, as these values provides an independent control of the motion amplitude regardless of the time resolution for the simulation.
- __handler_name__ = 'motion-image'#
- get_dynamic(phantom: snake.core.phantom.Phantom, sim_conf: snake.core.simulation.SimConfig) snake.core.phantom.DynamicData [source]#
Get dynamic information.