openslide / openslide-python

Python bindings to OpenSlide
https://openslide.org/
GNU Lesser General Public License v2.1
367 stars 180 forks source link

DeepZoomGenerator.get_tile(level, col, row) gives blank tiles. #58

Closed fireofearth closed 2 years ago

fireofearth commented 5 years ago

Context

Issue type (bug report or feature request): bug report

Operating system (e.g. Fedora 24, Mac OS 10.11, Windows 10): Ubuntu Linux 19.04

Platform (e.g. 64-bit x86, 32-bit ARM): x86_64

OpenSlide Python version (openslide.__version__): 1.1.1

OpenSlide version (openslide.__library_version__): 3.4.1

Slide format (e.g. SVS, NDPI, MRXS): SVS

Details

So this thing comes up in both my implementation of wsi viewer and in the example code. Image viewer returns blank tiles on the left and top slide (the top-left most slide renders properly).

Download some example .svs file say from https://dbarchive.biosciencedbc.jp/en/open-tggates-pathological-images/data-2.html. I used ftp://ftp.biosciencedbc.jp/archive/open-tggates-pathological-images/LATEST/images/1%25_cholesterol_+_0.25%25_sodium_cholate/Kidney/66064.svs

svn checkout https://github.com/openslide/openslide-python/trunk/examples/deepzoom

In deepzoom_server.py modify line 31 to

DEEPZOOM_SLIDE = '/path/to/deepzoom/66064.svs'

and add to line 108 with

import os.path
#...
tile.save(os.path.join('/path/to/deepzoom','out','{}_{}_{}.{}'.format(level, col, row, format))

Then run server by doing

FLASK_APP=deepzoom_server.py flask run

Observe that some jpeg tiles come up blank.

lambda-science commented 3 years ago

Update on this issue ? Had similar issue explained here https://github.com/openslide/openslide-python/issues/111#issuecomment-807233900

manyids2 commented 3 years ago

I experienced similar issues, the fix was to update pixman to version 0.4, which can be done by following these instructions.

bgilbert commented 2 years ago

This issue was likely due to an old pixman bug, so I'll close. Thanks for the report.