Unpack the data from bourget:

Find your subject...

To find your data, run the findsession command, passing it the "patient name", which is the name that you registered the subject under when scanning:

["findsession patientname"]

This will give you a list of all matching data sets, including paths to where each one can be found. E.g.,

/space/chartres/6/siemens/TRIO-20501-20020416-124756-468000

All the runs/series for your subject's visit will be in this directory. You can do more elaborate searches with findsession. To get more info, run findsession with -help.

Unpack the data

Unpacking is the process through which you convert the data from DICOM format (which is not very useful) to a format that can be used by an analysis programe (e.g., bhdr, nifti, analyze, mgh, mgz). The program that does this is unpacksdcmdir (this is only used to unpack Siemens DICOM files). mri_convert can also be used to convert individual runs, whereas unpacksdcmdir can be used to unpack any or all data from a directory. Below we go through some simple unpacking. unpacksdcmdir can do a lot more. Run it with -help to get full documentation.

The first step in unpacking is to decide where you want your data to be stored. Usually, you choose a "parent" directory under which all of the visits for a study will be stored. E.g., /space/data/1/users/you/data-parent. The actual target data for a given visit from a subject would be stored under something like /space/data/1/users/you/data-parent/yoursubject.

Next, you need to find out exactly what data are in the dicom directory. Specificially you need to know which run/series number corresponds to which acquisition. To do this run:

where dicomdir is the directory where the dicom data reside (as found above by findsession), targetdir is where you want the individual's data to go, and the scan.info file will contain a list of run/series numbers along with the scanning protocol that was used to acquire the data, and will look something like this:

To actually do the unpacking, you will need to run unpacksdcmdir again with a slightly different set of arguments:

["unpacksdcmdir"] -src dicomdir -targ targetdir -fsfast \

The -fsfast argument tells unpacksdcmdir to use the FS-FAST directory structure (if you want to specify a structure explicitly, use -generic). Each -run flag is followed by 4 arguments: (1) the run number (as found in the scan.info file), (2) a directory, (3) format, and (4) file name. In fsfast directory structure, run 2 will be stored in targetdir/bold/002 in bshort format. bshort format will have many files that start with "f" (i.e., the file name given as the 4th argument). Each of the fMRI runs (2-6) will be stored under the "bold" directory (this is also known as the "functional subdirectory" or fsd). Subsequent fsfast commands will expect this directory structure. Also, there will be an seq.info file in the bold directory with information about the acquistion. If you collected several types of fMRI scans (eg, different slice prescriptsion, TR, TE, resolution, etc), then you should put each type in a separate fsd (e.g., -run 7 bold-hires bshort f).

Note that run 7 was not unpacked. Note also that the backslashes ("\") are unix command-line continuation characters and not part of the unpacksdcmdir arguments list. Runs 8 and 9 are an anatomicals which can be used in FreeSurfer processing; they will be stored in targetdir/3danat/008/001.mgz and 009/001.mgz (this is compressed mgh format). You can launch FreeSurfer on these volumes with:

recon-all -s yoursubjectname -i targetdir/3danat/008/001.mgz -i targetdir/3danat/009/001.mgz -all

where "yoursubjectname" is the FreeSurfer name for the subject as found in $SUBJECTS_DIR. Alternatively, you can create yoursubjname/mri/orig and then copy or link the mgz files into that directory as 001.mgz and 002.mgz and then launch recon-all.