Shifting images for alignment



I’m trying to align two very large images (15 Mb, 50,000 objects in each). Works but takes a long time.
I can align them much faster by cropping them using the same cropping coordinates, then aligning the cropped images.
I thought I would then be able to apply the calculated X and Y shifts to the original images.
But when I do, the original images get cropped and shifted rather than just shifted.
Any ideas of how to correct this?
Many thanks,



An alternative approach is to use the Resize module to shrink the images to a more manageable size, and then Align those. The caveats would be (a) loss of resolution of the 50k objects, which I presume would diminish alignment efficacy; and (b) all other images would need to be rescaled similarly, since the alignment factors would be for the resized images, not the original. Do you think this would be an option for you?


Hi Mark -
Unfortunately I cannot shrink them as most of my objects are only a few pixels in area.
I would think it would be relatively simple to design a module that shifts a given amount without cropping given that the code already exists for this (in the Align module).
Wouldn’t it just be the same as the Align module minus the Alignment algorithm (using saved x- and y-shifts from the previous Align module)?
Is my thinking naive?