IRadon#

class deepinv.physics.functional.IRadon(in_size=None, theta=None, circle=False, use_filter=True, out_size=None, parallel_computation=True, dtype=torch.float32, device=device(type='cpu'))[source]#

Bases: Module

Inverse sparse Radon transform operator.

Parameters:
  • in_size (int) – the size of the input image. If None, the size is inferred from the input image.

  • theta (torch.Tensor) – the angles at which the Radon transform is computed. Default is torch.arange(180).

  • circle (bool) – if True, the input image is assumed to be a circle. Default is False.

  • use_filter – if True, the ramp filter is applied to the input image. Default is True.

  • out_size (int) – the size of the output image. If None, the size is the same as the input image.

  • parallel_computation (bool) – if True, all projections are performed in parallel. Requires more memory but is faster on GPUs.

  • dtype (torch.dtype) – the data type of the output. Default is torch.float.

  • device (str, torch.device) – the device of the output. Default is torch.device(‘cpu’).

forward(x, filtering=True)[source]#

Define the computation performed at every call.

Should be overridden by all subclasses.

Note

Although the recipe for forward pass needs to be defined within this function, one should call the Module instance afterwards instead of this since the former takes care of running the registered hooks while the latter silently ignores them.