-
Notifications
You must be signed in to change notification settings - Fork 29
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
f3d permuted output #680
Comments
weird and worrying. Can you confirm that this image is the displacement field output (I guess so, as z=0)? Is your registered output image ok? What happens if you use the output disp field to resample the "floating"? Are the niftyreg disp fields zero? |
Answers to @KrisThielemans :
|
Hi. Looks like the problem is in the symmetric part of f3d unfortunately. Add and remove
Since I wrapped the symmetric version of the algorithm, it seems we always have that problem. I switched our wrapped algorithm from the symmetric to non-symmetric version, and the problem disappeared. Solutions include:
I'll have a quick look at NiftyReg to see if I can spot a bug. Second would be a shame, since symmetric algorithms can be useful. Third option is obviously horrible. |
ouch. if it's a bug in niftyreg, we should create an issue on their github (whichever is the currently most active, if any). and then pray... |
Done - KCL-BMEIS/niftyreg#71 |
In the meantime, to fix this I'll add an option to use the symmetric component or not. Then, until the bug is fixed the non-symmetric version can be used. |
great. would be good to add a test-case for this. @AnderBiguri should be easy to use your script as a basis. It's a python test, but better that than nothing. |
I've added a test to the PR. It fails for the old implementation and passes when symmetric is off. |
@rijobro should we have an open issue saying that f3d only wraps/exposes non symetric until NiftyReg fixes their stuff? |
Sure, would you mind? |
When running the f3d registration, I noticed that my outputs/displacement/deformations are X-Y permuted. For a given identity transformation I get correct Displacement fields, they are just non-zero, they describe a X-Y permutation. You can see the output image being permuted too.
You can test this with:
I can reproduce the same results with different images (i.e. I have not only tried an identity transform). I can also reproduce it by calling
sirf_registration --algo f3d --ref ....
via the command line.I can not reproduce it if I call niftyreg directly:
reg_f3d ....
No parameters have been set in any of the cases, whichever are default have been used.
In my particular test, Displacement fields look like this:
The text was updated successfully, but these errors were encountered: