A project that involves image processing, i.e. to calculate the angular shift of the same image when shifted by a medium of certain Refractive Index. We have to build an app that correlates the 2 images (phase/2D correlation?) and then plot using Chaco and Mayavi (2 libraries in Python). Is there any other existing template software (FOSS) that we can base our app on, or use it as a reference?
A:
This thread might be helpful
http://stackoverflow.com/questions/94875/image-processing-in-python
sushant
2010-05-05 06:26:57
A:
Scipy contains many image processing routines in its scipy.ndimage package.
EOL
2010-05-05 09:00:05
A:
using scipy this should be a one-liner (although you can probably avoid the ndimage package)
from scipy.fftpack import fftn, ifftn
corr = (ifftn(fftn(a)*ifftn(b))).real
assuming you've managed to read your original images into numpy arrays a & b. If it's 2D images mayavi might be a bit overkill, and it would probably be easier to use matplotlib than chaco. If using matplotlib, you could do the whole lot with
from pylab import *
corr = (ifftn(fftn(a)*ifftn(b))).real
imshow(corr)