DEAL#
- class deepinv.models.DEAL(pretrained, sigma=25.0, lam=10.0, max_iter=50, auto_scale=False, target_y_std=25.0, color=False, device=None, clamp_output=True)[source]#
Bases:
ReconstructorDeep Equilibrium Attention Least Squares (DEAL) reconstruction model.
This model solves linear inverse problems using a learned equilibrium-based regularizer combined with conjugate gradient iterations. It can be used for image restoration and reconstruction tasks such as denoising, deblurring, and computed tomography reconstruction.
This implementation is adapted from the official DEAL repository: mehrsapo/DEAL
For the original method, see Pourya et al.[1].
A pretrained network can be loaded by setting
pretrained='download'.- Parameters:
pretrained (str) – checkpoint path or
'download'.sigma (float) – noise-level parameter used by DEAL.
lam (float) – regularization strength used by the DEAL solver.
max_iter (int) – maximum number of outer fixed-point iterations.
auto_scale (bool) – if
True, rescales measurements based on their std.target_y_std (float) – target std for auto-scaling when enabled.
color (bool) – if
True, use the color DEAL variant; otherwise grayscale.device (str, None) – compute device. If
None, use CUDA if available.clamp_output (bool) – if
True, clamp output to[0, 1].
- References:
- forward(y, physics)[source]#
Run the DEAL reconstruction.
- Parameters:
y (torch.Tensor) – Measurements (e.g. sinogram).
physics (deepinv.physics.LinearPhysics) – DeepInverse linear physics operator with
__call__andA_adjoint.
- Returns:
Reconstructed image with the same spatial shape as
H^T y.- Return type: