help
help > RE: Using acpcdetect to get pitch, roll, and yaw
Nov 2, 2018 07:11 PM | Babak Ardekani
RE: Using acpcdetect to get pitch, roll, and yaw
Originally posted by Pravesh Parekh:
Hello,
I issued the following command:
acpcdetect -i filename.nii -no-tilt-correction -center-AC -noppm -nopng -v
Regards
Pravesh
Originally posted by Babak Ardekani:
In NIFTI header there are three vectors:I issued the following command:
acpcdetect -i filename.nii -no-tilt-correction -center-AC -noppm -nopng -v
Regards
Pravesh
Originally posted by Babak Ardekani:
Sorry, I should have made my self clearer.
I was asking what is the command line that you issued to run
acpcdetect including all the options?
Babak
Babak
float srow_x[4] ; /*!< 1st row affine transform. */
float srow_y[4] ; /*!< 2nd row affine transform. */
float srow_z[4] ; /*!< 3rd row affine transform. */
These are set by acpcdetect.
NIFTI defineds the x,y,z directions as:
+x = Right +y = Anterior +z = Superior
Let's say (i,j,k) are the coordinates of the AC as detected by acpcdetect, they to get the transformed AC location you will perform the
following:
x = srow_x[0] * i + srow_x[1] * j + srow_x[2] * k + srow_x[3]
y = srow_y[0] * i + srow_y[1] * j + srow_y[2] * k + srow_y[3]
z = srow_z[0] * i + srow_z[1] * j + srow_z[2] * k + srow_z[3]
Since you chose -center-AC option, the (i,j,k) of the AC locations should map to point (0,0,0), the center of the FOV of the transformed image.
Hope this helps.
Babak
P.S. I should add that since in acpcdetect V2 the transformation is further adjusted using the 8 Orion landmarks, AC may not be mapped exactly to (0,0,0) by the above formula, but it will be close. To map the AC exactly to (0,0,0) you should use the -standard option as well, that is:
acpcdetect -i filename.nii -no-tilt-correction -center-AC -noppm -nopng -v -standard
Threaded View
Title | Author | Date |
---|---|---|
Pravesh Parekh | Oct 31, 2018 | |
Pravesh Parekh | Nov 2, 2018 | |
Babak Ardekani | Nov 2, 2018 | |
Babak Ardekani | Nov 2, 2018 | |
Pravesh Parekh | Nov 2, 2018 | |
Babak Ardekani | Nov 2, 2018 | |
Pravesh Parekh | Nov 3, 2018 | |
Babak Ardekani | Nov 6, 2018 | |
Babak Ardekani | Oct 31, 2018 | |
Pravesh Parekh | Nov 1, 2018 | |
Babak Ardekani | Nov 2, 2018 | |
Pravesh Parekh | Nov 2, 2018 | |