cgohlke / tifffile

Read and write TIFF files
https://pypi.org/project/tifffile
BSD 3-Clause "New" or "Revised" License
539 stars 155 forks source link

use tiffile stored in a multi-resolution pyramid structure with tiff file #207

Closed chengdonglin closed 1 year ago

chengdonglin commented 1 year ago

I known different scale tiles , how can I use tifffile build the Whole slide images tiff file,like below image

cgohlke commented 1 year ago

It depends on which software you use to read the image pyramid from TIFF. There are several TIFF based formats that support pyramids, e.g. OME-TIFF, ZIF, Generic tiled TIFF, and Cloud Optimized GeoTIFF.

There's an example in the docstring to create a pyramidal OME-TIFF: https://github.com/cgohlke/tifffile/blob/84c9c41668173965fdeb2907bfb42d037bf0cd00/tifffile/tifffile.py#L630-L676

There are more examples and discussions on the Image.sc forum