CEA-COSMIC / pysap-mri

MRI external plugin for Python Sparse data Analysis Package
Other
43 stars 18 forks source link

Flattening of the wavelet coefficients #93

Open zaccharieramzi opened 4 years ago

zaccharieramzi commented 4 years ago

Right now, the wavelet coefficients in WaveletN are flattened. I guess this is because the scalar product was "easier" to perform then.

However we could use vdot. And therefore we wouldn't need to flatten the coefficients and could use them in other ways like to solve #66 .

It would also prevent errors like calling the adjoint operator first (which as of now doesn't fail elegantly):

import numpy as np
from mri.operators import WaveletN
coeffs = np.zeros((16,))
linear_op = WaveletN(wavelet_name='haar', nb_scale=2)
adj_tr = linear_op.adj_op(coeffs)
chaithyagr commented 3 years ago

I think this is related to #66 . As we change the flow of how we promote sparsity, we can also work on getting adjoint right. However, will still retain this issue for completeness.