Some fixes in wavelet decomposition and reconstruction.