knip icon indicating copy to clipboard operation
knip copied to clipboard

Image Writer loses data when writing ICS format

Open imagejan opened this issue 8 years ago • 9 comments

When writing an image (X,Y,Z,Time,Channel) in ics format, the resulting file has much less planes than expected. See the workflow uploaded here:

http://jmp.sh/IV7snca

Note: writing the file using Scifio in Fiji (File > Export > Image...) works as expected, so it's not a SCIFIO issue.

imagejan avatar Feb 21 '17 12:02 imagejan

Thanks for the detailed workflow and explanation. I was able to reproduce the problem. However, it may still be SCIFIO related. Are you sure the image is written with SCIFIO in ImageJ2 and not BioFormats or IJ1? Anyway, we will investigate it!

dietzc avatar Feb 22 '17 04:02 dietzc

Hm, I'm pretty sure that File > Export > Image will use SCIFIO. Anyways, thanks for investigating!

imagejan avatar Feb 22 '17 06:02 imagejan

Any news on this issue? I try to read ics images with libics (https://github.com/svi-opensource/libics). If I read this example image (http://loci.wisc.edu/sample-data/qdna1) everything works fine. I can also convert it to tif and save it as tif. KNIME/Fiji are able to open the original example image and it is possible to save it as tif. But if the image is saved as ics from KNIME/Fiji and then read with libics I get 5 dimensions (original has 2) and the converted tif is mixed up. Opening the image written by KNIME/Fiji works just fine.

tibuch avatar Apr 12 '18 14:04 tibuch

Opening the image written by KNIME/Fiji works just fine. Which image do you mean in that sentence? The one read as ICS and written as TIF?

gab1one avatar Apr 12 '18 15:04 gab1one

That is confusing, sorry. What I did:

  1. Read example ICS image with KNIME/Fiji.
  2. Write this image with KNIME/Fiji as ICS. (example_from_knime_fiji.ics)
  3. Read this image (example_from_knime_fiji.ics) which works fine.
  4. Read this image via libics results in 5 dimensions.

tibuch avatar Apr 12 '18 15:04 tibuch

So the metadata was modified during reading?

gab1one avatar Apr 13 '18 10:04 gab1one

Maybe, but it was definitely modified during writing. And it was modified in such a way that it can't be read by libics but KNIME/Fiji can still read it.

tibuch avatar Apr 13 '18 10:04 tibuch

Sorry now I understand, this seems to be a bug in the scifio ics format. I will file it there.

gab1one avatar Apr 16 '18 07:04 gab1one

Thanks!

tibuch avatar Apr 16 '18 12:04 tibuch