Differences between revisions 29 and 30
Deletions are marked like this. Additions are marked like this.
Line 46: Line 46:
(This section reports on what I (GW) have learned of the registration process from Bruce Fischl. and Doug Greve, along with reading the source code. I have not actually tried it.)
Line 50: Line 52:
attachment:gw_make_template3.gif attachment:gw_make_template4.gif
Line 52: Line 54:
The process starts ("Prep") by choosing one reference subject, and producing a template. No ?h.sphere is required -- this step uses the subject's own pattern as the reference. (ie: ?h.sphere plays the role of ?h.sphere.reg). registering the other reference subjects to the first one, using ["mris_register"]'s "-1" (one) option. With this initial registration (?h.sphere.myreg0 for each subject), use ["mris_make_template"] to create an initial template (mytemp1.tif). The process starts ("Prep") by choosing one reference subject, and producing a template (Here, mytemp0.tif). No ?h.sphere is required -- this step uses the subject's own pattern as the reference.
Line 54: Line 56:
Then one or more iterations of the steps in the blue box are carried out where all the reference subjects are aligned to the latest template using mris_register (in it's normal "register-to-template" mode), then a new template is created based on the latest alignments. If Round 1, all reference subjects data are registered to the initial template, producing ?h.sphere.myreg0. (I've coordinated the suffix numbers with the template used to produce the registration.) Using that registration, a new template (mytemp1.tif) is made using all reference subjects as input.

Round 2 is essentially a repeat of Round 1, but produces an improved template (mytemp2.tif) because Round 2's initial registration step is based on a better template than in Round 1.

Sidenote: mris_register performs more of a rigid registration when it notices that the input template has degrees-of-freedom=1, as it is in Round 1, being based on only one subject. When dof is higher, as in Round 2, mris_register performs a more flexible warp.

The steps in the blue box could be iterated again if needed, but from what I've learned from Bruce F., this is generally not necessary.
Line 57: Line 65:
1. As of this date (2008-01-26), I have not verified that this process is entirely correct -- these are assembled from email exchanges with MGH investigators, and from reading source code. 1. The above diagram assumes that the subjects have all been processed once by !FreeSurfer's recon-all pipeline or similar to produce all the required files needed for the template-creation process. Recon-all will also have produced ?h.sphere.reg aligned to the standard reference template (?h.average.curvature.filled.buckner40.tif), and corresponding annotation files -- for purposes here, these can be ignored. Indeed, once a satisfactory new template has been created, the recon-all script can be modified to use the new template, and the subjects can be re-run to create new improved annotations.
Line 59: Line 67:
2. The above diagram assumes that the subjects have all been processed once by !FreeSurfer's recon-all pipeline or similar to produce all the required files needed for the template-creation process. Recon-all will also have produced ?h.sphere.reg aligned to the standard reference template (?h.average.curvature.filled.buckner40.tif), and corresponding annotation files -- for purposes here, these can be ignored. Indeed, once a satisfactory new template has been created, the recon-all script can be modified to use the new template, and the subjects can be re-run to create new improved annotations. 2. GW comment: Since the process uses a particular subject as the starting point, the final position of the template pattern is dependent on that first subject. The iterations of registration and template creation work to improve the variance aspect of the template.
Line 61: Line 69:
3. GW comment: Since the process uses a particular subject as the starting point, the final position of the template pattern is dependent on that first subject. The iterations of registration and template creation work to improve the variance aspect of the template.

4. For technical details on the template file contents and format, see: TemplateTifImageFiles.
3. For technical details on the template file contents and format, see: TemplateTifImageFiles.

The Surface Registration Process; Templates

Index TableOfContents

Overview

This page provides an overview of two related topics:

  • How the FreeSurfer pipeline registers the surfaces of individual subjects to an "average" reference surface, using "template" ("tif") file.

  • The process of creating one's own template file, perhaps for subject groups or species for which the provided template is not suitable.

You might also be interested in these related topics:

  • Technical details on template file contents and format: TemplateTifImageFiles.

  • The possibility of registering subjects surfaces based on functional MRI data. See the script mksurfatlas that's part of the FreeSurfer distibution.

  • How surface label atlases are created and used: SurfaceLabelAtlas

Disambiguation: template, atlas, parameterization file, average surface

  • In many places, especially within the FreeSurfer source code, the word "atlas" is often used interchangeably with "template". I am reserving the term "atlas" for the GCA files used in labeling regions. A template file is also sometimes referred to as a "parameterization file".

  • The process of creating a template based on a number of reference subjects is sometimes called "making an average surface". This should not be confused with the process of averaging the surfaces of a group of subjects to create, for example, an average white surface (perhaps for plotting fMRI data). (This is what I think mris_["mris_make_average_surface"] does, and I think it's unrelated to the topic of this page. -- GW)

The FreeSurfer pipeline surface registration process

(In the following "?h." refers to a file name hemisphere prefix of either "lh." or "rh.".)

The registration process includes several key steps:

Inflated Spherical "version" of a subject's surface mesh

As the FreeSurfer pipeline processes a subject's data, the initial white surface mesh is "inflated" to several other states, one of which is a sphere, typically ?h.sphere. The inflation process is constrainted to minimize the total distortion.

Vertex-wise data is applicable to all versions of the surface

The inflation process does not add or remove any vertices, so any data associated with the white vertices (such as curvature or convexity) is still associated with the same-numbered vertices of the sphere mesh. This is the basis of displays such as the following where a per-vertex variable "convexity" of the white surface (aka 'sulc') is plotted in color on the lh.sphere surface.

attachment:fsbert_sulc_sphere.jpg

Registration of a subject's surface

Registration of a subject's surface to a reference consists of a 2-D warp of the subject's sphere surface so that the individual's curvature data pattern aligns with a reference template pattern. The template was previously prepared as the "average" (loosely speaking) pattern from a group of representative subjects. The standard template supplied with FreeSurfer is in the files {fshome}/average/?h.average.curvature.filled.buckner40.tif.

Registration output

The output from registration is yet another version of the subject's surface mesh, typically named ?h.sphere.reg, with the x,y,z vertex positions still on a sphere, but warped so that the subject's curvature pattern best aligns with the template data. Here is the same convexity data, now plotted on the lh.sphere.reg surface. Similar pattern, but "stretched around".

attachment:fsbert_sulc_spherereg.jpg

Registration process diagram

The diagram below summarizes the registration process. Program mris_register inputs a specific subject's ?h.sphere.reg file and associated sulc and curv data from the inflated and smoothwm surfaces. The program compares these to the template file input. The registration sphere, ?h.sphere.reg is output.

attachment:gw_sphere_reg.gif

Creating a registration template

(This section reports on what I (GW) have learned of the registration process from Bruce Fischl. and Doug Greve, along with reading the source code. I have not actually tried it.)

The process of creating a template involves calculating an "mean" (across subjects) pattern of curvature-related values, along with the variance of these variables. This task is performed by program mris_make_template. However, mris_make_template expects the input subjects to be already aligned (ie: already have ?h.sphere.reg files). This of course will not be the case if you are about to create a template!

Consequently, the process proceeds iteratively, as shown in the following figure.

attachment:gw_make_template4.gif

The process starts ("Prep") by choosing one reference subject, and producing a template (Here, mytemp0.tif). No ?h.sphere is required -- this step uses the subject's own pattern as the reference.

If Round 1, all reference subjects data are registered to the initial template, producing ?h.sphere.myreg0. (I've coordinated the suffix numbers with the template used to produce the registration.) Using that registration, a new template (mytemp1.tif) is made using all reference subjects as input.

Round 2 is essentially a repeat of Round 1, but produces an improved template (mytemp2.tif) because Round 2's initial registration step is based on a better template than in Round 1.

Sidenote: mris_register performs more of a rigid registration when it notices that the input template has degrees-of-freedom=1, as it is in Round 1, being based on only one subject. When dof is higher, as in Round 2, mris_register performs a more flexible warp.

The steps in the blue box could be iterated again if needed, but from what I've learned from Bruce F., this is generally not necessary.

Notes

1. The above diagram assumes that the subjects have all been processed once by FreeSurfer's recon-all pipeline or similar to produce all the required files needed for the template-creation process. Recon-all will also have produced ?h.sphere.reg aligned to the standard reference template (?h.average.curvature.filled.buckner40.tif), and corresponding annotation files -- for purposes here, these can be ignored. Indeed, once a satisfactory new template has been created, the recon-all script can be modified to use the new template, and the subjects can be re-run to create new improved annotations.

2. GW comment: Since the process uses a particular subject as the starting point, the final position of the template pattern is dependent on that first subject. The iterations of registration and template creation work to improve the variance aspect of the template.

3. For technical details on the template file contents and format, see: TemplateTifImageFiles.

References

The registration process is a main topic in: High-resolution inter-subject averaging and a coordinate system for the cortical surface, Fischl, B., Sereno, M.I., Tootell, R.B.H., and Dale, A.M., (1999). Human Brain Mapping, 8:272-284(1999). See ArticlesSlidesAndPosters

Document Author(s)

GrahamWideman

SurfaceRegAndTemplates (last edited 2011-05-16 10:21:28 by tanha)