Problem reading some dm4 files in bioformats 6.4.0

Hi,
I recently came across a problem reading some dm4 files with bioformats 6.4.0. The problem occurs both in imagej and using bftools.
There is no problem with older 6.0.1 bioformats on the same file. I have tried several java versions.
Bioformats version:
Version: 6.4.0
Build date: 11 March 2020
VCS revision: b1be2a9baa7b780ca258315d80132479099c57de
output of:
$ bftools/showinf SomeFile.dm4 -nocore -nopix
Exception in thread “main” java.lang.IllegalArgumentException: 0 must be non-null and strictly positive.
at ome.xml.model.primitives.PositiveInteger.(PositiveInteger.java:48)
at loci.formats.MetadataTools.populatePixelsOnly(MetadataTools.java:312)
at loci.formats.MetadataTools.populateMetadata(MetadataTools.java:262)
at loci.formats.MetadataTools.populatePixels(MetadataTools.java:151)
at loci.formats.MetadataTools.populatePixels(MetadataTools.java:116)
at loci.formats.in.GatanReader.initFile(GatanReader.java:267)
at loci.formats.FormatReader.setId(FormatReader.java:1389)
at loci.formats.ImageReader.setId(ImageReader.java:843)
at loci.formats.ReaderWrapper.setId(ReaderWrapper.java:650)
at loci.formats.tools.ImageInfo.testRead(ImageInfo.java:1035)
at loci.formats.tools.ImageInfo.main(ImageInfo.java:1121)

Hi @Jean-Marc and welcome to the forum,

the issue you describe could indicate a regression caused by recent changes to the reader. Unfortunately, we have not been able to flag such a regression due the absence of representative sample file in our curated QA repository.

Would it be possible for you to upload one of the dm4 files which fails to open? If you had sample files that could be also made publicly available under a CC-BY license, this would be ideal. If that is not possible, we will keep the data private and use it internally for testing.

Best,
Sebastien

Hi, I am having the same problem ( error below). I would like to upload a file, but it seems Flash needs to be installed to upload on that page. Is there another way?

I am using bioformats 6.5.

java.lang.IllegalArgumentException: 0 must be non-null and strictly positive.
	at ome.xml.model.primitives.PositiveInteger.<init>(PositiveInteger.java:48)
	at loci.formats.MetadataTools.populatePixelsOnly(MetadataTools.java:312)
	at loci.formats.MetadataTools.populateMetadata(MetadataTools.java:262)
	at loci.formats.MetadataTools.populatePixels(MetadataTools.java:151)
	at loci.formats.MetadataTools.populatePixels(MetadataTools.java:116)
	at loci.formats.in.GatanReader.initFile(GatanReader.java:267)
	at loci.formats.FormatReader.setId(FormatReader.java:1389)
	at loci.plugins.in.ImportProcess.initializeFile(ImportProcess.java:499)
	at loci.plugins.in.ImportProcess.execute(ImportProcess.java:142)
	at loci.plugins.in.Importer.showDialogs(Importer.java:140)
	at loci.plugins.in.Importer.run(Importer.java:76)
	at loci.plugins.LociImporter.run(LociImporter.java:78)
	at ij.IJ.runUserPlugIn(IJ.java:230)
	at ij.IJ.runPlugIn(IJ.java:193)
	at ij.IJ.runPlugIn(IJ.java:182)
	at loci.plugins.shortcut.ShortcutPanel$1.run(ShortcutPanel.java:189)

Hi @cwood1967,

thanks for following up here, if using the Flash-based uploader is not an option for you, there are a few other immediate alternatives:

  • if the file is < 25MB, we could turn this into a proper Bio-Formats GitHub issue and attach the file to the issue
  • if you have access to any file hosting system through your institution, you can use it to share the data with us
  • we can also send you privately some details for a FTP server to upload your data.

Let us know which option works best for you,
Sebastien

Hi Guys,
Sorry I had to create new images before I could male them public and it took time with the lockdown. Then I tried the upload and it did not work (flash).
Therefore, you can find images here: https://www.open-em.org/BFTOOLS/
It is a montage of 3x3. The first of the montage (0000.dm4) opens without a problem. the others don’t. And I only get the problem with montages. The images are completely blank: this is normal (the beam was off).
This issue is still valid today with:
Version: 6.5.0
Build date: 30 April 2020
VCS revision: ed992ebc2cb07d04fcb49485540af0babd1baa05

1 Like

Thanks @Jean-Marc and no worries at all,

with your set of files I can reproduce the issue. The problem is likely related to the handing of montage files for some variants of the DM4 format. I have opened https://github.com/ome/bioformats/pull/3558 to test a potential fix?

We will add your sample files to our curated QA repository. Can you confirm you are happy for us to make them publicly available under CC-BY 4.0 license?

Hi Sebastien,

Yes, sure. I’m happy to make these files publicly available under CC-BY 4.0 license. I acquired them for this purpose !
If you need further trials or even additional images, let me know.

Jean-Marc

Hi Sebastien,
Will a shared OneDrive folder work for you? The files are around ~200 MB each.

Chris

Hi Chris,

yes sharing the data via OneDrive folder would work. Really, any hosting solution that allows us to copy/mirror the data on our curated QA repository is doable. Having additional samples would be useful for us so that we can test the proposed fix as thoroughly as possible.

Sebastien

Great,

Here is the link: dm4 files.

Let me know if you have trouble,
Chris

Hi Chris,

we received the files and will use them to test the proposed fix, thanks for sharing. Same question as above, is it okay to share publicly or should the files be kept private?

Sebastien

Hi Sebastien,
You can share the files publicly.

Chris

2 Likes

Hi again on this topic,

I have just updated by bioformats bftools to 6.5.1 (7 July 2020) and unfortunately, the problem is still there. Always the same problem, which did not exist in previous versions.
I had to go back to 6.0.1 again …
I hope can be fixed at some point, and I’m happy to help if I can do anything.
Best,

Jean-Marc

Hi Jean-Marc, I have added the PR containing the fix for this issue (https://github.com/ome/bioformats/pull/3558) to the Bio-Formats 6.6.0 milestone to target a fix for that upcoming release. Once it has been fully tested and merged then it should be available in the next release.