labsyspharm / ashlar

ASHLAR: Alignment by Simultaneous Harmonization of Layer/Adjacency Registration
https://labsyspharm.github.io/ashlar/
MIT License
128 stars 42 forks source link

3d stitching #227

Open bpavie opened 4 days ago

bpavie commented 4 days ago

Dear All,

I have a 3d stack that I would like to stitch using ashlar: tile_x001_y001_z001.tif tile_x001_y001_z002.tif ... tile_x002_y010_z402.tif

I looked at the documentation but I am not sure exactly how I could use file pattern in x/y/z to stitch. The filepattern seems to support cols and rows bu not Z stack.

Would it be possible to have a example on how to perform this or to know if it's possible to stitch 3d Z-stack with ashlar ?

Best, Benjamin

jmuhlich commented 22 hours ago

There's no support for stitching with Z-stack images. We have a few ideas for how it might be done but there are actually a lot of subtle issues to consider. You could try to stitch a fixed central Z-plane e.g. z200 in your case and see how the image looks -- use something like "filepattern|...|pattern=tile_x{col:03}_y{row:03}_z200.tif|...". If it works, I can show you how to generate a CSV with the corrected tile coordinates to use in reconstructing the full Z-stacks. Let me know if the stitching looks wrong and we can troubleshoot it.