Align AC PC to horizontal
anat
shell
code
visualization
alignment
Translate your structural scans to AC-PC alignment for visualization and display.
Align to the Anterior Commissure-Posterior Commisure Line
If you need help determining where the Anterior and Posterior Commisures are in your image, please see Commissural Pathways, available online, or Catani & Thiebaut de Schotten (2012), which is available from the UBC Library.
Download the
acpc_align
script from here. Be sure the code is in the folder where your participant’s structural scans are.Make the acpc_align.sh script executable.
chmod 755 acpc_align.sh
- Open your structural scan in your faviourite viewer. Here we are using FSLeyes.
- Get the X, Y and Z coordinates of the anterior commissure in voxel space by placing your cursor on the anterior commissure. The anterior commissure is located in the anterior wall of the third ventricle. It runs transversely anterior to the anterior columns of the fornix, above the basal forebrain and beneath the medial and ventral aspect of the anterior limb of the internal capsule. Save the X, Y, and Z coordinates.
- Get the X, Y, and Z coordinates of the posterior commissure in voxel space by placing your cursor on the posterior commissure. The posterior commissure is the inferior lamina or stalk of the pineal gland. Save the X, Y, and Z coordinates.
- In your terminal (MacOS or Linux) run
acpc_align subjectbrain.nii.gz -a x y z -p x y z
to produce the realigned image for subject-specific to acpc alignment.
In the example, this is
sh acpc_align.sh T1_reoriented.nii.gz -a 93 130 153 -p 93 98 152