top | previous

Testing your FreeSurfer installation

There is a sample subject, called 'bert', found in the freesurfer/subjects directory, which contains pre-processed data stored in .mgz files.

freeview (volume & surface viewer)

$> <source_freesurfer>
$> freeview -v $SUBJECTS_DIR/bert/mri/brainmask.mgz -v $SUBJECTS_DIR/bert/mri/aseg.mgz:colormap=lut:opacity=0.2 -f $SUBJECTS_DIR/bert/surf/lh.white:edgecolor=yellow -f $SUBJECTS_DIR/bert/surf/rh.white:edgecolor=yellow -f $SUBJECTS_DIR/bert/surf/lh.pial:annot=aparc:edgecolor=red -f $SUBJECTS_DIR/bert/surf/rh.pial:annot=aparc:edgecolor=red

recon-all -help

The Freesurfer command:

$> recon-all --help | less

will print text on the overall functionality of Freesurfer.

recon-all -all

To re-create all volume and surface files, on the command-line type:

$> recon-all -s bert -all

If you get a permission error type the following:

$> sudo chmod -R a+w $FREESURFER_HOME/subjects/bert

Then try again.

$> recon-all -s bert -all

Note that this operation may take 24 hours to complete. Consult recon-all --help for instructions on how to conduct multi-stage processing (eg. -autorecon1, -autorecon2 and -autorecon3). The -autorecon1 stage completes in less than a half an hour, and is worth running to test your installation, as it exercises most of the libraries. To run, type:

$> recon-all -s bert -autorecon1

Getting started with your own data

Given a subject having two sets of DICOMS (two runs of structural scans), do the following to setup a subject, where <subjid> is replaced with whatever name or id you want to give to that subject and SUBJECTS_DIR is set to the directory where you want to keep your subjects:

$> recon-all -s <subjid> \
   -i <path_to_dicoms>/95555-2-1.dcm 
   -i <path_to_dicoms>/95555-3-1.dcm

Now you will have two files in $SUBJECTS_DIR/<subjid>/mri/orig, named 001.mgz and 002.mgz. The recon-all -i command has taken your two structural scans and converted them to .mgz format. Note that in your own case, the name of the dicom files will be different (in this example, 95555-2-1.dcm is the first of a collection of 128 files). This import command is only issued once, i.e. once your data has been successfully imported, do not use the -i flags again. With the two structural scans now imported into a freesurfer subject directory, you can begin processing the subject:

$> recon-all -s <subjid> -all

Questions?

Send email to: freesurfer AT nmr DOT mgh DOT harvard DOT edu

Bug reports: analysis-bugs AT nmr DOT mgh DOT harvard DOT edu

TestingFreeSurfer (last edited 2021-09-22 11:47:02 by DevaniCordero)