[scikit-image] Warping image subset

Amaury Dehecq amaury.dehecq at univ-smb.fr
Thu Oct 6 20:06:04 EDT 2016


Hello everyone,

I'm using skimage to correct distortions on an image, using a polynomial 
transformation. Basically, my commands can be summarized to:

         import skimage.transform as tf

         # estimate the transformation matrix from control points before 
(pts2) and after (pts1) distortion
         M=tf.estimate_transform('polynomial',pts2,pts1,order=3)

         # warp the initial image im
         warped=tf.warp(im,M)

This does exactly what I want, except that my image is very large (35000 
x 35000) and the script crashes if I try to run it for the whole image.
So I thought I could just cut my image into subimages and run warp for 
each subimage. But as the matrix indexes are shifted (e.g always in the 
interval [0-5000] instead of [0-350000]), I end up applying the same 
correction to each subimage.
Is there a way to take into account the fact that my matrix is a subset, 
for example by indicating the actual coordinates instead of using the 
matrix indexes? (Like in the MatLab function imwarp using argument RA if 
that helps understanding)

Thanks a lot,

Amaury



More information about the scikit-image mailing list