Stitching together sequence of images

stitching
Tags: #<Tag:0x00007fd5464a83c8>

#1

I’ve been working on a project to find the best possible way to stitch together stacks of images at once. I’ve tried both writing a macro with a loop using the pairwise stitching function and just using the Grid/Collection stitching plug in but have had some issues with both.

The main issue that we encounter is an image that is clearly out of place in the TileConfiguration document created. Some of the sequences end up coming out fine, but others have issues and I’m not exactly sure why.

Below is an example of such a tileconfiguration:

Define the image coordinates

Image122.tif; ; (0.0, 0.0)
Image124_ch00.tif; ; (7.997980568471957, 437.8945896870307)
Image126_ch00.tif; ; (18.9960233652584, 1000.7924275684242)
Image128_ch00.tif; ; (29.99415133430623, 1635.6947112726173)
Image130_ch00.tif; ; (42.99219293663753, 2313.592486805826)
Image132_ch00.tif; ; (54.990446997340655, 2889.5013522438703)
Image134_ch00.tif; ; (68.98870049215671, 3601.410188143733)
Image136_ch00.tif; ; (82.98719685144933, 4323.3317010866795)
Image138_ch00.tif; ; (96.98570538865988, 5058.253849692742)
Image140_ch00.tif; ; (108.98457033945601, 5684.194602379745)
Image142_ch00.tif; ; (122.98341190728765, 6478.134134522466)
Image144_ch00.tif; ; (133.98263572417952, 6999.093619306569)
Image146_ch00.tif; ; (146.98182534958042, 7672.051319362786)
Image148_ch00.tif; ; (160.981380647587, 8381.028106802394)
Image150_ch00.tif; ; (171.9809111991341, 8908.003602525989)
Image152_ch00.tif; ; (185.98067580674456, 9675.991315511)
Image154_ch00.tif; ; (-105.46658197729006, -5180.457206946628)
Image156_ch00.tif; ; (-92.46658197729006, -4539.457206946628)
Image158_ch00.tif; ; (-76.46658197729009, -3793.4572069466294)
Image160_ch00.tif; ; (-60.466581977290126, -3038.457206946632)
Image162_ch00.tif; ; (-44.46658197729017, -2291.457206946635)
Image164_ch00.tif; ; (-27.466581977290225, -1463.457206946638)
Image166_ch00.tif; ; (-11.466581977290275, -646.4572069466418)
Image168_ch00.tif; ; (4.53341802270968, 155.542793053355)
Image170_ch00.tif; ; (16.533418022709633, 813.5427930533515)
Image172_ch00.tif; ; (31.53341802270959, 1580.5427930533483)
Image174_ch00.tif; ; (45.533418022709554, 2266.542793053345)
Image176_ch00.tif; ; (56.533418022709526, 2901.5427930533424)
Image178_ch00.tif; ; (72.53341802270951, 3724.54279305334)
Image180_ch00.tif; ; (86.5334180227095, 4365.542793053339)
Image182.tif; ; (102.53341802270948, 5132.542793053339)

Clearly something happens at Image152_ch00 and I’m not sure how to attack the problem.

Does anyone have any suggestions for alternate approaches to the stitching or any suggestions for why the issue we are facing may occur.


#2

Hi @kcbristol,

To help diagnose your issue, it will be helpful to know the steps that you took in order to get that TileConfiguration,
(did you change any parameters in the plugin, for instance?), and also what your images look like (if your images are mostly sparse, then the stitcher’s job is very challenging).

Also, you might be interested in trying the BigSticher which is similar to the Grid/Collection stitching plugin but with many improvements.

Good luck,
John


#3

Hi @bogovicj

I downloaded the BigStitcher plugin, but have been confused how to apply it to a stack of images. The data I have gathered is in .tiff files and the BigStitcher plugin needs files to be .xml instead.

My question is how do you properly use the plugin for a folder full of TIFF files? For example, I have a folder full of 30 TIFF images, and I want them all stitched together in order. I saw there is the manual loading option, but was confused with that as well.

Any assistance would be greatly appreciated.

Regards.


#4

Hi @kcbristol,

BigStitcher want’s those xml files because it uses a multi-resolution image pyramid for processing.

Consider converting your tiff to xml/h5 by following the instructions here:

(if you can open your data in imagej, you can convert it)

Edit:
How big are your images?

Was there anything in particular that was confusing about the manual loading option?
… we can help better if you have a specific question / problem. i.e., what have you tried so far?
and what happened.

Let us know how it goes,
John