Skip to content

N5 Writer & File Export Challenges #146

@AdvancedImagingUTSW

Description

@AdvancedImagingUTSW

n5

I have been having some strange behavior, and increasingly suspect that the latest update to BigStitcher isn't working as intended. I have been working with some new data sources, so I have been working to rule out that the data doesn't have some strange metadata that could be causing the problem. I no longer thing that is the case.

When I manually define a dataset and resave the dataset as an n5 object in place, zero blocks are written in the sub-directories but the log throws no errors and saves the XML file as if everything worked appropriately. Worryingly, the Max dimensions of the image that will be resaved is listed as [0, 0, 0].

image

The dimensions also seem completely incorrect in the attributes.json file, and I do not see the pixel resolution information.

{"downsamplingFactors":[[1,1,1]],"dataType":"uint16","compression":{"type":"raw"},"blockSize":[128,128,64],"dimensions":[0,0,0]}

It appears to be loading the data incrementally, so perhaps it is a resave issue...
image

From the log...

Thu Dec 19 09:32:08 CST 2024: Loading '/archive/bioinformatics/registration/syt_tub_EEA1/position 5/decon/1_CH00_000000.tif' ...
Thu Dec 19 09:37:27 CST 2024: Opened '/archive/bioinformatics/registration/syt_tub_EEA1/position 5/decon/1_CH01_000000.tif' [2048x512x1820 image=CellImg<UnsignedShortType>]

When I load the data and resave it as an N5 file using the File -> Save As -> HDF5/N5/Zarr/OME-NGFF ... dialog it works appropriately. The attributes.json file looks correct, and I can see each chunk with the n5 structure.

{"dataType":"uint16","compression":{"type":"raw"},"blockSize":[128,128,128],"dimensions":[2048,512,1820],"pixelResolution":{"unit":" ","dimensions":[1.0,1.0,1.0]},"downsamplingFactors":[1.0,1.0,1.0]}

HDF5

The image import is working, and it clearly creates a large monolithic HDF5 file. When I select Display Raw Images -> As 16-Bit ImageJ Stack it loads the proper image from the HDF5 file. However, when I try to export the data, it shows that the dimensions of my fused image will be 0 x -1 x 1...

image

When I try to quick display a selected image, I get the following error as well:

Exception in thread "Thread-80" java.lang.IllegalArgumentException: Stack is empty
	at ij.ImagePlus.setStack(ImagePlus.java:826)
	at ij.ImagePlus.<init>(ImagePlus.java:162)
	at net.imglib2.img.display.imagej.ImageJFunctions.makeImagePlus(ImageJFunctions.java:305)
	at net.imglib2.img.display.imagej.ImageJFunctions.wrapFloat(ImageJFunctions.java:293)
	at net.imglib2.img.display.imagej.ImageJFunctions.wrap(ImageJFunctions.java:237)
	at net.preibisch.mvrecon.process.export.DisplayImage.getImagePlusInstance(DisplayImage.java:174)
	at net.preibisch.mvrecon.process.export.DisplayImage.getImagePlusInstance(DisplayImage.java:153)
	at net.preibisch.mvrecon.fiji.spimdata.explorer.popup.DisplayFusedImagesPopup$DisplayVirtualFused$1.run(DisplayFusedImagesPopup.java:240)
	at java.lang.Thread.run(Thread.java:750)

I apologize for the long-winded explanation, just trying to help. I am using Big_Stitcher-2.2.1.jar.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions