Differences between revisions 16 and 35 (spanning 19 versions)
Revision 16 as of 2006-03-22 17:22:48
Size: 2992
Comment: changed FixingDefects to FixingGeomInaccuracies
Revision 35 as of 2014-04-03 13:59:26
Size: 4139
Editor: LouisVinke
Comment:
Deletions are marked like this. Additions are marked like this.
Line 1: Line 1:
#acl AdminGroup:read,write,delete,revert All:read
[wiki:Self:FreeSurferWorkFlows top] | [wiki:Self:BasicReconstruction previous] | [wiki:Self:HistoricalReconstruction next]
#acl LcnGroup:read,write,delete,revert All:read
[[FreeSurferWorkFlows|top]] | [[BasicReconstruction|previous]] | [[HistoricalReconstruction|next]]
Line 4: Line 4:
This workflow completes the reconstruction process in three different steps, allowing the user to check the outputs before proceeding. See the ReconAllDevTable for a list of the steps run with this command OtherUsefulFlags for a list of other flags that you can use with recon-all. Any manual intervention that is needed is done before moving on to the next step, which can save both time and use of computer power.
Although the reconstruction process is broken down into three different stages, this workflow suggests that the user run all these steps at once before beginning to inspect the data. This allows the user to see the final complete output before deciding on any interventions. Any manual intervention needed can be all done at once (with the exception of the talairach and the skullstrip) which can save both time and use of computer power. See the ReconAllDevTable for a list of all the steps associated with each recon stage, or ReconAllBlockDiagram for a different presentation, and OtherUsefulFlags for a list of other flags that you can use with recon-all.
Line 15: Line 14:
 3. Run the first step of recon-all. See the ReconAllDevTable for individual steps that will be run during the whole process.
    '''`recon-all -i `''invol1''` -i `''invol2''` -autorecon1 -subjid `''your_subject_name'''''
 3. Import your data and create a subject data directory. This is done '''once''' using the following command:
Line 18: Line 16:
    where ''invol1'' and ''invol2'' are paths to your input files. You can use as many as necessary (i.e., '''-i ''invol3'' -i ''invol4''''') and they can be in any format that is accepted by mri_convert     '''`recon-all -i `''invol1''` -i `''invol2''` -subjid `''your_subject_name'''''
Line 20: Line 18:
 4. Check the talairach transform:
   '''`tkregister2 --mgz --s `''your_subject_name''` --fstal`'''
    where ''invol1'' and ''invol2'' are paths to your input files. You can use as many as necessary (i.e., '''-i ''invol3'' -i ''invol4''''') and they can be in any format that is accepted by mri_convert (i.e. DICOM, MGZ, NIFTI, etc.). The command above will create an empty directory named ''your_subject_name'', except the mri/orig directory will contain files named 001.mgz and 002.mgz, which are your imported structurals. Once your input files are imported, you do not need to use the -i flags again.
Line 23: Line 20:
  For intructions on how to fix bad talairachs tranforms, refer to:
   * ["FsTutorial/Talairach"]
 4. Run the all the steps of recon-all. See the ReconAllDevTable for individual steps that will be run during the whole process.
    '''`recon-all -all -subjid `''your_subject_name'''''
Line 26: Line 23:
 5. Check the skull strip:    After your subject finishes running, do the following to make sure the recon was successful.

 5. Check the talairach transform:
   '''`tkregister2 --mgz --s `''your_subject_name''` --fstal --surf orig`'''
     (exclude '''`--surf orig`''' if surfaces have not been generated yet)

  For instructions on how to fix bad talairachs tranforms, refer to:
   * [[FsTutorial/Talairach_tktools]]

 6. Check the skull strip:
Line 30: Line 37:
   * FsTutorial/ControlPoints
      After adding control points run the step [wiki:Self:OtherUsefulFlags -autorecon2-cp] (this will run -normalization, using control points, and everything else through the end of -autorecon2.)
   * FsTutorial/SkullStripTutorial
   * [[FsTutorial/ControlPoints_tktools]]
      After adding control points run the steps [[OtherUsefulFlags|-autorecon2-cp]] (this will run -normalization, using control points, and everything else through the end of -autorecon2) and -autorecon3 (this will update all your stat tables with the new changes).
   * [[FsTutorial/SkullStripFix_tktools]]
      After adjusting the skullstrip, run the steps -autorecon2 and -autorecon3.
Line 34: Line 42:
 6. After you have an accurate brain volume, run the next step of recon-all:
    '''`recon-all -autorecon2 -subjid `''your_subject_name'''''
Line 37: Line 43:
   '''`tkmedit `''your_subject_name''` wm.mgz rh.white -aux brainmask.mgz -aux-surface lh.white`'''    '''`tkmedit `''your_subject_name''` brainmask.mgz -aux wm.mgz -surfs`'''
Line 39: Line 45:
  For intructions on editing the final surfaces, refer to:
   * FsTutorial/FixingGeomInaccuracies
      After editing the wm.mgz volume run the step [wiki:Self:OtherUsefulFlags -autorecon2-wm] (this will run -fill, using new wm.mgz volume, and everything else through the end of -autorecon2.)
   * FsTutorial/PialEdits
      After editing the brainmask.mgz volume run the step [wiki:Self:OtherUsefulFlags -autorecon2-pial] (this will run -finalsurfs, using new brainmask.mgz volume, and everything else through the end of -autorecon2.)
   * FsTutorial/FinalSurfEx
  For instructions on editing the final surfaces, refer to:
   * [[FsTutorial/WhiteMatterEdits_tktools]]
      After editing the wm.mgz volume run the steps [[OtherUsefulFlags|-autorecon2-wm]] (this will run -fill, using new wm.mgz volume, and everything else through the end of -autorecon2) and -autorecon3.
   * [[FsTutorial/PialEdits_tktools]]
      After editing the brainmask.mgz volume to adjust the pial surface, run the steps [[OtherUsefulFlags|-autorecon-pial]] (this will run -finalsurfs, using new brainmask.mgz volume, and everything else through the end of -autorecon3.)
   * [[FsTutorial/FinalSurfEx]]
Line 46: Line 52:
 8. After you have accurate pial and white surfaces run the final step of recon-all:
     '''`recon-all -autorecon3 -subjid `''your_subject_name'''''
 8. Next, check the segmentations:
   '''`tkmedit `''your_subject_name''` brainmask.mgz -surfs -aseg`'''

  For instructions on editing the aseg, refer to:
   * [[TkMeditGuide/TkMeditWorkingWithData/TkMeditSegmentations]]
      After editing the wm.mgz volume run the following steps: -normalization -maskbfs -segmentation -autorecon2-wm -autorecon3.

top | previous | next

Although the reconstruction process is broken down into three different stages, this workflow suggests that the user run all these steps at once before beginning to inspect the data. This allows the user to see the final complete output before deciding on any interventions. Any manual intervention needed can be all done at once (with the exception of the talairach and the skullstrip) which can save both time and use of computer power. See the ReconAllDevTable for a list of all the steps associated with each recon stage, or ReconAllBlockDiagram for a different presentation, and OtherUsefulFlags for a list of other flags that you can use with recon-all.

FreeSurfer Troubleshooting Reconstruction Work Flow

  1. Source the correct version of FreeSurfer:

    • source your_freesurfer_dir/SetUpFreeSurfer.csh

  2. Set your SUBJECTS_DIR variable to your subjects directory:
    • setenv SUBJECTS_DIR your_subjects_dir

  3. Import your data and create a subject data directory. This is done once using the following command:

    • recon-all -i invol1  -i invol2 -subjid your_subject_name

      where invol1 and invol2 are paths to your input files. You can use as many as necessary (i.e., -i invol3 -i invol4) and they can be in any format that is accepted by mri_convert (i.e. DICOM, MGZ, NIFTI, etc.). The command above will create an empty directory named your_subject_name, except the mri/orig directory will contain files named 001.mgz and 002.mgz, which are your imported structurals. Once your input files are imported, you do not need to use the -i flags again.

  4. Run the all the steps of recon-all. See the ReconAllDevTable for individual steps that will be run during the whole process.

    • recon-all  -all -subjid your_subject_name

    After your subject finishes running, do the following to make sure the recon was successful.
  5. Check the talairach transform:
    • tkregister2 --mgz --s your_subject_name --fstal --surf orig

      • (exclude --surf orig if surfaces have not been generated yet)

  6. Check the skull strip:
    • tkmedit your_subject_name brainmask.mgz -aux T1.mgz

    • For instructions on how to fix poor normalizations or skull strips, refer to:
  7. Check the white and pial surfaces:
    • tkmedit your_subject_name brainmask.mgz -aux wm.mgz -surfs

  8. Next, check the segmentations:
    • tkmedit your_subject_name brainmask.mgz -surfs -aseg

RecommendedReconstruction (last edited 2014-08-20 11:34:47 by AllisonMoreau)