Apply segmentation to a large binary image

Juan Nunez-Iglesias jni.soma at gmail.com
Fri Mar 13 22:04:10 EDT 2015


Hey Yuta,




You'll need to do some stitching out-of-core. That's a really tricky problem and I don't have any ready-made solutions for you. The solution will depend on the nature of your segments. The only thing I would recommend is that you use a format such as HDF5 (you can use the excellent h5py library) that allows random access into the underlying disk data.




Other than that, as I said, to my knowledge you'll have to develop your own stitching: segment *overlapping* tiles independently in memory, and when it comes time to write to disk, load the tile and overlapping tiles that have already been segmented, and resolve label mapping then...




Generally, think of it this way: tile i has already been segmented and written out. We now want to write out tile j, which overlaps tile i. Labels from tile i that intersect labels from tile j in the overlap region should be matched. labels in tile j that *don't* intersect tile i should be relabelled to ensure they are unique with respect to tile i.




Of course this gets a bit more complicated in 2D or 3D...




Juan.

On Fri, Mar 13, 2015 at 7:20 PM, Yuta Sato <yutaxsato at gmail.com> wrote:

> Dear SKIMAGE Developers and Users:
> I want to use the following algorithm in a large binary image that does not
> fit into my PC memory. So, I am thinking to split my large image into tiles
> and apply algorithm one by one. However, the original border definition
> change when I do it in parts. I need the result as applied in original full
> image. How can I do it efficiently?
> skimage.segmentation.clear_border(image, buffer_size=0, bgval=0)
> Thanks for your ideas.
> -- 
> You received this message because you are subscribed to the Google Groups "scikit-image" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to scikit-image+unsubscribe at googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/scikit-image/attachments/20150313/1261ec9c/attachment.html>


More information about the scikit-image mailing list