Skip to content

AFNI

afni is a suite of tools for neuroimaging analysis.

Usage

AFNI version 23.0.08 is available on Picotte. You can load it using the modulefile:

module load afni/23.0.08

Then you can run AFNI commands, of which there are many. For example:

$ 3dDespike

Usage: 3dDespike [options] dataset

Removes 'spikes' from the 3D+time input dataset and writes
a new dataset with the spike values replaced by something
more pleasing to the eye.
...

Use APPTAINER_BIND to mount data

The AFNI installation on Picotte wraps the AFNI Singularity/Apptainer wraps the AFNI Singularity/Apptainer container. This means that you need to use the APPTAINER_BIND environment variable to mount data into the container. If you don't set this variable, AFNI commands will not be able to read and write files.

For example, to run the 3dDespike command, you can do the following:

module load afni/23.0.08
export APPTAINER_BIND=/path/to/data
3dDespike /path/to/data/input.nii.gz /path/to/data/output.nii.gz

Without setting APPTAINER_BIND, 3dDespike will not be able to read the input data.

You can mount multiple paths by separating them with a colon. For example:

export APPTAINER_BIND=/path/to/data:/path/to/other/data

Documentation

The AFNI documentation is available online.