The batch script registerTimeLapse.m is designed to remove microscope jitter from a series of time lapse images. Given a folder of multiple-image tif files, the script iteratively registers each image to the previous registered image.
The function dftregistration is required for using this script and can be downloaded from the MATLAB file exchange:
Manuel Guizar (2020). Efficient subpixel image registration by cross-correlation (https://www.mathworks.com/matlabcentral/fileexchange/18401-efficient-subpixel-image-registration-by-cross-correlation), MATLAB Central File Exchange. Retrieved December 8, 2020.
The script requires the following user inputs:
- imDir is the directory which contains the multiple-image tif files to be registered.
- imTag is a string that identifies which images should be registered. For example, this could specify a specific imaging channel. To analyze all the images in the folder, set imTag to
''. - saveDir is the location where the registered images will be saved.
- overwrite allows the user to choose whether to overwrite or to skip previously registered image files.
- usfac is the upsampling factor used to set the resolution of the registration (images are registered to within 1/usfac of a pixel).
- otherChannels can be used to register other images with the same base name as the registered image. If no other images need to be registered, set this option to
{}. Otherwise, specific a list of string that uniquely identify the other image sets to be image. For example, if myImage_Ch1.tif is being registered usingimTag = 'Ch1', then myImage_Ch2.tif and myImage_Ch3.tif can be registered using the same offsets usingotherChannels = {'Ch2','Ch3'}.