Error when visualizing a CachedCellImg with BigDataViewer

When running this script: https://github.com/acardona/scripts/blob/01cd9c723d0a07fe1acadd255812699b68ba0161/python/imagej/examples/imglib2_load_4D_CachedCellImg_from_3D_filepaths.py , I get an error at line:

bdv = BdvFunctions.show(cachedCellImg, "4D volume")

The error: lacking field list. Any clues?

Traceback (most recent call last):
  File "/home/albert/lab/scripts/python/imagej/examples/imglib2_load_4D_CachedCellImg_from_3D_filepaths.py", line 82, in <module>
    bdv = BdvFunctions.show(cachedCellImg, "4D volume", Bdv.options())
	at bdv.viewer.BasicViewerState.notifyListeners(BasicViewerState.java:1622)
	at bdv.viewer.BasicViewerState.addSources(BasicViewerState.java:724)
	at bdv.viewer.SynchronizedViewerState.addSources(SynchronizedViewerState.java:496)
	at bdv.viewer.state.ViewerState.<init>(ViewerState.java:81)
	at bdv.viewer.ViewerPanel.<init>(ViewerPanel.java:248)
	at bdv.viewer.ViewerFrame.<init>(ViewerFrame.java:103)
	at bdv.BigDataViewer.<init>(BigDataViewer.java:335)
	at bdv.util.BdvHandleFrame.createViewer(BdvHandleFrame.java:91)
	at bdv.util.BdvHandle.add(BdvHandle.java:142)
	at bdv.util.BdvFunctions.addRandomAccessibleInterval(BdvFunctions.java:449)
	at bdv.util.BdvFunctions.show(BdvFunctions.java:86)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:498)
java.lang.NoSuchFieldError: java.lang.NoSuchFieldError: list

There was an old issue related to this error:

But it should be solved now.
Which versions do you have for imglib2, bdv-core and bdv-vistools ? Do you have update sites enabled ?

1 Like

Thanks, good catch. I do have update sites enabled, but I had just updated Fiji, which should also update jars from update sites.

I’ve now unticked the update site BigVolumeViewer, but the error persists.

I have:

Fiji.app/jars$ ls big*
bigdataviewer-core-9.0.5.jar
bigdataviewer-vistools-1.0.0-beta-20.jar
bigvolumeviewer-0.1.8.jar

/Fiji.app/jars$ ls scijava-listeners*
scijava-listeners-1.0.0-beta-3.jar

Fiji.app/plugins$ ls big
bigdataviewer_fiji-6.2.0.jar
bigwarp_fiji-6.0.2.jar

Are any of these not up to date? They ought to be, as per the Fiji updater.

Found a solution: uninstall the SciView update site.

1 Like

You should have bdv-vistools v>=1.0.0-beta-21 to have the issue fixed : https://github.com/bigdataviewer/bigdataviewer-vistools/issues/46

1 Like

Thanks. Do you know who is in charge of SciView? Their Bdv tools have this issue. @tpietzsch @kephale?

One moment please! Let me check. I’ll try to cut a release early. The SciView-Unstable site should be working with a more recent vistools in the meantime.

Aha, the latest pom-scijava still seems to use 1.0.0-beta-20

Currently waiting on a SciView-Unstable CI update. @albertcardona I’ll test your script when that is ready and follow up after that.

Thanks! the data for that script is here:

… and requires the SiMView update site for the KLB file format reader.

Okey doke, working for me with the SciView-Unstable update site. We’ll propagate this to the primary SciView update site soon

2 Likes

For the record, the whole script is here:

… and showcases:

  • How to read a series of 3D stacks as a 4D volume using ImgLib2’s CachedCellImg.
  • How to view the volume in an ImageJ VirtualStack and with the BigDataViewer, properly setting a display range (min and max values) for best initial visualization.
  • How to write the volume in N5 format.
  • How to read the N5 formatted-volume into an ImgLib2 image, and then view it either with a VirtualStack or a BigDataViewer, showcasing:
    A) How the N5 format with an appropriate GZIP compression level compares in file storage requirements to e.g. the highly compressed KLB (584 MB for GZIP=4 N5 versus 407 MB for KLB).
    B) How the N5 format with a relatively small block size (2 MB) enables fast random access on the volume.

This will be part of the python (jython) tutorial on exploring large datasets at #I2K2020 on December 1st.

2 Likes

Sounds very complementary to the volumetric data segment of the sciview I2K tutorial! Good thing the update sites wont clash now :wink:

1 Like