-
Notifications
You must be signed in to change notification settings - Fork 261
Coordinate x and z are inverted in minc 1 format #372
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
I think you'll find that the MINC array axes are also reversed. This is
just a feature of the way that MINC expected its data. It's convention is
that the fastest changing axis is last instead of first. So, the array
should be transposed relative to the matching NIfTI and the affine reflects
that...
|
I agree the thing is that this is inconsistent with the way you present the data in other format that could lead to error e.g if we use affine transformation from different format. is there a method at leas to make a sanity check about the dimension order? Thank you a lot for your great work! |
Sorry, I am not sure what you mean by a sanity check about the dimension
order - could you say more?
|
Yes it is just that in order to prevent mistake loading a nii or a mnc file I would have expect to have the coordinate in the same order or a function that would provide if the dimensions are in xyz or zyx. let's take an hypothetical example: I will have to specify the x,y,z coordinates for the nii file and the z,y,x coordinate for the mnc1 file. |
@cdansereau I think the expectation is that users should know about the image formats of their data. My understanding is that With that said, #300 is probably along the lines of what you're looking for--a function that you can use to get data in a common format. |
@bcipolli Not to get too far off-topic, but the goal of #300 is to create a new image from an old one, but with a new data array. Unless I'm missing something about the underlying new image creation, all a
|
Cool, thanks for clarifying! |
@cdansereau Here's a quick function that does what I think you're asking for:
|
Hi,
The coordinate x and z are inverted in when we load minc 1 format
see the affine transformation it will make it clear
I notice that problem when I try to go from the voxel space to the world space using the following
This is the correct coordinates using the nii file :
This is the result with the same file in mnc1 format :
The text was updated successfully, but these errors were encountered: