Skip to content

CGDogan/openslide

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

caMicroscope OpenSlide Docker image

Used by SlideLoader for serving image metadata and by iipimage for serving pixels.

Dummy apt packages

After compiling and make installing OpenSlide, packages such as libvips will try to install alternative OpenSlides such as libopenslide0 from apt. A safe way to solve this is to create and install dummy packages, as suggested on StackExchange (1, and 2). Something to watch out for is that the dummy package must have a version that satisfies the requirements of dependendees. Currently the strictest dependees had the requirement: ">=3.4.1 ..." and this was released in 2015. Therefore the current version in this repository is 3.4.2 but feel free to update it to 4.0.0 since no library I could find currently checks for "<4.0.0"

To check that an OpenSlide installation is recent enough and supports DICOM:

wget https://medistim.com/wp-content/uploads/2016/07/ttfm.dcm
python3 -c "o={};exec(\"import openslide;\nif openslide.OpenSlide.detect_format('ttfm.dcm') is None:\n\tres='old openslide'\nelse:\n\tres='new openslide'\n\",globals(),o);print(o['res'])"

Which will print the result or give an error if OpenSlide could not be found.

A second version returns a nonzero process exit code if a DICOM file cannot not be read. This is useful for Dockerfiles:

RUN wget https://medistim.com/wp-content/uploads/2016/07/ttfm.dcm
RUN python3 -c "o={};exec(\"import openslide;\nif openslide.OpenSlide.detect_format('ttfm.dcm') is not None:\n\tres='new openslide'\n\",globals(),o);print(o['res'])"

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published