plot_parameters

deepinv.utils.plot_parameters(model, init_params=None, save_dir=None, show=True)[source]

Plot the parameters of the model before and after training. This can be used after training Unfolded optimization models.

Parameters:
  • model (torch.nn.Module) – the model whose parameters are plotted. The parameters are contained in the dictionary params_algo attribute of the model.

  • init_params (dict) – the initial parameters of the model, before training. Defaults to None.

  • save_dir (str, Path) – the directory where to save the plot. Defaults to None.

  • bool (show) – whether to show the plot. Defaults to True.

Examples using plot_parameters:

Vanilla Unfolded algorithm for super-resolution

Vanilla Unfolded algorithm for super-resolution

Learned Iterative Soft-Thresholding Algorithm (LISTA) for compressed sensing

Learned Iterative Soft-Thresholding Algorithm (LISTA) for compressed sensing

Learned iterative custom prior

Learned iterative custom prior