Skip to content

Memory not released after deleting layers loaded from .zarr in napari-ome-zarr #129

@macromeer

Description

@macromeer

When loading OME-Zarr (.zarr) image data into napari using the napari-ome-zarr plugin, I have noticed that deleting layers from the viewer does not free the corresponding data from working memory. The memory usage remains high even after layers are removed. This suggests that references to the image data persist.

Steps to Reproduce

  1. Load a .zarr file (OME-Zarr format) into napari via napari-ome-zarr.
  2. Delete/remove layers from the viewer.
  3. Observe that memory usage does not decrease as expected.

Expected Behavior
Upon removing layers from the napari viewer, the memory associated with those layers, including any cached dask arrays or image data from the .zarr source, should be released promptly to prevent memory bloat during long sessions.

Edit: Napari behavior for TIFs seems to be that after removing layers data stays in memory but when loading a new image, old data is removed from memory.

Observed Behavior
Memory used by the application does not decrease despite deleting layers, indicating that the data stays in memory.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions