Closed ingiehong closed 6 years ago
Thanks for this. I'm surprised about the negative values. Another option that I used to have inside the motion correction functions was to subtract and then add back the minimum value to ensure that no problems arise. I'll think about putting it back.
Hi Eftychios, thanks again for the great work! I find that in apply_shifts, I need an additional line setting up Xq/Yq/Zq when using 'fft'. Another occasional problem I encountered when using NoRMCorre was that with images that have significant numbers of negative value pixels, the fft registration would produce global phase differences of pi or -pi, and in result, invert the images in terms of pixel intensity. A simple fix to this (I haven't fully explored whether this is a bug or an inevitable result of fft-based registration) is to ensure all pixels are non-negative at start. You had commented this out some time ago, I simply reinstated it. Hope this helps. Cheers! -Ingie