-
Notifications
You must be signed in to change notification settings - Fork 5
Switch from PixelBuffer to Zarr metadata and array cache #3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Switch from PixelBuffer to Zarr metadata and array cache #3
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Similarly to #1 (comment), integrated these changes into a development branch of omero-ms-image-region
for deployment and testing on a development instance.
The rendering of RGB and fluorescent OME-Zarr images as well as OME-Zarr labels hosted on our public S3 bucket is working as expected in PathViewer. For digital pathology data in particular, the navigation experience including the bird's eye view as well as zooming & panning functionality was working without any error while retrieving tiles.
My inline comments are related to possible next steps so I think we could get this included as is but @kkoz might want to take a look at the changes.
throws IOException { | ||
// FIXME: Really should be ZarrUtils.readAttributes() to allow for | ||
// attribute retrieval from either a ZarrArray or ZarrGroup but ZarrPath | ||
// is package private at the moment. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In the same spirit as the work we did with @melissalinkert on bioformats2raw/raw2ometiff
, I was considering switching to the more active zarr-developers/jzarr
fork on this repository as well
This might be an opportunity to discuss any API improvements we should consider as a preamble of this update.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Opened as zarr-developers/jzarr#19. I think it makes sense to switch to that fork for testing as soon as possible.
.maximumSize(0) | ||
.buildAsync(PixelsService::getZarrArray) | ||
); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍 I'll port similar changes to the omero-ms-image-region
unit tests instantiating ZarrPixelBuffer
.
This raises the question of whether AbstractZarrPixelBufferTest
(which originates from the omero-ms-image-region
tests) is still relevant and could be consumed by downstream components. In that case, there's probably a case for moving this utility method under this abstract class.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sounds good. I'm not sure the utility now to be honest.
Caching at the
PixelBuffer
level can cause concurrency issues due to the combination ofsetResolutionLevel()
andgetTile()
not being used atomically in all situations. We can also improve performance by cachingZarrArray
instances and not recreating them when switching between resolution levels.