Class DisplacementFieldN5Tools

java.lang.Object
net.preibisch.mvrecon.process.fusion.blk.DisplacementFieldN5Tools

public final class DisplacementFieldN5Tools extends Object
Static helpers to persist displacement fields to an N5/Zarr container and reload them as in-memory ArrayImgs. Layout: each dfield is stored as a 4D dataset of shape (n, gridX, gridY, gridZ) where n is the number of vector components (3 for 3D). The spacing (double[]) and offset (double[]) used during sampling are written as N5 attributes on the dataset so that the DisplacementFields.TransformedDisplacementField can be reconstructed exactly on the read side. Important: per the perf contract of BlkThinPlateSplineFusion, the read side returns an ArrayImg-backed dfield (not a lazy CachedCellImg). The downstream block operator is tuned for ArrayImg access patterns.