elsa generators¶
Table of Contents
Phantoms¶
-
template<typename
data_t
>
DataContainer<data_t>elsa::phantoms
::
modifiedSheppLogan
(IndexVector_t sizes)¶ Create a modified Shepp-Logan phantom in 2d or 3d (with enhanced contrast).
The phantom specifications are adapted from Matlab (which in turn references A.K. Jain, “Fundamentals of Digital Image Processing”, p. 439, and P.A. Toft, “The Radon Transform,
Theory and Implementation”, p. 199).
Warning: the 3D version is currently very inefficient to compute (cubic algorithm).
- Return
DataContainer of specified size containing the phantom.
- Parameters
[in] sizes
: a 2d/3d vector indicating the requested size (has to be square!)
-
template<typename
data_t
>
DataContainer<data_t>elsa::phantoms
::
forbildHead
(IndexVector_t sizes)¶
-
template<typename
data_t
>
DataContainer<data_t>elsa::phantoms
::
forbildAbdomen
(IndexVector_t sizes)¶
-
template<typename
data_t
>
DataContainer<data_t>elsa::phantoms
::
forbildThorax
(IndexVector_t sizes)¶
CircleTrajectoryGenerator¶
-
class
elsa
::
CircleTrajectoryGenerator
: public elsa::BaseCircleTrajectoryGenerator¶ Generator for traditional circular trajectories as used in X-ray Computed Tomography (for 2d/3d).
- Author
Maximilan Hornung - initial code
- Author
Tobias Lasser - modernization, fixes
- Author
Julia Spindler, Robert Imschweiler - restructuring
Public Static Functions
-
std::unique_ptr<PlanarDetectorDescriptor>
createTrajectory
(index_t numberOfPoses, const DataDescriptor &volumeDescriptor, index_t arcDegrees, real_t sourceToCenter, real_t centerToDetector, std::optional<RealVector_t> principalPointOffset = std::nullopt, std::optional<RealVector_t> centerOfRotOffset = std::nullopt, std::optional<IndexVector_t> detectorSize = std::nullopt, std::optional<RealVector_t> detectorSpacing = std::nullopt)¶ Generate a list of geometries corresponding to a circular trajectory around a volume.
Please note: the first pose will be at 0 degrees, the last pose will be at arcDegrees For example: 3 poses over a 180 arc will yield: 0, 90, 180 degrees.
- Return
a pair containing the list of geometries with a circular trajectory, and the sinogram data descriptor
- Parameters
numberOfPoses
: the number of (equally spaced) acquisition poses to be generatedvolumeDescriptor
: the volume around which the trajectory should goarcDegrees
: the size of the arc of the circle covered by the trajectory (in degrees, 360 for full circle)sourceToCenter
: the distance of the X-ray source to the center of the volumecenterToDetector
: the distance of the center of the volume to the X-ray detector
Please note: the sinogram size/spacing will match the volume size/spacing.
-
std::unique_ptr<PlanarDetectorDescriptor>
trajectoryFromAngles
(const std::vector<real_t> &thetas, const DataDescriptor &volumeDescriptor, real_t sourceToCenter, real_t centerToDetector, std::optional<RealVector_t> principalPointOffset = std::nullopt, std::optional<RealVector_t> centerOfRotOffset = std::nullopt, std::optional<IndexVector_t> detectorSize = std::nullopt, std::optional<RealVector_t> detectorSpacing = std::nullopt)¶ Generate a list of geometries corresponding to a circular trajectory around a volume.
- Return
a pair containing the list of geometries with a circular trajectory, and the sinogram data descriptor
- Parameters
thetas
: Sequence of degreesvolumeDescriptor
: the volume around which the trajectory should gosourceToCenter
: the distance of the X-ray source to the center of the volumecenterToDetector
: the distance of the center of the volume to the X-ray detector
SphereTrajectoryGenerator¶
-
class
elsa
::
SphereTrajectoryGenerator
: public elsa::TrajectoryGenerator¶ Generator for spherical trajectories as used in X-ray Computed Tomography (for 2d/3d).
- Author
Michael Loipführer - initial code
Public Static Functions
-
std::unique_ptr<DetectorDescriptor>
createTrajectory
(index_t numberOfPoses, const DataDescriptor &volumeDescriptor, index_t numberOfCircles, geometry::SourceToCenterOfRotation sourceToCenter, geometry::CenterOfRotationToDetector centerToDetector)¶ Generate a list of geometries corresponding to a spherical trajectory around a volume. The spherical trajectory is made up of multiple circular trajectories around the volume.
Please note: the sinogram size/spacing will match the volume size/spacing.
- Return
a DetectorDescriptor describing the spherical trajectory
- Parameters
numberOfPoses
: the number of (equally spaced) acquisition poses to be generatedvolumeDescriptor
: the volume around which the trajectory should gonumberOfCircles
: the number of circular trajectories this acquisition path is made up ofsourceToCenter
: the distance of the X-ray source to the center of the volumecenterToDetector
: the distance of the center of the volume to the X-ray detector
TODO: Make it possible to return either PlanarDetectorDescriptor, or CurvedDetectorDescriptor
PlanarHelixTrajectoryGenerator¶
-
class
elsa
::
PlanarHelixTrajectoryGenerator
: public elsa::BaseHelixTrajectoryGenerator¶ Generator for helical trajectories as used in X-ray Computed Tomography (for 3d).
- Author
Fabian Degen - initial code
Public Static Functions
-
std::unique_ptr<PlanarDetectorDescriptor>
createTrajectory
(const DataDescriptor &volumeDescriptor, std::vector<real_t> thetas, real_t pitch, real_t sourceToCenter, real_t centerToDetector, std::optional<RealVector_t> principalPointOffset = std::nullopt, std::optional<RealVector_t> centerOfRotOffset = std::nullopt, std::optional<IndexVector_t> detectorSize = std::nullopt, std::optional<RealVector_t> detectorSpacing = std::nullopt)¶ Generate a list of geometries corresponding to a helical trajectory around a volume captured on a planar detector.
Please note: the sinogram size/spacing will match the volume size/spacing.
- Return
a pair containing the list of geometries with a helical trajectory, and the sinogram data descriptor
- Parameters
volumeDescriptor
: the volume around which the trajectory should gothetas
: array of acquisition anglespitch
: the distance a helix advances along its central axis per one complete turnsourceToCenter
: the distance of the X-ray source to the center of the volumecenterToDetector
: the distance of the center of the volume to the X-ray detector
CurvedHelixTrajectoryGenerator¶
-
class
elsa
::
CurvedHelixTrajectoryGenerator
: public elsa::BaseHelixTrajectoryGenerator¶ Generator for helical trajectories as used in X-ray Computed Tomography (for 3d).
- Author
Fabian Degen - initial code
Public Static Functions
-
std::unique_ptr<CurvedDetectorDescriptor>
createTrajectory
(const DataDescriptor &volumeDescriptor, std::vector<real_t> thetas, real_t pitch, real_t sourceToCenter, real_t centerToDetector, geometry::Radian angle, std::optional<RealVector_t> principalPointOffset = std::nullopt, std::optional<RealVector_t> centerOfRotOffset = std::nullopt, std::optional<IndexVector_t> detectorSize = std::nullopt, std::optional<RealVector_t> detectorSpacing = std::nullopt)¶ Generate a list of geometries corresponding to a helical trajectory around a volume captured on a curved detector.
Please note: the sinogram size/spacing will match the volume size/spacing.
- Return
a pair containing the list of geometries with a helical trajectory, and the sinogram data descriptor
- Parameters
volumeDescriptor
: the volume around which the trajectory should gothetas
: array of acquisition anglespitch
: the distance a helix advances along its central axis per one complete turnsourceToCenter
: the distance of the X-ray source to the center of the volumecenterToDetector
: the distance of the center of the volume to the X-ray detectorangle
: rotation angle (in radians)