Examples

This section demonstrates practical applications of the low-level diffct engine (Torch/CUDA) for various computed tomography (CT) reconstruction tasks; the same operations are available portably through the unified diffct_mlx API (see Getting Started). Each example provides comprehensive mathematical background, implementation details, and complete working code. The supporting Python scripts live under examples/circular_trajectory and examples/non_circular_trajectory in the repository.

The examples are organized into two main categories:

Analytical Reconstruction Methods - Filtered backprojection (FBP) algorithms for direct reconstruction - Standard analytical approaches used in clinical and research settings

Iterative Reconstruction Methods - Gradient-based optimization approaches using differentiable operators - Advanced reconstruction techniques with regularization capabilities