I was tasked with providing a work around for the virtual microscope used in two of our ongoing applications, Histology and Pathology lab manuals.The virtual microscope is used by medical students to view the massive Aperio digital pathology slides. The current system worked well but used Flash, which is no longer supported in major browsers. I had to quickly find a solution for the upcoming semester.
One of the solutions considered was to have the Aperio software integrated into
the site. Unfortunately this option would require students to log in anytime
they accessed a slide. More importantly, the cost for the software was high. The
other option was to build our own viewer. I looked around for a possible way to
display these slides, coming across this guide from folks at NYU
Virtual Microscope. They proposed a
solution which involved converting the Aperio specific .SVS
slides to a common
file type and using a maps framework called Leaflet.
The Leaflet framework works similarly to Google Maps, using tiles to break up
large images. With the NYU guide in hand, I began to convert around 143 .SVS
slide images to a huge tiled versions using the recommended library
libvips. Once completed, this allowed me
to set up Leaflet to use those tiled images to create a virtual microscope,
zooming in as if it were a real microscope.
To really make this new version useful and accessible, I added some controllers. The pan controller offers keyboard control. Panning across the image is especially useful when zoomed in all the way. A zoom slider allows for keyboard control of the magnification. Because I didn’t have the information for exact microscope magnification, I set up a small algorithm so that the zoom levels were at least consistent with each other.
This new virtual microscope has been working well for the faculty and students.
I am happy we were able to produce something in-house using open source software,
saving a few bucks along the way!
Printed from: https://compiled.ctl.columbia.edu/articles/a-leaflet-solution/