inpystem.restore.DL_BPFA module

This module implements the BPFA algorithm.

inpystem.restore.DL_BPFA.BPFA_matlab(Y, mask, P=5, Omega=1, K=128, Nit=100, step=1, PCA_transform=True, PCA_th='auto', verbose=True)

Implements BPFA algorithm for python.

This function does not properly executes BPFA but it calls the Matlab BPFA code.

Parameters
  • Y ((m, n) or (m, n, l) numpy array) – The input data.

  • mask ((m, n) numpy array) – The acquisition mask.

  • P (int) – The patch width. Default is 5.

  • Omega (int) – The Omega parameter. Default is 1.

  • K (int) – The dictionary dimension. Default is 128.

  • Nit (int) – The number of iterations. Default is 100.

  • step (int) – The distance between two consecutive patches. Default is 1 for full overlap.

  • PCA_transform (optional, bool) – Enables the PCA transformation if True, otherwise, no PCA transformation is processed. Default is True.

  • PCA_th (optional, int, str) – The desired data dimension after dimension reduction. Possible values are ‘auto’ for automatic choice, ‘max’ for maximum value and an int value for user value. Default is ‘auto’.

  • verbose (bool) – The verbose parameter. Default is True.

Returns

  • (m, n) or (m, n, l) numpy array – Restored data.

  • dict – Aditional informations. See Notes.

Note

The output information keys are:

  • time: Execution time in seconds.

  • Z

  • A

  • S