Vectorization of convolution functions in utils/convolve.py
The implementation of the phase_conv2d, nan_conv2d and norm_angle has been replaced by a vectorized implementation approach to significantly speed up code execution (~200x faster for nan_conv2d and ~40x faster for phase_conv2d).
WARNING: This implementation also fixes the boundary conditions issue taken into account by PR #66. Please consider to merge PR #66 before this one for result consistency.
@FMarmoreo could you test whether the output of the updated functions are all equivalent to the previous versions and post the results? Otherwise, a change in behavior would need to be documented.
Here a test about the new implementation of phase_conv2d, compared to the old implementation (after having fixed the bug as in PR #66):
The difference between them stays below the double precision of the machine: