Repository navigation
Conversation
|
This pull request has been mentioned on Image.sc Forum. There might be relevant details there: https://forum.image.sc/t/ome-zarr-0-6-and-newer-accidentally-forbid-ndim-changes/123425/1 |
|
Thanks @btbest !
Correct. As you wrote, the purpose of the most strict text was to ensure that for images, the intrinsic coordinate system has the same number of dimensions as the array. Your edits reflect that, so I approve! |
|
I edited the PR description to add the point regarding 0.6; I've set this up to merge into the 0.9dev branch, but I think since this is more of a clarification of original intention, it would be justified to also backport it to 0.6. |
Accompanies forum post https://forum.image.sc/t/ome-zarr-0-6-and-newer-accidentally-forbid-ndim-changes/123425
This PR merges into 0.9dev, because that's the minimum where it should be fixed. The problem it addresses already exists in the 0.6 text, so it could be considered if this should also be post-fixed onto 0.6.
Post duplicated here for convenience:
I had an agent on an unrelated task; it noticed a little problem in the spec phrasing:
This plainly forbids defining coordinate systems whose number of axes does not match "the image data", and it's a blanket statement in the general "axes" section, i.e. it applies to both multiscales and scenes.
The same requirement is reiterated specifically for multiscales later, also without a qualifier that it only applies to the multiscale's "intrinsic" system (i.e. it applies to all of the multiscale's systems):
The problem: I do think the point of defining coordinate transformations that can change dimensionality ("projectAxis", "affine", "coordinates" and "byDimension") was to enable coordinate systems with different numbers of axes. In the context of scenes, requiring coordinate systems to match "the image data" could be interpreted as requiring all image data in the scene to have the same ndim.
I don't actually think anyone intended this restriction. I don't recall it ever being mentioned, and neither ngff-zarr nor the official conformance tester enforce it. The conformance tester even supplies a projectAxis example that contradicts this phrasing, and calls it valid. The spec phrasing is quite unambiguous though.
Fix: I'm assuming this was really an accident, so I'm optimistic that no one would object to fixing the phrasing. The text change I'd propose is very small, and I've put it in a PR. The reason I'm posting here is to see if there are objections, because if it was an intentional rule, removing it is a serious change.
The concrete proposed text changes:
"axes" MUST contain at least one object".Related (same point): fideus-labs/ngff-zarr#859