Differences between revisions 1 and 8 (spanning 7 versions)
Revision 1 as of 2008-01-19 07:27:09
Size: 2243
Comment:
Revision 8 as of 2008-01-19 08:03:32
Size: 3378
Comment:
Deletions are marked like this. Additions are marked like this.
Line 8: Line 8:
 * Labels:
 * Color Lookup Tables
 * Annotation Files
== Label ==

A label is an integer value which can be associated with a surface mesh vertex, or with a voxel, to indicate that it belongs to some region of interest. This could mark the vertex or voxel as part of an anatomical region, or it could mark the vertex/voxel as part of a region for analysis.

Sometimes when speaking or writing loosely, the word "label" is used as shorthand for "the set of vertices marked with a particular label". Sometimes vertices are said to "belong to a label", meaning that these vertics belong to the set marked by that label. "Saving a label" refers to saving into a file the list of vertices marked by a particular label value.

== Label file ==
A label file is a text file capturing a list of vertices belonging to a region, including their spatial positions(using R,A,S coordinates). Because both vertex number and corresponding position are listed, a label file can be used by either tksurfer or tkmedit to identify surface or volume locations belonging to the region.

It should be noted that a label file's vertex numbers will apply to several surfaces of a subject: for example the white surface, the pial surface, the inflated surface and so on. However the R,A,S positions are those of a particular one of these surfaces, according to selections in effect when the label file was saved by tksurfer.

Perhaps surprisingly, a label file contains neither the label code nor label name that it pertains to. Instead it is conventional to name the label file in a manner that indicates the label intended, though this naming convention has varied over the years. Examples:
 * lh.cortex.label
 * lh-avg_calcarine_sulcus.label.

=== Label file format ===
{{{
#!ascii label , from subject
1806
7 -22.796 -66.405 -29.582 0.000000
89 -22.273 -43.118 -24.069 0.000000
138 -14.142 -81.495 -30.903 0.000000
[...]
}}}

||'''Row'''||'''Col1'''||'''Col2'''||'''Col3'''||'''Col4'''||'''Col5'''||
||1||Comment|| || || || ||
||2||Count of subsequent rows|| || || || ||
||3..end||Vertex num||R coord||A coord||S coord||Don't know||

== Color Lookup Table ==
In FreeSurfer a "color lookup table" is a table cross-referencing the integer label code to a name, and to a color (Red, Green, Blue and Opacity values). Although called a "color lookup", in many usages it is the cross-reference to name, or simply the list of names, which is important.

 * Annotation: An annotation
Line 16: Line 47:
x
Line 18: Line 51:
== Annotations ==  x

== Annotations ==

x
Line 26: Line 63:
 * EditingLabels : Pointers to a couple of pages about labels   * EditingLabels : Pointers to a couple of pages about labels
Line 29: Line 66:
= Synopsis =
command argA argB -flag1 arg1 -flag2 arg2 [-flag3 arg3] [-flag4 arg4]
Line 32: Line 67:
= Arguments =
== Positional Arguments ==
|| argA || brief description || detailed description (eg, help file information) ||
|| argB || brief description || detailed description (eg, help file information) ||

== Required Flagged Arguments ==
|| -flag1 arg1 || brief description || detailed description (eg, help file information) ||
|| -flag2 arg2 || brief description || detailed description (eg, help file information) ||

== Optional Flagged Arguments ==
|| -flag3 arg3 || brief description ||detailed description (eg, help file information) ||
|| -flag4 arg4 || brief description ||detailed description (eg, help file information) ||
 
= Outputs =
|| volume1 || description ||
|| volume2 || description ||

= Description =
description

= Examples =
== Example 1 ==
command foo -i f -o out

description

== Example 2 ==
command foo -i f -o out -f fvalue

description

= Bugs =
None

= See Also =
["othercommand1"], ["othercommand2"]

= Links =
FreeSurfer, FsFast

= Methods Description =
{{{
description
description
}}}

= References =
["References/Lastname###"]

= Reporting Bugs =
Report bugs to <analysis-bugs@nmr.mgh.harvard.edu>

= Author/s =
JaneSmith
= Document Author/s =
GrahamWideman

Index TableOfContents

Labels, Color Lookup Tables and Annotation Files

This page discusses the basic concepts of FreeSurfer files that relate to identifying regions-of-interest for surfaces and volumes.

Label

A label is an integer value which can be associated with a surface mesh vertex, or with a voxel, to indicate that it belongs to some region of interest. This could mark the vertex or voxel as part of an anatomical region, or it could mark the vertex/voxel as part of a region for analysis.

Sometimes when speaking or writing loosely, the word "label" is used as shorthand for "the set of vertices marked with a particular label". Sometimes vertices are said to "belong to a label", meaning that these vertics belong to the set marked by that label. "Saving a label" refers to saving into a file the list of vertices marked by a particular label value.

Label file

A label file is a text file capturing a list of vertices belonging to a region, including their spatial positions(using R,A,S coordinates). Because both vertex number and corresponding position are listed, a label file can be used by either tksurfer or tkmedit to identify surface or volume locations belonging to the region.

It should be noted that a label file's vertex numbers will apply to several surfaces of a subject: for example the white surface, the pial surface, the inflated surface and so on. However the R,A,S positions are those of a particular one of these surfaces, according to selections in effect when the label file was saved by tksurfer.

Perhaps surprisingly, a label file contains neither the label code nor label name that it pertains to. Instead it is conventional to name the label file in a manner that indicates the label intended, though this naming convention has varied over the years. Examples:

  • lh.cortex.label
  • lh-avg_calcarine_sulcus.label.

Label file format

1806
7  -22.796  -66.405  -29.582 0.000000
89  -22.273  -43.118  -24.069 0.000000
138  -14.142  -81.495  -30.903 0.000000
[...]

Row

Col1

Col2

Col3

Col4

Col5

1

Comment

2

Count of subsequent rows

3..end

Vertex num

R coord

A coord

S coord

Don't know

Color Lookup Table

In FreeSurfer a "color lookup table" is a table cross-referencing the integer label code to a name, and to a color (Red, Green, Blue and Opacity values). Although called a "color lookup", in many usages it is the cross-reference to name, or simply the list of names, which is important.

  • Annotation: An annotation

Details

Labels

x

Color Lookup Tables

x

Annotations

x

Related pages

  • AnnotFiles : Some brief end-user notes on annotation files, plus MatLab and C developer notes.

  • ["mris_label2annot"] : Documentation for the command-line program that amalgamates label files (plus optional color lookup table file) into a single annotation file.
  • ["mri_annotation2label"] : Documentation for the command-line program that breaks an annotation file into individual label files
  • EditingLabels : Pointers to a couple of pages about labels

  • TkSurferGuide/TkSurferWorkingWithData/TkSurferLabel : Working with labels

Document Author/s

GrahamWideman

LabelsClutsAnnotationFiles (last edited 2018-09-28 13:42:03 by 66)