pearcetm / GeoTIFFTileSource

Implementation of a TileSource for OpenSeadragon based on GeoTIFF.js, enabling local and remote TIFF files to be viewed without using an image server
MIT License
27 stars 5 forks source link

Memory usage problem #21

Open name-undef1ned opened 3 weeks ago

name-undef1ned commented 3 weeks ago

I used this plugin in an openseadragon based project for capturing pathology files in.ndpi.svs and other formats, but when viewing, especially after multiple zoomings, the memory usage was high, up to 16GB (my computer only had 16GB of memory left) and the page crashed. Now I want to optimize this memory usage problem, could you please give me some suggestions? Thank you very much

abiswas97 commented 3 weeks ago

Can you share the version of the plugin that you're currently using? A potential leak was addressed as part of https://github.com/pearcetm/GeoTIFFTileSource/pull/5 (https://github.com/pearcetm/GeoTIFFTileSource/pull/5/commits/6dfa997cd2252a97601d44e306ce35e7b3c68a10)

If your version is lower than the change from the above PR, you can try installing the package through npm, or use the latest bundled build. If you're using the current version, we might have a new memory leak to investigate.

name-undef1ned commented 2 weeks ago

image image Thank you for your reply. Here is the version of my plugin, which I use following the guidance in the official documentation. The file is an approximately 188MB .ndpi format file. Not only in my own project, but even the official demo on our computers experiences high memory usage issues. Therefore, I would like to know if there are ways to reduce memory usage, such as certain release strategies that might help unload and free up regions of the image that are reloaded frequently.