deepinv.loss#

This package provides a collection of supervised and self-supervised loss functions for training reconstruction networks. Refer to the user guide for more information.

Base class#

User Guide: refer to Training Losses for more information.

deepinv.loss.Loss

Base class for all loss functions.

Supervised Learning#

User Guide: refer to Supervised Learning for more information.

deepinv.loss.SupLoss

Standard supervised loss

Self-Supervised Learning#

User Guide: refer to Self-Supervised Learning for more information.

deepinv.loss.MCLoss

Measurement consistency loss

deepinv.loss.EILoss

Equivariant imaging self-supervised loss.

deepinv.loss.MOILoss

Multi-operator imaging loss

deepinv.loss.MOEILoss

Multi-operator equivariant imaging.

deepinv.loss.Neighbor2Neighbor

Neighbor2Neighbor loss.

deepinv.loss.SplittingLoss

Measurement splitting loss.

deepinv.loss.Phase2PhaseLoss

Phase2Phase loss for dynamic data.

deepinv.loss.Artifact2ArtifactLoss

Artifact2Artifact loss for dynamic data.

deepinv.loss.SureGaussianLoss

SURE loss for Gaussian noise

deepinv.loss.SurePoissonLoss

SURE loss for Poisson noise

deepinv.loss.SurePGLoss

SURE loss for Poisson-Gaussian noise

deepinv.loss.TVLoss

Total variation loss (\(\ell_2\) norm).

deepinv.loss.R2RLoss

Recorrupted-to-Recorrupted (R2R) Loss

deepinv.loss.ScoreLoss

Learns score of noise distribution.

Adversarial Learning#

User Guide: refer to Adversarial Learning for more information.

deepinv.loss.adversarial.DiscriminatorMetric

Generic GAN discriminator metric building block.

deepinv.loss.adversarial.GeneratorLoss

Base generator adversarial loss.

deepinv.loss.adversarial.DiscriminatorLoss

Base discriminator adversarial loss.

deepinv.loss.adversarial.SupAdversarialGeneratorLoss

Supervised adversarial consistency loss for generator.

deepinv.loss.adversarial.SupAdversarialDiscriminatorLoss

Supervised adversarial consistency loss for discriminator.

deepinv.loss.adversarial.UnsupAdversarialGeneratorLoss

Unsupervised adversarial consistency loss for generator.

deepinv.loss.adversarial.UnsupAdversarialDiscriminatorLoss

Unsupervised adversarial consistency loss for discriminator.

deepinv.loss.adversarial.UAIRGeneratorLoss

Reimplementation of UAIR generator's adversarial loss.

Network Regularization#

User Guide: refer to Network Regularization for more information.

deepinv.loss.JacobianSpectralNorm

Computes the spectral norm of the Jacobian.

deepinv.loss.FNEJacobianSpectralNorm

Computes the Firm-Nonexpansiveness Jacobian spectral norm.

Loss schedulers#

User Guide: refer to Loss schedulers for more information.

deepinv.loss.BaseLossScheduler

Base class for loss schedulers.

deepinv.loss.RandomLossScheduler

Schedule losses at random.

deepinv.loss.InterleavedLossScheduler

Schedule losses sequentially one-by-one.

deepinv.loss.InterleavedEpochLossScheduler

Schedule losses sequentially epoch-by-epoch.

deepinv.loss.StepLossScheduler

Activate losses at specified epoch.