Skip to content
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

Missing dependency for .zarr files #77

Closed
jo-mueller opened this issue Jan 29, 2024 · 9 comments
Closed

Missing dependency for .zarr files #77

jo-mueller opened this issue Jan 29, 2024 · 9 comments

Comments

@jo-mueller
Copy link

Hi all,

following up some discussions on image.sc about the upload and use of .zarr files to OMERO, I have also discovered, that the problem in the latter of those issues (blosc dependency missing for "proper" zarr usage) persists in the container-based setup.

Error I observed

  1. I uploaded a ZARR file to our OMERO instance as discussed in this thread and the image cannot be displayed there.

  2. When I download (parts of) the image via ezomero like this:

metadata, data = ezomero.get_image(conn, image_id=some_id, no_pixels=False, dim_order='tczyx', start_coords=(2000, 2000, 5, 0, 0), axis_lengths=(512, 512, 1, 1, 1))

I receive the following error:

WARNING:omero.gateway:InternalException on <class 'omero.gateway.OmeroGatewaySafeCallWrapper'> to <aaaa9577-994e-4bad-a45a-ac6aa8c1a7a7omero.api.RawPixelsStore> getTile((5, 0, 0, 2000, 2000, 512, 512), {})
Traceback (most recent call last):
File "/home/pol_haase/johamuel/miniforge3/envs/microwells/lib/python3.9/site-packages/omero/gateway/__init__.py", line 4856, in __call__
  return self.f(*args, **kwargs)
File "/home/pol_haase/johamuel/miniforge3/envs/microwells/lib/python3.9/site-packages/omero_api_RawPixelsStore_ice.py", line 998, in getTile
  return _M_omero.api.RawPixelsStore._op_getTile.invoke(self, ((z, c, t, x, y, w, h), _ctx))
omero.InternalException: exception ::omero::InternalException
{
  serverStackTrace = ome.conditions.InternalException:  Wrapped Exception: (java.lang.NoClassDefFoundError):
Could not initialize class org.blosc.IBloscDll
  at com.bc.zarr.CompressorFactory$BloscCompressor.cbufferSizes(CompressorFactory.java:352)
  at com.bc.zarr.CompressorFactory$BloscCompressor.uncompress(CompressorFactory.java:338)
  at com.bc.zarr.chunk.ChunkReaderWriterImpl_Short.read(ChunkReaderWriterImpl_Short.java:55)
  at com.bc.zarr.ZarrArray.read(ZarrArray.java:278)
  at com.bc.zarr.ZarrArray.read(ZarrArray.java:255)
  at loci.formats.services.JZarrServiceImpl.readBytes(JZarrServiceImpl.java:266)
  at loci.formats.in.ZarrReader.openBytes(ZarrReader.java:362)
  at loci.formats.ImageReader.openBytes(ImageReader.java:465)
  at loci.formats.ChannelFiller.openBytes(ChannelFiller.java:167)
  at loci.formats.ChannelSeparator.openBytes(ChannelSeparator.java:229)
  at loci.formats.ReaderWrapper.openBytes(ReaderWrapper.java:348)
  at ome.io.bioformats.BfPixelsWrapper.getTile(BfPixelsWrapper.java:350)
  at ome.io.bioformats.BfPixelBuffer.getTileDirect(BfPixelBuffer.java:518)
  at ome.services.RawPixelsBean.getTile(RawPixelsBean.java:961)
  at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
...
  serverExceptionClass = ome.conditions.InternalException
  message =  Wrapped Exception: (java.lang.NoClassDefFoundError):
Could not initialize class org.blosc.IBloscDll
}

Possible solution

As discussed in this image-sc thread, the problem is likely just a missing dependency (e.g., libblosc). To fix it, I could probably simply build my own container based on the omero containers and fix it, but including the dependency here would probably be the more sustainable solution.

I would be happy to send a PR to fix it if you can point me to the correct place where to add it. That being said, I am not sure whether this is a missing dependency of the webserver or the other involved containers.

@jburel
Copy link
Member

jburel commented Jan 29, 2024

The blosc library is not installed. This is a server dependency. Are you using omero-server-docker? or another server.

@jo-mueller
Copy link
Author

Hi @jburel ,

thanks for the quick reply. I have essentially used the docker-example-omero which led to the error.

@jburel
Copy link
Member

jburel commented Jan 29, 2024

Thanks.
I have opened a PR ome/omero-server-docker#89
this is the first step to upgrade docker-example-omero.

@imagesc-bot
Copy link

This issue has been mentioned on Image.sc Forum. There might be relevant details there:

https://forum.image.sc/t/images-batch-import-into-a-dataset-in-omero-using-ezomero-2-1-0/89529/22

@jo-mueller
Copy link
Author

Thanks for the lightning-fast fix @jburel . How often are docker containers released? I.e., how long would it take for this change to take effect in production?

@pwalczysko
Copy link
Member

Thanks for the lightning-fast fix @jburel . How often are docker containers released? I.e., how long would it take for this change to take effect in production?

@jo-mueller please see https://hub.docker.com/r/openmicroscopy/omero-server/tags for the de-facto release frequency. In short, it is a manual process, so please bear with us, thank you :)

@jo-mueller
Copy link
Author

Will keep my eyes peeled then :) Your work is very appreciated, thanks!

@jburel
Copy link
Member

jburel commented Feb 1, 2024

@jo-mueller A new version of the omero-server-docker has been pushed to dockerhub. It should include blosc

@jburel jburel closed this as completed Feb 1, 2024
@jo-mueller
Copy link
Author

Thanks big time! 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants