User's Guide to SureFit Cortical Segmentation and ... - Semantic Scholar

4 downloads 3964 Views 3MB Size Report
Jan 24, 2001 - A conversion utility is available to convert from “raw” 8-bit or 16- ..... Surface reconstruction entails generation of a tessellation (wireframe mesh) that represents the ...... http://brainmap.wustl.edu/SureFit/DemoData.html.
SureFit User’s Guide (Version 4.38)

User’s Guide to SureFit Cortical Segmentation and Surface Reconstruction David C. Van Essen, Heather A. Drury, Donna Hanlon, John Harwell Version 4.38 February 25, 2002 Copyright © 1999, 2000, 2001, 2002 Washington University

Washington University School of Medicine Department of Anatomy and Neurobiology St. Louis, Missouri USA 63110

1

SureFit User’s Guide (Version 4.38)

Copyright © 1999, 2000, 2001, 2002. Washington University. Permission to use, copy, modify, and distribute this document solely for non-commercial applications is hereby granted by Washington University free of charge, provided that the copyright notice “Copyright 1999, 2000, 2001 Washington University” appears on all copies of the software and that this permission notice appears in all supporting documentation. The name of Washington University or of any of its employees may not be used in advertising or publicity pertaining to the software without obtaining prior written permission from Washington University. Washington University makes no representation about the suitability of this software for any purpose. It is provided “as is” without any express or implied warranty.

2

SureFit User’s Guide (Version 4.38)

Table of Contents PART 1. INTRODUCTION AND OVERVIEW ..................................................................... 6 1.1 WHY SUREFIT? ...........................................................................................................................................................6 1.2. INPUT DATA REQUIREMENTS ....................................................................................................................................6 1.2.1 Species and Structures Suitable for Reconstruction ..........................................................................................6 1.2.2 Functional Neuroimaging Data.........................................................................................................................7 1.3 HARDWARE REQUIREMENTS.......................................................................................................................................7 1.4 SOFTWARE AVAILABILITY .........................................................................................................................................7 1.5 BUG REPORTING AND SUGGESTIONS..........................................................................................................................7

PART 2. SUREFIT GUI REFERENCE GUIDE..................................................................... 8 2.1 2.2 2.2.1 2.3 2.3.1 2.3.2 2.3.3 2.3.4 2.3.5 2.4 2.4.1 2.4.2 2.4.3 2.4.4 2.4.5 2.5 2.5.1 2.5.2 2.6 2.7 2.7.1 2.7.2 2.7.3 2.7.4 2.7.5 2.7.6

ORGANIZATION AND TYPOGRAPHIC CONVENTIONS .........................................................................................8 LAUNCHING SUREFIT ........................................................................................................................................8 Menu Bar ..................................................................................................................................................8 NAVIGATING THROUGH VOLUME DATA ..........................................................................................................9 Loading Volume Data ..............................................................................................................................9 Screen Layout .........................................................................................................................................10 Volume Selection Tabs ...........................................................................................................................10 Navigating Through the Volume............................................................................................................11 Miscellaneous Volume Operations ........................................................................................................12 SURFACE OPERATIONS ....................................................................................................................................13 Loading Surfaces ....................................................................................................................................13 Viewing surfaces.....................................................................................................................................14 Generate Surfaces ..................................................................................................................................14 Smooth Surface .......................................................................................................................................15 Paint Surface. .........................................................................................................................................15 SURFACE-VOLUME RELATIONSHIPS ................................................................................................................15 Surface and Volume “Picking” .............................................................................................................16 Drawing Surface Slices ..........................................................................................................................16 SUREFIT OPERATIONS .....................................................................................................................................16 VISUALIZING FMRI DATA ..............................................................................................................................16 Split fMRI Volume ..................................................................................................................................17 Read fMRI Volume as Vol2 ....................................................................................................................17 Toggle fMRI Color Map.........................................................................................................................17 Adjust fMRI Mapping Parameters.........................................................................................................17 Map fMRI Data to Surface.....................................................................................................................17 View Painted fMRI Data. .......................................................................................................................17

PART 3. SUREFIT INSTRUCTIONS AND TUTORIAL .................................................... 18 3.1 CONVENTIONS ............................................................................................................................................................18 3.2 LAUNCHING SUREFIT ...............................................................................................................................................18 3.3 VOLUME PREPARATION ............................................................................................................................................19 3.3.1 Volume Information. ........................................................................................................................................19 3.3.2 Volume Orientation..........................................................................................................................................20 3.3.3 Setting the Anterior Commissure.....................................................................................................................21 3.3.4 Defining the Volume of Interest.......................................................................................................................22 3.3.5 Set Intensity peaks...........................................................................................................................................23 3.3.6 Resampling (NOT recommended for normal segmentation)...........................................................................24 3.3.7 Save Parameters................................................................................................................................................24 3.4 AUTOMATED SEGMENTATION, ERROR CORRECTION, AND SURFACE GENERATION ..............................................24 3.4.1 Run SureFit........................................................................................................................................................25 3.4.2 Interactive Error Correction. .........................................................................................................................27 3.4.3 A la Carte. ........................................................................................................................................................31 3.5 FORMATTING AND VISUALIZING FMRI DATA ........................................................................................................32 3.5.1 Formatting fMRI Volume Data.........................................................................................................................32 3.6 VOLUME AND SURFACE SPECIFICIATION FILES .......................................................................................................33 3

SureFit User’s Guide (Version 4.38) 3.7 SEGMENTATION OF A FULL HEMISPHERE .................................................................................................................33

APPENDICES I. INSTALLATION INSTRUCTIONS .................................................................................. 35 II. LOADING YOUR OWN DATA ....................................................................................... 36 III. TROUBLESHOOTING ................................................................................................... 38 IV. PARAMETER FILES AND SPECIFICATION FILES ................................................. 40 V. RELATED SOFTWARE................................................................................................... 43 VI. SUREFIT DESIGN PRINCIPLES ................................................................................. 44 A. UNDERLYING PHYSICAL AND IMAGING MODEL..........................................................................................................44 B. PROCESSING STAGES...................................................................................................................................................45 1. Initial Preparatory Steps. See main text part 3.3, Volume Preparation for details. ..........................................45 2. Main Process ...........................................................................................................................................................45 3. Surface Reconstruction ...........................................................................................................................................48 4. Error Detection and Correction ............................................................................................................................48 C. COMPARISONS TO OTHER METHODS ..........................................................................................................................48

VII. PLANNED FUTURE ENHANCEMENTS .................................................................... 49 VIII. ACKNOWLEDGMENTS ............................................................................................. 49 IX. REFERENCES ................................................................................................................. 50

4

SureFit User’s Guide (Version 4.38)

Table of Figures Figure 1. Surface reconstruction and flat map of human left hemisphere generated using SureFit and flattening using Caret.....................................................................................................................................................................7 Figure 2: The SureFit GUI Screen.. ......................................................................................................................................9 Figure 3: Surface reconstruction for demo volume............................................................................................................14 Figure 4: fMRI visualization in SureFit..............................................................................................................................17 Figure 5: The SureFit Volume Preparation Window ........................................................................................................19 Figure 6: Anterior commissure. .........................................................................................................................................21 Figure 7. Intensity peaks. ....................................................................................................................................................23 Figure 8. The Run SureFit screen ......................................................................................................................................25 Figure 9: Interactive Error Correction Window ................................................................................................................27 Figure 10: Correction of topological handles.. ...................................................................................................................30 Figure 11: A la Carte menu ................................................................................................................................................31 Figure 12. Segmentation of a full hemisphere...................................................................................................................43 Figure 13. An integrated software suite for surface-based analyses. 43 Figure 14: Structural MRI showing a coronal slice through the human frontal cortex. ...................................................44 Figure 15. A schematic model showing a patch of folded cortex......................................................................................44 Figure 16. Processing steps and stages in SureFit..............................................................................................................45 Figure 17. Probabilistic maps of cortical structure.............................................................................................................46 Figure 18: Combining the inner and outer boundaries.......................................................................................................47

5

SureFit User’s Guide (Version 4.38)

Part 1. Introduction and Overview SureFit (Surface Reconstruction by Filtering and Intensity Transformations) is a method for rapidly generating accurate surface reconstructions of the cerebral cortex from structural MRI data (Van Essen, et al., 1999a,b; 2001a; patent pending). It includes a graphical user interface (GUI) that has broad utility for visualization of volume data and associated surface reconstructions. SureFit also allows for visualization of fMRI data in a volumetric format (overlaid on the structural images) and directly painted onto surface representations. Caret (Computerized Anatomical Reconstruction and Editing Toolkit) is a separate software application that includes capabilities for automated flattening plus many additional surface visualization options. This User's Guide and Tutorial comprises three sections. Part 1. Introduction and Overview addresses the following issues:

- Capabilities and advantages of SureFit - Input data requirements (structural and fMRI data) - Hardware requirements and software availability Part 2: SureFit GUI Reference Guide describes the SureFit graphical user interface (GUI). Using demonstration data sets, the main features and capabilities of the GUI can be learned in about 30 minutes. Part 3: SureFit Instructions and Tutorial shows how to run SureFit segmentation on a test data set (identical to that used for generating the demonstration data). Following this tutorial will greatly expedite your learning curve. Appendices I - VI provide information regarding software installation, troubleshooting, and related surface-based software. Appendix VI. SureFit Design Principles summarizes the general design strategy of SureFit and outlines the major processing steps from a conceptual standpoint.

1.1 Why SureFit? Surface reconstructions are increasingly useful for studies of cortical structure and function, particularly for the highly convoluted human cerebral cortex. SureFit uses a novel probabilistic approach to shape analysis, in which multiple lines of evidence about cortical structure are combined to generate a segmentation that runs midway through the thickness of the cortical sheet. Its success in achieving high-quality surface reconstructions that faithfully represent the highly convoluted pattern of cortical convolutions is illustrated in Figure 1. This shows a surface reconstruction of an entire hemisphere in its intact 3-D configuration (Figure 1A) after extensive smoothing (Figure 1B), and after flattening, using Caret software (Figure 1C). Buried (sulcal) cortex has been automatically identified (dark gray) along with specific individual sulci (red). It is particularly important to obtain a surface that is free of topological handles (“donuts”), as this is a prerequisite for satisfactory surface smoothing and flattening. Some topological errors are typically present in the initial cortical segmentation. SureFit includes an automated error correction process for removing these handles, and it has interactive editing capabilities as well.

1.2. Input Data Requirements 1.2.1 Species and Structures Suitable for Reconstruction SureFit has been designed primarily for reconstructing human cerebral cortex from structural MRI data. However, the method is suitable for reconstructing any convoluted, sheet-like structure, including the cerebral and cerebellar cortex in a variety of species (e.g., the macaque monkey) using any imaging modality that provides reasonable contrast between white matter, gray matter, and CSF (e.g., cryosection images). A basic requirement is that the volume be sampled at a uniform (isotropic) spacing that is approximately three-fold finer than the average thickness of the cortical sheet (1 mm voxels for human cortex). The volume of interest can be specified within SureFit and can include an entire hemisphere or any portion thereof. SureFit assumes the anatomical convention (left side of the brain on the left side of the image) rather than the radiological convention for orientation of volumetric images. Volume data can be re-oriented or mirror-flipped within SureFit if necessary. 6

SureFit User’s Guide (Version 4.38) SureFit reads volume data which has been stored using the Minc (Medical Image NetCDF) format (http://www.bic.mni.mcgill.ca/software/minc). A conversion utility is available to convert from “raw” 8-bit or 16bit character images to the Minc format (see Loading Your Own Data, Appendix II). SureFit reads surface files stored in the VTK format (Schroeder et al., 1998; Lutz, 1996). 1.2.2 Functional Neuroimaging Data SureFit includes the capability for visualizing fMRI data on the volume slices. SureFit maps fMRI data onto the surface reconstruction with a method that uses the local surface orientation to constrain how data are projected to the surface.

1.3 Hardware Requirements SureFit runs on SGI (IRIX 6.2 or above), Linux and Solaris platforms. A minimum of 256 MByte RAM is recommended. SureFit is written in Python and C and uses the VTK graphics toolkit (Schroeder et al., 1998; Lutz, 1996). If you encounter problems with installation or running of our software, please contact us at [email protected]. (Note: Trouble with SuSE Linux has been reported. See Release Notes.)

1.4 Software Availability

Figure 1. Surface reconstruction and flat map of human left hemisphere generated using SureFit and flattening using Caret. SureFit is freely available by downloading after an initial registration process (http://brainmap.wustl.edu/SureFit).

1.5 Bug Reporting and Suggestions We have designed SureFit for easy navigation through the full sequence of steps necessary to generate a topologically accurate surface. However, occasional bugs and glitches may arise. If you encounter problems please report the problem to [email protected]. We will attempt to address problems and fix bugs in a reasonable time frame.

7

SureFit User’s Guide (Version 4.38)

Part 2. SureFit GUI Reference Guide 2.1

Organization and Typographic conventions

This section will familiarize the user with the manipulation and visualization of surfaces and volume data in SureFit, independent of the steps necessary to generate a segmentation of a volume. If you wish to proceed directly to the automated segmentation and surface reconstruction process, skip directly to Part 3 [SureFit Instructions and Tutorial]. Several typographic conventions facilitate navigation through Parts 2 and 3: •

Bullets and italics indicate suggested steps to take within SureFit to aid in learning the GUI functions.

General instructions and explanations are in regular font. Instructions involving a specific menu selection or a specific command to type are shown in a distinct font (Arial), such as SureFit. Instructions to select a file or operation multiple levels down a menu are described concisely using a colon to separate each level (e.g. Volume Operations: Read Volume 1:Demo.Occipital.mnc). On completion of this section the user should be able to:

- launch SureFit from an appropriately configured directory, - load and view multiple volumes, - zoom and pan the slice images, - manipulate the cross hairs and sectioning planes of the volumes, - adjust the contrast and brightness of the slice images, - threshold the volume data, - “flood-fill” to segment objects from the volume, - read file headers and parameters files that give information about file types and characteristics, - save volume data, - load and view multiple surfaces (as rendered 3-D surfaces and as contours intersecting with the volume), - “pick” points in one view (slice or surface) and see the corresponding point in other views, - smooth a surface to varying degrees to reduce or eliminate folds, - visualize fMRI data on image slices, and - visualize fMRI data painted onto a reconstructed surface.

2.2

Launching SureFit

Create a directory containing the volume data to be viewed and segmented. If necessary, transform your data into the Minc format (see Loading Your Own Data, Appendix II). Then, move into the newly created directory and type SureFit. • •

For the demo volume, copy the SUREFIT.DEMO directory from the SureFit data directory where SureFit has been installed (nominally, /usr/local/SureFit/data) to a local directory. Move to the newly created SUREFIT.DEMO directory, and type SureFit.

If the SureFit command is not recognized by your system, see your System Administrator or consult Appendix I. Installation Instructions. 2.2.1 Menu Bar When SureFit is launched, a small menu bar appears after a few seconds. Initially, only two of the five available options are enabled.

8

SureFit User’s Guide (Version 4.38) File There are two items in the File pull-down menu. Until a volume is loaded, only the Quit option is enabled. Screen Image Capture Selection of Screen Image Capture saves the current SureFit window as an image file (plot.ppm) in the directory from which SureFit was launched. The *.ppm images can be viewed using imgview software on an SGI, which also allows printing and conversion to TIFF and other image formats.

Figure 2: The SureFit GUI Screen. The left panel shows the screen appearance on first loading Vol. 1. The Screen is divided into four regions. A. The menu bar. B. Volume selection tabs. C. The slice-viewing window. D. The slice selection controls. The middle panel shows the appearance after loading Vol. 2, resizing and repositioning the volume, and switching to a coronal view. Vol1 + 2 shows the superposition of two volumes with the segmentation (Vol2) shown as a red overlay over the original intensity volume (Vol1). The right panel shows the contents of the various pull-down/tear-off menus.

Quit Exits SureFit without saving any previously unsaved files.

2.3

Navigating Through Volume Data

The first step in working with volume data is to load the volume(s) of interest into memory. SureFit uses a file naming convention for many of the volume files it generates: ....mnc. For example, the SUREFIT.DEMO/ directory contains the following structural MRI (sMRI) volumes, all from the same subject, but of different dimensions: Demo.LR.full.sMRI.mnc [the entire brain, both hemispheres] Demo.L.full.sMRI.mnc [the entire left hemisphere] Demo.L.occipital.sMRI.mnc [the left occipital lobe] Demo.L.occipital.sMRI_pad.mnc (a "padded" version of the left occipital lobe, used to facilitate surface flattening) 2.3.1

Loading Volume Data

The Volume Operations pull-down menu includes eight options (Figure 2, right). Until a volume is loaded, only the first option (Read Volume 1) is enabled. Read Volume 1 Selection of this option opens a file selection window. Once an appropriate Minc file (*.mnc) has been selected, the volume will be loaded and the main SureFit window will appear as shown in Figure 2. •

Load the occipital lobe structural MRI volume into Vol1 by selecting Volume Operations: Read Volume 1 Demo.L.occipital.sMRI_pad.mnc) Your screen should look like Figure 2 (left panel). 9

SureFit User’s Guide (Version 4.38) When SureFit reads a volume named .mnc into Vol1, looks for a "params" file named .params and loads these parameter settings. Otherwise, SureFit initializes parameters to default values, which can be changed using procedures described in 3.3 Volume preparation. Read Volume 2 This option permits the user to read in a second volume (whose dimensions must be the same as Vol1). If the selected volume has identical dimensions as Vol 1, it will be loaded as Vol 2. If the dimensions are mismatched, no volume is loaded and an error message appears in the terminal window. •

Load the occipital lobe segmented volume intoVol2 by selecting Volume Operations: Read Volume 2:SEGMENTATION/ Demo.L.occipital.segment_pad_corr2.mnc

Once a volume is loaded into Vol2, you cannot load a volume of different dimensions into Vol1 without exiting and restarting SureFit. (You can, however, reload a volume of different dimensions into Vol1 if no volume is loaded in Vol2.) Read Parameters File Once a volume is loaded, selection of this option brings up a listing of information about the currently loaded Volume1. This includes general information about the subject (self-explanatory name, species, etc.); information about the particular volume (hemisphere, region, dimensions, etc.), and various other parameters set during the Volume Preparation and Parameter setting stage. A complete listing of these parameters is provided in Appendix IV. Parameter file. Read Volume Headers Selection of this option brings up specific characteristics of the particular volumes loaded as Volume 1 and Volume 2. This includes the file name, dimensions, file creation date, SureFit version with which the file was generated, and the parameters file for the associated structural volume. • •

Select Read Parameters File and survey its contents Select Read Volume 1 Header and survey its contents

The remaining six options in the Volume Operations pull-down menu are described in Miscellaneous Volume Operations following the description of how to navigate through the volume. 2.3.2

Screen Layout

Once a volume loaded, the screen should appear as in Figure 2A, which is broken into four regions: A. B. C. D.

Menu Bar: includes File, Volume Operations, Surface Operations, SureFit, and fMRI data operations. Volume Selection Tabs: for toggling between volumes (and drawing a surface contour) Slice Window: main window for viewing slices through volume data Slice Selection Controls: for selecting slice planes, scrolling through volume, adjusting cross-hairs.

2.3.3 Volume Selection Tabs The volume selection tabs (Figure 2B) allow toggling between the different volumes and volume combinations. Vol1 Pressing the Vol1 tab displays a slice through Volume 1 on the screen, in a slice plane determined by the buttons and slider bars below the slice window. If only one volume is loaded, this is the only tab that appears. Vol2 Pressing the Vol2 tab displays the corresponding slice through Volume 2.

10

SureFit User’s Guide (Version 4.38) Vol1+2 Pressing the Vol1+2 tab displays a superposition (addition) of Vol1 and Vol2. If Volume 2 is a segmented (binary) volume, it will appear as transparent reddish overlay over Vol1. If both Vol1 and Vol2 are binary volumes, voxels will appear red where Vol1 and Vol2 are positive, white where only one is positive, and black where both are zero. The file names of the volume(s) currently being viewed are shown in the upper left corner of the slice window. 2.3.4

Navigating Through the Volume

SureFit contains several tools to facilitate rapid navigation through the volume while maintaining awareness of the slice orientation relative to standard anatomical axes. Positioning Within the Slice Window With the cursor positioned in the slice window, the options listed in Table 1 can be used. The default slice position is in the lower left of the slice window. It is generally advisable to reposition the volume to near the center of the window. Slice Selection Controls The slice selection controls at the bottom of the screen include three slice plane buttons on the left (Parasagittal (YZ), Coronal (XZ), and Horizontal (XY)) and associated slider bars on the right. Pressing a slice plane button switches the slice viewer to that plane. The button color changes from gray to white, making it easy to identify the current slice plane. The default slice plane on launching SureFit is horizontal. •

Select a coronal view, scroll to coronal slice 45 and select Vo1 1 & 2. Your screen should look like Figure 2, right panel.

Table 1: Slice visualization options. Mouse Function Description Left Position cross- hairs Moving the mouse while depressing the left-mouse button positions the cross-hairs at the current cursor position. Middle Zoom Moving the mouse in the vertical direction while depressing the middle mouse button changes the scale (zooms) of the image. Right Pan Moving the cursor while depressing the right mouse button pans the current slice image. The slider bars are controlled using the left mouse button with the mouse cursor over the slider bar. Adjusting the slider bar for the currently selected slice plane scrolls the image volume through different slices. The speed of scrolling depends greatly on the image size (how much the image is zoomed) on the screen. Adjusting the slider bars for non-selected slice planes moves the cross-hairs in the slice viewer: § § §

Red cross-hair: parasagittal “x” coordinate, Green cross-hair: coronal “y” coordinate, Blue cross-hair: horizontal “z” coordinate.

When the cursor is within the slider bars: § Left-mouse button controls slider bar position. § Left-right keyboard arrows allow fine adjustment of the slider bar. When the cursor is in the slice window: § Left-right keyboard arrows moves the vertical cross-hair left and right. § Up-down keyboard arrows moves the horizontal cross-hair up and down. Screen Coordinates The (x,y,z) coordinates shown in yellow at the bottom left of the slice viewer indicate the parasagittal (x), coronal (y), and horizontal (z) slice plane levels) of the cross-hairs relative to the (0, 0, 0) coordinates of the image volume. The AC (x, y, z) shown in purple indicates the coordinates relative to the AC reference landmark, which is set during 3.3 Volume preparation. If AC has already been set at the actual anterior commissure, and if the volume is oriented in AC-PC space but otherwise unchanged in dimensions, then AC (x,y,z) indicates the "native AC-PC coordinates" of 11

SureFit User’s Guide (Version 4.38) the subject hemisphere (Drury et al., 1998). If the volume has been transformed to Talairach space (and the AC has been previously identified), then AC (x,y,z) indicates the Talairach coordinates. Anatomical Axis Labels The blue letters at the top, bottom, left, and right of the slice screen indicate the anatomical axes currently being viewed, assuming that the volume orientation conforms to SureFit conventions (see 3.3.2 Volume Orientation).

- When viewing parasagittal slices: - D - V (dorso-ventral) is vertical - A - P (antero-posterior) is horizontal. - When viewing coronal slices: - D - V (dorso-ventral) is vertical - L - R (left-right) is horizontal - When viewing horizontal slices: - A - P axis is vertical on the screen - L - R axis is horizontal. 2.3.5

Miscellaneous Volume Operations

The Volume Operations menu bar contains various options for modifying the currently loaded volume and saving some types of modified volumes. Contrast/Brightness Selecting Contrast/Brightness brings up two slider bars used to adjust the contrast and brightness of the current volume. These adjustments affect the screen appearance but not the underlying voxel intensity values used for thresholding and other processing steps, nor can these changes be saved. The default levels are 255 for contrast and 128 for brightness. Any changes in the contrast/brightness adjustments will affect the appearance of all three volumes (Vol1, Vol2, and Vol1+2). For many workstations, these settings will not be optimal. After spending a few minutes determining the optimal settings for their display, users can override these defaults by either of the following methods: - To change the defaults for all users, edit $SFHOME/lib/python1.5/site-packages/SureFitEnv.py. - To change the defaults only for a given user, set the CONTRAST and BRIGHTNESS variables in that user's environment files, e.g.: csh users, append these lines to ~/.cshrc: setenv CONTRAST 128 setenv BRIGHTNESS 200 bash users, append these lines to $HOME/.bash_profile: CONTRAST=128 BRIGHTNESS=200 export CONTRAST BRIGHTNESS Threshold Selecting Threshold brings up a window that includes two slider bars. The Upper Threshold slider bar sets a “threshold from above” that colors all voxels between the current threshold value and 256 a transparent green. The Lower Threshold slider bar sets a “threshold from below” that colors all voxels between the zero and the current threshold value an opaque blue. These are applied to whichever volume (Vol1, Vol2, or Vol1+2) is currently being viewed. Reset Volume This resets the slice window to its starting size and position. (Alternatively, depress “r” on the keyboard while the mouse cursor is in the slice window.) 12

SureFit User’s Guide (Version 4.38) Flood Fill Selecting Flood Fill uses the current cross-hair location as a seed voxel and applies a flood-filling operation to identify all contiguous voxels in Vol1 that are above the threshold level (i.e., appear green in the volume). The thresholding operation must be applied even if the currently viewed volume happens to be a binary segmentation. The flood-filling generates a volume, Test Flood Fill, that is automatically loaded as Vol2. Save Volume 1 Saves the volume currently viewed in Vol1 as a Minc file (the “.mnc” extension is appended to the file name currently loaded as Vol1). Thresholding or contrast/brightness changes are not saved by this step. Save Volume 2 Similar to Save Volume 1, this saves the volume currently viewed in Vol2 as a Minc file. This operation can be used for example, to save the outcome of a flood-filling operation applied to Vol1.

2.4

Surface Operations

SureFit permits the simultaneous viewing of up to three surfaces, each rendered in a different surface window. In addition, there are options for rotating, panning, and zooming of surfaces, and for comparing locations on surfaces with the corresponding locations in the volume. SureFit includes conventions for naming surfaces. In general, each surface is named .vtk. The node number refers to the number of nodes in the surface reconstruction; it provides a concise and convenient way to tag different surface configurations (shapes) originating from a common source (i.e., a "raw" surface generated from a particular segmentation). 2.4.1

Loading Surfaces

Read Surface 1 This brings up a menu of surface files (in the VTK format) in the current directory. Selection of a surface file will load the surface and display it in a separate window. In addition, a contour intersecting with the currently viewed volume slice appears in red, and the same contour appears in green in the surface rendering. •

Select Surface Operations: Read Surface 1: SURFACES/Demo.L.occipital. segment_corr2.fiducial.43306.vtk to load a 3-D rendering in the Surface 1 window that should look like Figure 3A, except that it is not yet colored (See Section 2.4.5).

SureFit does not attempt to assess compatibility between the loaded surface and the volume from which it originated. Hence, it is possible (although generally not advisable) to view a surface from one hemisphere (or portion thereof) concurrently with volume data from a different hemisphere. Read Surface 2 This allows selection of a second surface file, appearing in the Surface 2 window and as a green contour in the slice window and in the surface rendering. •

Select Surface Operations: Read Surface 2: SURFACES/Demo.L.occipital.segment_corr2.inflated.43306.vtk to load an extensively smoothed (inflated") configuration of the same surface in Surface 2 (as in Figure 3B). The contour for the inflated surface will not be in register with the volume, as the surface is translated (so its center is at the origin) during inflation.

13

SureFit User’s Guide (Version 4.38)

Figure 3: Surface reconstruction for demo volume. A. Fiducial surface. B. Inflated surface. Red dot marks location [50, 60, 93] in the volume, as selected using the "p" command in the slice viewer.

Read Surface 3 This allows selection of a third surface file (memory permitting) appearing in the Surface 3 window and as a blue contour in the slice window and green in the surface rendering. 2.4.2

Viewing surfaces

Surfaces can be rotated, panned, and zoomed under mouse control when the mouse cursor is in the surface window as described in Table 2.

Table 2: Surface Visualization Options Mouse/Key Action Left Mouse

Rotation

Middle Mouse Right Mouse

Zooming Panning; To enhance rendering performance, large surface renderings will automatically switch to a lower-resolution display format when the surface is being panned, rotated, or zoomed. To force a particular representation, the user can utilize the “c”, “w”, or “s” keyboard keys as shown below. change surface to cloud of points change surface a wire-frame mesh change surface to a solid pick a point on the surface (displays a red sphere).

c key w key s Key p Key 2.4.3

Generate Surfaces

A segmented volume contains the shape information needed to identify the cortical surface, but the segmentation is not itself an explicit surface. Surface reconstruction entails generation of a tessellation (wireframe mesh) that represents the geometry (configuration and topology) of the boundary between segmented and non-segmented voxels.

- Make sure that a desired segmented volume is loaded as Vol2. Often it is useful to have the corresponding intensity volume loaded as Vol1, but the choice of volume for Vol1 is not critical (as long as it has the appropriate dimensions). - Select: Generate Surface. This option generates up to three surfaces for whatever segmentation is currently loaded into Vol2. Selection of "raw only" generates a surface (.raw.node_number.vtk) that runs precisely along the boundaries of the segmentation. The raw surface is displayed as Surface 1.

14

SureFit User’s Guide (Version 4.38) Selection of "raw & fiducial" generates an additional surface (.fiducial.node_number.vtk) in which a small amount of smoothing reduces the "blockiness" of the voxels and better approximate the fiducial shape of the cortex. The default degree of fiducial smoothing involves 10 iterations with a smoothing factor of 0.2, but this can be adjusted. The fiducial surface is displayed as Surface 1. Selection of "raw, fiducial, & inflated" generates a third surface (.inflated.node_number.vtk) that is smoothed more extensively to “inflate” the surface and allow visualization of buried regions and easier detection of topological errors ("handles"). The default degree of additional smoothing involves 50 iterations with a smoothing factor of 1.0, but this can be adjusted. The fiducial surface is displayed as Surface 1; the inflated surface is displayed as Surface 2. •

For the test volume, make sure SEGMENTATION/Demo.L.occipital.segment_pad_corr2.mnc is loaded in Vol. 2.



Select SureFit: Surface Generation, click on Generate Surface. Select "raw, fiducial, & inflated". Once the fiducial surface appears (in a separate window), view it from different angles using the left mouse button. [Recall that the left-mouse button is used for rotation, the middle-mouse button for zooming, and the right-mouse button for panning in the 3-D surface window].



Click on Done in the surface generation window to close this window.

2.4.4

Smooth Surface

SureFit has an option for smoothing any existing surface reconstruction that has been loaded as Surface 1. Selection of this option brings up a window that includes slider bars for the number of smoothing iterations and the strength of smoothing applied at each iteration. Number of Iterations Typically, 50 – 100 iterations at a relaxation factor of 1.0 will smooth out most of the convolutions from human cerebral cortex. Relaxation Factor The relaxation factor relates to the strength of the smoothing. For inflation of the surface (in order to discern topological problems, for example) use a factor of 1.0. For mild smoothing to remove artifactual “blockiness” due to the finite voxel size a factor of 0.2 is preferable. Smooth Surf This initiates the smoothing process. When it is complete, both the surface window and the slice window display the smoothed surface. Undo This restores the surface configuration prior to the most recent smoothing operation. Write Surface Selecting this option saves the surface as a file labeled smooth.vtk in the directory from which SureFit was loaded. 2.4.5 Paint Surface. This brings up a menu option that lists any files in the current directory ending in "RGB_paint". Selection of one of these files results in painting the currently loaded surface(s) with the coloration pattern contained in the selected paint file. •

2.5

For the demo surface, select SURFACES/Demo.L.occipital.segment_corr2.geography.43306.RGB_paint.

Surface-volume relationships

SureFit includes two options for ascertaining relationships between the volume data, as seen in the slice viewer, and the surface data, as seen in whatever surface windows are open. One is based on identifying points in the volume or on a surface. The other displays surface contours in both the slice viewer and on the surface rendering. 15

SureFit User’s Guide (Version 4.38) 2.5.1

Surface and Volume “Picking”

The “p” key can be used to identify corresponding points in the slice volume and in whatever surfaces are displayed. This option can be used in either direction – to pick a point in the volume and highlight the corresponding location in the surface viewer(s) or to pick a point in a surface viewer and identify the corresponding location in the volume data. Keyboard “p” (cursor in slice window): Depressing the “p” key in the slice window generates a red sphere at the corresponding locations in any currently viewed surface windows. Depending upon the position of the cross-hairs in the slice window, the red sphere may appear inside the surface(s) and therefore it will not be visible. Keyboard “p” (cursor in surface window): Depressing the “p” key in any of the surface windows near a surface node will highlight the closest surface point on the surface with a red sphere and the corresponding node (as distinct from an (x,y,z) position) in other surfaces will be indicated by red spheres. In addition, the slice window will automatically be adjusted to the location of the marker in Surface 1 (even if the point was “picked” in Surface 2). The slice viewer will also show the contours for surface 1 (in red) and surface 2 (in green), and surface 3 (in blue). If a fiducial surface and a inflated surface are being concurrently viewed, it is generally advisable to load the fiducial surface as Surface 1 and the inflated surface as Surface 2. This insures that locations in the slice viewer are accurately mapped to the fiducial surface and from these to corresponding locations on the inflated surface. 2.5.2

Drawing Surface Slices

DrawSurf This tab appears in the Viewing Tab (Figure 2B) options only after a surface has been loaded. Selecting this tab redraws in the slice window slices through whatever surface(s) are currently loaded, as these automatically disappear each time the slice level is changed (to expedite scrolling through slices).

2.6

SureFit Operations

The SureFit operations listed in the menu bar incorporate all of the steps needed to generate a segmentation and surface reconstruction from whatever intensity volume is currently loaded in Vol1. The specific steps are described in Part 3. SureFit Instructions and Tutorial.

2.7

Visualizing fMRI Data

SureFit provides multiple options for visualizing fMRI data in relation to structural volume data, as illustrated in Figure 4A and in relation to surface reconstructions, as illustrated in Figure 4B, C. Note, however, that many aspects of visualizing fMRI data on surfaces are better handled using Caret software, which includes many options for visualizing functional data (thresholding, pos/neg/both toggling, user-specifiable palette, min/max, underlay, toggling between various data sets, etc.) (see http://stp.wustl.edu/caret/pdf/caret_user_guide_part1.pdf). Also, the process of mapping fMRI data to surfaces can be carried out using SureFit's Map2Surface command line utility. This offers a number of improvements to SureFit's menu-driven functional mapping (e.g., no need to split pos/neg, multiple data types supported, byteswapping, flipping, multiple mapmethods). For full usage, enter "Map2Surface" at the command line.

16

SureFit User’s Guide (Version 4.38)

Figure 4: fMRI visualization in SureFit. A. The slice window showing a coronal slice (slice 40) from the test MP-RAGE volume with an associated functional MRI data set overlaid. B, C. fMRI data painted onto surface representations of the fiducial surface (B) and inflated surface (C). fMRI data from Corbetta et al. (1998).

2.7.1 Split fMRI Volume This operation converts fMRI activation data initially in a 16 bit (signed integer) .img file (Analyze format) to a SureFit-compatible format. It assumes that the fMRI volume dimensions are identical to the structural image volume prior to any cropping steps that have been applied. When dealing with other data formats or volume dimensions, see Section 3.5 Formatting and Visualizing fMRI Data. 2.7.2 Read fMRI Volume as Vol2 This operation brings up a window for selecting an fMRI activation volume (in 8-bit minc format) for viewing as Vol2, using a color look-up table to represent the activation pattern. •

To visualize an exemplar fMRI data set, choose fMRIData: Read fMRI Volume as Vol2 and choose Demo.L.occipital.EyeMovement_fMRI_pad.POS.mnc.

2.7.3 Toggle fMRI Color Map This toggles the coloring format between regular gray-scale and a fMRI activation color scale (red is associated with maximal activation). 2.7.4 Adjust fMRI Mapping Parameters This step allows adjustment of the geometric parameters used in mapping fMRI volume data onto a surface. See Painting fMRI Data onto Surface for details. 2.7.5 Map fMRI Data to Surface This operation carries out the mapping of fMRI activation data onto a surface. See Painting fMRI Data onto Surface for details. 2.7.6 View Painted fMRI Data. This selects an fMRI “paint” file for mapping to whatever surfaces are currently loaded in the surface viewer. •

View fMRI data on the currently visualized surfaces by choosing fMRIData: View Painted fMRI Data and selecting SURFACES/Demo.L.occipital.EyeMovement_fMRI.POS.43306.RGB_paint.

17

SureFit User’s Guide (Version 4.38)

Part 3. SureFit Instructions and Tutorial 3.1 Conventions This section provides general instructions for reconstructing the surface of any volume of interest. In addition, the bulleted and italicized sections provide specific comments and values pertaining to the reconstruction of the same volume data used for the demonstration data set. As in the SureFit GUI Reference Guide, un-bulleted regular font provides general descriptions and explanations. •

Solid bullets and italics indicate specific steps to be carried out with the test data set;

In addition,

- Dashed line bullets indicate steps to be carried out using an arbitrary data set of interest. File naming conventions. Volume files created or saved within SureFit generally use the naming conventions indicated in Table 3. For example, Demo.L.occipital.sMRI.mnc refers to the demonstration volume, left hemisphere, occipital lobe, structural MRI volume. Additional information about the nature of each file is included in the file header and in the "parameters file" associated with each family of volumes generated from a common source. Surface files follow a smaller convention, except that the number of nodes in the wireframe mesh is also included. Table 3. Naming conventions. Generic

Exemplars

Volumes

....mnc

Surfaces

.....vtk

Test.L.full.sMRI.mnc Test.L.occipital.segment.mnc Test.L.full.fiducial.27200.vtk Test.L.occipital.inflated.27200.vtk

3.2 Launching SureFit For a new image volume, create a suitably named directory.

-

Copy or move the volume data to be analyzed into the newly created directory.

-

If necessary, convert the volume data to the Minc format (using, for example, the supplied Raw2Minc utility, which requires inputting the volume dimensions - see Appendix -Error! Reference source not found.).

-

Move to the newly created directory and type SureFit.

-

Read in the volume data by selecting Volume:Read Volume 1 from the menu bar and selecting the desired .mnc file.



For the test data set, copy the “test” volume data from the SureFit data directory (nominally, /usr/local/SureFit/data/SUREFIT.TEST). Upon completion of this tutorial, files in your copy of SUREFIT.TEST should match files in SUREFIT.DEMO, except that "Demo" will be replaced with "Test" in the filename.



Ensure that the directory includes the following two files: Test.LR.full.sMRI.mnc [the full brain volume] Test.LR.full.fMRI.img Change to the SUREFIT.TEST directory and type SureFit. Select Volume Operations:Read Volume 1: Test.LR.full.sMRI.mnc and then press Open.

• •

18

SureFit User’s Guide (Version 4.38)

3.3 Volume preparation SureFit includes a series of preparatory steps prior to starting the segmentation process. They should take only a few minutes to complete.

Figure 5: The SureFit Volume Preparation Window •

Select SureFit: Volume Preparation.

3.3.1 Volume Information. General information about each data set is acquired at the outset and stored in a parameters file specific to each family of volumes (i.e., volumes of identical dimensions, derived from the same subject). When a volume is reoriented or cropped, a new parameters file is created, with relevant information automatically incorporated, so that the main entry process occurs only once.

-

Subject. A unique identifier for each individual brain. Do not include the hemisphere in the subject name. Investigator. This can be the individual responsible for the study or for doing the segmentation. Group. Neuroimaging group or laboratory. Data type. (i.e., structural MRI or cryosection images). Resolution. Currently SureFit segmentation process is adopted for 1.0 mm resolution data for human cortex, or ~0.3 mm resolution for macaque cortex. Species. Check human or macaque, or other (if other, enter the species name in the entry box that appears). Comment. Brief comments can be entered in the dialog box directly.

19

SureFit User’s Guide (Version 4.38)

-

Additional reference file. More extended comments or ancillary data (e.g., MRI data acquisition parameters) can be included in a separate file.

Volume extent. Structural MRI volumes typically are acquired over the whole brain, but prior to SureFit segmentation the volume is cropped to cover the region of interest (a hemisphere, or portion thereof). SureFit preserves information about the position of each cropped volume within the original (whole) image volume. This can be particularly useful when aligning structural and functional MRI data from the same subject.

-

Indicate whether the currently loaded volume has already been cropped, or whether it includes the whole image volume (i.e., the largest volume available) or just a portion (i.e., an already cropped volume).

-

Indicate whether the currently loaded volume includes the left hemisphere, right hemisphere, or both (L, R, or LR in the resultant file name).

-

Indicate the geographic region (all of the cerebral hemisphere; one or more lobes; the cerebellum; or other).

-

Indicate whether to assign the volume (and the associated parameters file) a new name according to SureFit conventions (see Table 3).



For the test volume, enter "Test" for subject, and enter your own information for investigator, group and comments. Leave the data type, resolution, and species in their default values.



For volume extent, the current volume includes the entire brain, so select 'no' for Volume Already Cropped.



Select "both=LR" for Hemisphere.



Select "entire cerebral hemisphere" for Region.



Select "Change" for Filename, and accept the default Test.L.full.sMRI.

3.3.2 Volume Orientation If necessary, the volume should be re-oriented to correspond to SureFit conventions. SureFit follows the anatomical viewing convention (left hemisphere displayed on the left side of the slice window) rather than the radiological convention (right side displayed on the left). [Note: For AFNI users, SureFit's conventions are LPI -- not RA1, as in AFNI.]

-

Select the SureFit:Volume Orientation tab. This automatically switches the display to the Y-Z (parasagittal) slice plane. Move the top (parasagittal) slider bar and scroll to a slice plane where it is easy to ascertain how the actual anatomical axes of the brain are oriented.

-

Determine whether posterior (P) is to the left and ventral (V) is towards the bottom in the parasagittal slice, then switch to a coronal or horizontal slice and determine (if possible) whether the left hemisphere (L) is to the left.

-

If the volume is already oriented according to SureFit conventions, depress the "Yes" button, then skip to the Set Anterior Commissure tab.

-

If the volume is incorrectly oriented, depress the "No" button, then select the button(s) that describe the current screen axes, press Permute, and ascertain whether the newly rotated axes are now correct. For example, suppose the medial-lateral axis actually runs horizontally on the screen and the antero-posterior axis runs vertically. If so, first select the Horizontal: Medial-Lateral button, then select the Vertical: Anterior-Posterior button, then press Permute. Note that the dorso-ventral button for the horizontal screen axis is initially disabled. If the actual dorso-ventral axis runs horizontally, first select the correct vertical axis, as this will then enable the dorsal-ventral option for the horizontal axis.

20

SureFit User’s Guide (Version 4.38)

-

Once the axes are the correct orientation on the screen, ascertain whether they are pointed in the appropriate direction (polarity). If dorsal is down instead of up (while still viewing the parasagittal slice plane), then press the FlipY button; if anterior is to the left (towards the P on the screen) instead of to the right (towards the A), then press the FlipX button; if the right side is to the left (in a coronal or horizontal plane) press the FlipX button. Note that the original orientation can be restored by pressing the same button a second time.



For the test volume, note that the axes are pointed correctly. Nonetheless, to see how this works, click "no" and press FlipX and note the reversal along the horizontal axis. Press FlipY and note the reversal along the vertical axis. Repeat both steps and note that the image is restored to its original orientation.

-

Once the volume is in the correct orientation and polarity in all slice planes, press Save. This will create a volume in which Orient.mnc is appended to the initial volume name and use this as Vol1 for subsequent processing steps.



For the test volume, the axes are correct and the volume is oriented correctly. Click "yes" and proceed to the next tab.

3.3.3 Setting the Anterior Commissure The anterior commissure is a standard stereotaxic landmark used in a number of SureFit processing steps. If the volume before cropping includes the anterior commissure, center the cursor on the anterior commissure and press the Set Anterior Commissure button. More specifically,

-

-

Select the Set Anterior Commissure tab. The view will switch automatically to coronal view; scroll to an anterior-posterior level that includes the corpus callosum; move the parasagittal cursor to the midline; switch to a parasagittal midline view; center the cursor on the anterior commissure (see Figure 6 and the image in the instruction window); return to a coronal view and adjust the parasagittal cursor if necessary to intersect the midline precisely at this coronal level; press the Set Anterior Commissure button.

• • • • •

For the test volume, select a coronal view where the midline can be seen. Move the parasagittal cursor to slice 94 (the midline). Switch to a parasagittal view. Move the cursor to the anterior commissure (94, 132, 63). Press the Set Anterior Commissure button.

-

Figure 6: Anterior commissure. Midline (saggital) view of entire hemisphere. Crosshairs are centered on the anterior commissure (AC).

21

SureFit User’s Guide (Version 4.38) If the volume does not include the anterior commissure and its location has not previously been set, place the cursor as close as possible to where the anterior commissure would be if the full hemisphere were included:

-

coronal (red) cursor at the midline; horizontal (blue) cursor line below the corpus callosum (if it is present) and above the hindbrain/cerebellum (if they are present); vertical (green) cursor line at the far right (anterior) limit for a posterior (occipital) volume and at the far left (posterior) limit for an anterior (frontal) volume.

3.3.4 Defining the Volume of Interest The following steps permit the user to identify the “Volume of Interest” (VOI), which can be a full hemisphere or portion thereof. Important Note: The SureFit segmentation algorithm currently works only on hemispheres and portions thereof; it does not segment entire brains. You must crop to left and right hemispheres before proceeding to segmentation. Otherwise, you may get errors such as "out of swap space" and/or unsatisfactory segmentations.

-

Select Define VOI within the Volume Preparation window.

-

Select the Horizontal slice plane and scroll to the slice level where the hemisphere of interest is widest and longest. Adjust the X (minimum and maximum) slider bars to choose the medio-lateral extent of the volume to be analyzed and the Y (minimum and maximum) slider bars to choose the anteroposterior extent.

-

Depress the Crop button to apply the newly defined extent to the X- and Y-axes.

-

Scroll through the volume to assure that the entire region of interest is visualized. Pay particular attention to anterior and posterior regions along the midline, as natural asymmetries or slight misalignment of the head can easily lead to undesired cropping. If you inadvertently crop a portion of the volume that you want to preserve, simply readjust the slider bar and select Crop again to restore the larger sub-volume. Cropping several mm beyond the midline (i.e., into the opposite hemisphere) is a good idea, to prevent clipping bits of the VOI. Any excess beyond the midline will be cut off during segmentation, as long as it is minimal compared to the VOI.

-

Switch to the parasagittal plane and scroll to a slice where the partially cropped image volume is maximal in extent.

-

Adjust the Z slider bars to the desired limits.

-

Once the VOI is satisfactory in all three axes, press the Save button.

-

In the popup window, indicate the hemisphere (left, right, or both) and the geographic region included in the cropped volume (all of the cerebral hemisphere; one or more lobes; the cerebellum; or other).

-

If one or more faces (medial, lateral, posterior, anterior, dorsal, or ventral) of the cerebral cortex has been cut, press the appropriate toggle button in the Identify Cut Faces section of the bottom of the window. This information is used to reduce distortions in subsequent flattening operations (by adding a "padded" region to the segmentation, thereby compensating for irregular "fingers" at the cut margins of the segmented volume). Normally, when cropping full hemispheres or portions thereof, it isn't necessary to specify a medial cut face (right +x for left hemisphere, left -x for right hemisphere). Only specify a medial cut face when you actually are cropping lateral to the natural medial wall within the hemisphere of interest. If you want the cortex up to the medial wall, it's best to crop just a bit beyond the midline. SureFit will figure out where the actual hemisphere ends and throw away the residual bits of the other hemisphere.



To generate a left hemisphere occipital lobe for the test volume, scroll to slice 73 in the Horizontal plane, adjust the lower and upper X slider bars to 24 and 99, respectively, and adjust the Y sliders to 24 and 100. (This VOI should correspond to the previously cropped occipital lobe used in the demo volume.) 22

SureFit User’s Guide (Version 4.38)

3.3.5



Depress the Crop button.



Switch to the parasagittal plane and scroll to slice 94.



Change the Z levels to 45 and 148 and depress the Crop button again.



Select Save and select left hemisphere, occipital lobe, and OK to store the volume as Test.L.occipital.sMRI. mnc, then click on Save.



Check the Anterior box under the Identify Cut Faces section to indicate that this face has been cut.

Set Intensity peaks •

Select the Set Peaks tab.

This brings up a separate window showing a histogram of intensity values for the currently viewed volume.

Figure 7. Intensity peaks. Set Gray Matter peak This parameter identifies the peak in the volume histogram associated with cortical gray matter.



In the histogram window, depress the left mouse button, then move the vertical bar to the gray matter peak of the histogram. (The keyboard arrows allow fine-tuning of the vertical cursor while the mouse cursor is in the histogram window.) If the histogram does not have a clear gray-matter peak, select a value that results in roughly half of the gray matter voxels being above threshold (i.e., appearing green).



Click on Set Gray Matter Peak. • • •

For the test volume, Select the Set Peaks tab.

For the test volume, move the histogram cursor to 80. Click on the Set Gray Matter button to set the parameter.

Set White Matter peak This parameter is set at the peak in the intensity histogram associated with subcortical white matter. •

In the histogram window, depress the left mouse button, then move the vertical (red) cursor line from its center position to the right-most (white matter) peak of the histogram. If the histogram lacks a clear white-matter peak, select a value that results in roughly half of the white matter voxels being above threshold (i.e., appearing green in the slice window 23

SureFit User’s Guide (Version 4.38) •

Click on Set White Matter peak. The button changes color, from red to black, once this parameter has been set.

• •

Adjust the histogram cursor so that it reads 104. Click on Set White Matter Peak.

Click on Done in the histogram window to close it. List Parameters. Selecting the List Parameters tab brings up a list of adjustable parameters that are set either during the parameter setting process or have default values. Type in the desired number to change any of these parameters. Parameter Adjustments. In some cases, optimal segmentation entails using values for the White Matter Peak and/or Gray Matter Peak that are offset from the actual histogram peaks. For example, if one or both intensity peaks are strongly skewed, then the value should be set somewhat to the shallower side of that peak. See Troubleshooting: Adjusting Parameter Values for additional details. 3.3.6 Resampling (NOT recommended for normal segmentation). Using the Resample option will reduce the voxel site by a factor of two along each axis. The initial volume will be renamed and saved as .resamp.mnc and reloaded as Vol1 for subsequent processing steps. For human volume data already at 1 mm cubic voxels, do not use the resampling option. To resample the volume at intervals different from a factor of two, see Appendix Error! Reference source not found.. 3.3.7 Save Parameters Press the Save and Close button at the bottom of the screen. This saves the new parameters in ...params and moves the previous parameter file to ...params.old. If you do not wish to save the changes made, press Close without Saving. • •

For the test volume, press Save and Close. Select Volume Operations: Read Parameters File, and make sure the values match those listed in Appendix IV. Parameter file.

3.4 Automated Segmentation, Error Correction, and Surface Generation - Select SureFit: Run SureFit - Make sure the structural MRI volume to be segmented is loaded as Vol1. A notebook window appears with three tabs: Run SureFit; Interactive Error Correction; and A La Carte, as illustrated in Figure 8.

24

SureFit User’s Guide (Version 4.38)

Figure 8. The Run SureFit screen 3.4.1 Run SureFit The regular SureFit process includes an initial segmentation and surface generation stage, followed by a stage of automated error correction.

-

The default mode is to run the complete SureFit process (by simply pressing the Run SureFit button). Various steps can be skipped by selecting alternate menu options as described below.

Segmentation Scope.

-

Segmentation Scope. (Default = Extract Cerebrum, Segment) This option includes preprocessing steps to remove the skull and hindbrain (cerebellum plus brainstem). For special cases where the extraction of cerebral white matter is either inappropriate (e.g., when segmenting the cerebellum) or is not working properly, select Segment Full Volume. The Use Segmentation loaded in Vol2 option bypasses the initial SureFit segmentation process. It presumes instead that a previously generated segmentation is already loaded into Vol2. (This option can be used after a segmentation has been processed by interactive error correction (section 3.4.2) in order to generate a surface and prepare for flattening.)

-

Fill Ventricles? (Default = No) SureFit includes a process for automatically identifying the ventricles and incorporating them into the segmentation. This reduces irregularities along the medial wall and yields a smoother surface reconstruction. The output volume has a "_vent" appended to the file type (see Table 4). For partial hemisphere, select "no".

Surface generation and error correction

-

Correct Errors (or Skip Error Correction) (Default = Correct Errors) This option applies the SureFit error correction process to the initially generated segmentation. The output is a corrected segmentation with most or all of the topological errors removed (and also with irregular fingers reduced or eliminated). The duration of the error correction process depends upon the initial number of errors, but is typically several times longer than the initial segmentation. In order to apply error correction to a previously segmented volume, load the segmentation into Vol2 and select the “Use segmentation loaded in Vol2” option under Segmentation Scope. 25

SureFit User’s Guide (Version 4.38) If Skip Error Correction is selected, an additional pair of menu options appear:

-

Prepare to Flatten. If this option is selected, the resultant surface will be transformed into an ellipsoidal shape that is needed for automated flattening in Caret.

-

Review Surface First. This option entails less time, as it involves generation of fewer surface configurations, and should be used if the surface is not to be flattened.

-

Identify Sulci (or Skip Sulci Identification) (Default = Identify Sulci) SureFit includes an option that automatically identifies buried regions of cortex as well as selected individual sulci. Their identity is represented by selected volume files as well as paint files for surface reconstructions. The relevant volume files are stored in the SULCAL_IDENTIFICATION subdirectory under self-explanatory names. The surface paint file (...geography..RGB_paint) is stored in the SURFACES subdirectory, and can be viewed using Caret (Attributes: Surface Coloring.ShowGeography).

-

Keep intermediate files? (Default = unchecked) SureFit generates a large number of intermediate files that will be automatically deleted at the end of the process unless this option is selected (e.g., for debugging purposes).

-

Press the Run SureFit button once the desired options have been chosen.

This will generate a cortical segmentation (which is loaded into Vol 2) and associated surfaces; the fiducial surface automatically appears in a separate surface viewer window. The time needed to complete these processes can range from a few minutes to several hours, depending on the size of the volume, the speed of the computer, and whether error correction has been selected. • For the test volume, select SureFit: Run SureFit. Leave the different options in their default modes and press the Run SureFit button. Upon completion (two hours on an SGI Octane) the main viewing screen will show the corrected segmentation (Test.L.occipital.segment_pad_corr.mnc), and the surface viewer will show the fiducial surface. Table 4 indicates the naming conventions for segmented volumes and the associated surfaces, according to whether or not the volume has been padded, whether or not error correction has been done, and whether the ventricle has been filled. For the segmented volume, the filename "segment" is appended by "_pad" if the volume is padded, by "_vent" if the ventricle is included, and by "_corr" if automated error corrections have been applied. Table 4. Filenaming conventions for segmented volumes Segmentation characteristic Append

Exemplar

if padded

"_pad"

Demo.L.occipital.segment_pad.mnc

if ventricle filled

"_vent"

Demo.L.full.segment_vent.mnc

if errors corrected

"_corr"

Demo.L.full.segment_corr.mnc

Surfaces are identified by similar conventions: ...raw..vtk. The number of surface nodes is used to distinguish surfaces of different sizes (e.g., padded or unpadded); the “pad” identifier is not included in the file name. •

For the test volume, data set, the fiducial surfaces shown in the surface viewer is (Test.L.occipital.segment_corr.fiducial.43311.vtk). Your node_number may differ somewhat (e.g., 43227 on Linux Red Hat 7.1). 26

SureFit User’s Guide (Version 4.38) 3.4.2

Interactive Error Correction.

The automated error correction process in SureFit identifies and patches the great majority of errors (topological handles, fingers, and invaginations), but typically there are a few residual errors. Often, the residual errors can be safely ignored because the handles are very small or lie near the midline, outside of neocortex proper. SureFit provides convenient methods for counting the number of residual errors, determining their location, and when appropriate, correcting them by interactive editing. •

For the test volume, select the SureFit: Interactive Error Correction tab

The window will appear as in Figure 9. Counting errors.

-

Press the Update Handle Count button to determine the number of topological errors (handles) in whatever segmented volume is loaded in Vol2. Occasionally, this method can yield a few false positives (small handles in the volume that do not appear in the surface). •

Select the Update Handle Count button. This will compute the Euler number for the volume (but will not localize errors) and report it. In this case, SureFit reports one handle (topological error) for the corrected segmentation.

Figure 9: Interactive Error Correction Window

27

SureFit User’s Guide (Version 4.38) Localizing errors Residual errors in the segmentation can be visualized directly on the surface reconstruction, where they appear as red patches, and in the volume, where they can be viewed in relation to the segmentation.

-

Load the following files Vol1: the intensity volume (...sMRI.mnc or ...sMRI_pad.mnc if padding was required) Vol2: the segmentation to be corrected (...segment_corr.mnc or ...segment_pad_corr.mnc if padding was required) Surface1: the fiducial surface (...segment_corr.fiducial..vtk) Surface2: the inflated surface (...segment_corr.inflated..vtk) •

Select Surface Operations:Paint Surface, and open SURFACES/...segment_corr.errors..RGB_paint.

-

Press the Locate Objects button. You will be prompted for a Minc file. If the volume loaded in vol2 was run through error correction, then accept the default "*.errors*" file (...segment_corr.errors..mnc) to bring up a list of object locations of the form xmin-xmax, ymin-ymax, zmin-zmax. These are the limits of objects that the error correction algorithm has flagged as trouble spots. (If the volume loaded in vol2 was not run through error correction, then Locate Objects will not be able to pinpoint the trouble spots. Nevertheless, it does provide limits for objects in whatever file you select.)

-

In the slice window, scroll to within the limits specified for each dimension of the first trouble spot.

-

Press the keyboard "p" and rotate the fiducial and inflated surfaces to view the red dot over the red surface patch representing that error.

-

Scroll backwards and forward through the volume within the neighborhood of the trouble spot, toggling between Vol2 and Vol1 & 2, to identify the exact location and nature of the residual error. • • • • • •



For the demo volume, make sure SEGMENTATION/Test.L.occipital.segment_pad_corr.mnc is loaded as vol2. Load SURFACES/Test.L.occipital.segment_corr.fiducial.43311.vtk as Surface 1, and SURFACES/Test.L.occipital.segment_corr.inflated.43311.vtk as Surface 2. Select Surface Operations: Paint Surface, and open SURFACES/Test.L.occipital.segment_corr.errors.43311.RGB_paint. Press the Locate Objects button, and open the default Minc file (ERROR_CORRECTION_INTERMEDIATES/Test.L.occipital.segment_corr.errors.43311.mnc). Scroll to within the limits shown for the single trouble spot (53-57, 68-72, 88-92). Press "p" within the slice window while the cross-hairs are within these limits. Notice in Surface 1, a red sphere appears. Zooming up on the surface, and rotating to the right, you can see a handle highlighted in red. Press "p" in the surface window with the cursor as close to the handle as possible, and notice the red sphere near the handle on the inflated surface (Surface 2). The slice window also updates. (The cross-hairs should still be within the limits reported in the Locate Objects results.) In the slice window, scroll a few slices on either side of this location in each plane to try to find the error. Zooming up on parasagittal slice 56, notice a missing voxel at 56,70,90. Clicking "p" again here places the red sphere right in the handle in Surface 1 (Figure 10A).

Note: On non-Irix platforms, the error location may vary. For example, on Linux Red Hat 7.1, it is an extraneous voxel at 61, 16, 17, that must be toggled off. Correcting Handles. 28

SureFit User’s Guide (Version 4.38) Two methods are available for interactively correcting residual errors.

-

Toggle Voxels. Press the Toggle Voxels button to switch the mouse buttons to the voxel editing mode. While in the Toggle Voxels mode, the left mouse button still positions the cursor, but the middle button makes the voxel white, and the right button makes it black. If multiple voxels need editing, the process can be expedited using the arrow keys to position the cursor with one hand, while modifying voxels with the other hand on the mouse. Note that the voxel affected is determined by the position of the crosshairs, not the cursor. Zoom and pan are disabled until you press the "Resume Normal Mouse Mode" button, so be sure to exit the Toggle Voxels mode before resuming other operations.

-

Dilate/erode Masked Region

-

Adjust mask: center the mask used in patching (based on where erosion or dilation of the segmentation needs to occur) and adjust the mask dimensions;

-

Choose dilation/erosion steps: set the number of dilation or erosion steps likely to correct the error.

-

Patch: apply the patching operation to the segmented volume data;

-

Evaluate: ascertain whether the patch was successful (using Handle count or by scrolling through the volume), then proceed to the next error (or re-do the current one).

Also, a flood-filling option is available for removing disconnected regions. If a "finger" has been disconnected by deleting voxels that link it to the main segmentation, press the Flood Fill Volume 2 button. The largest segmented object will remain, and smaller objects will disappear from Vol2. If Update Handle Count reports a negative number, then a group of voxels probably became disconnected from the rest of the segmentation during patching. Either Undo the patch that disconnected the voxels, or Flood Fill Volume 2 to remove the disconnected voxels from the segmentation. Don't forget to save your corrections (see below). Saving Corrections. At the end of the process (or at periodic intervals if numerous patches are required), the patched volume should be saved. Press the Save Edits. In the popup file selection window, the default file name will have ".patch" appended to the current Vol2 file name. Alternatively, you may revise the name (e.g., to "...segment_corr2.mnc") to identify the second corrected volume. If a mistake is made in patching, the Undo button can be used to recover from the most recent step taken. Changes made at earlier steps are recoverable if intermediate volumes have been saved, in which case the partially patched volume can be reloaded. Even after most or all of the handles have been corrected, it still is a good idea to inspect the volume for artifactual invaginations and bulges that could lead to undesirable inaccuracies in the reconstructed surface, even though they may not represent topological errors. For example, SureFit may very rarely fill in a sulcus without introducing any handles. (If this happens, see Appendix III, Troubleshooting.) Once all significant errors have been corrected, save the edited segmentation, and generate a new surface. In the Run SureFit window, select Use Segmentation Loaded in Vol2 and Skip Error Correction. (See note below about Prepare to Flatten vs Review Surface First.) Unlike the Update Handle Count, which operates on unsaved patches, this operates on the most recently saved version of the segmentation. • • • • • • •

For the test volume, move to 56,70,90. Press the Toggle Voxels button. Click once with the middle mouse button to turn the voxel white. Press the Resume Normal Mouse Mode button. Press the Update Handle Count; the handles should reduce to 0. Press the Save Edits button, and save the patched volume as Demo.L.occipital.segment_pad_corr2.mnc. Click on the Run SureFit tab, and select these settings: • Use Segmentation Loaded in Vol2 29

SureFit User’s Guide (Version 4.38)



• No for Fill Ventricles • Skip Error Correction and Prepare to Flatten • Identify Sulci Press the Run SureFit button, and a final surface will be generated (within 30 minutes on an SGI Octane). Note that the handle has been removed (Figure 10C).

Note: Remember that Prepare to Flatten takes much longer than Review Surface First, so use this option only when you are reasonably sure your segmentation is final (i.e., all significant errors have been removed/patched). For the demo volume, Prepare to Flatten takes 30 minutes on an SGI Octane, while Review Surface First takes only about five minutes. (Recall that Prepare to Flatten gets the surface ready for flattening in Caret.) If you do not make any patches to the segmentation produced by the error correction process (i.e., the "_corr" version), then you do not need to regenerate the surface using Prepare to Flatten, because the files Caret uses are produced during Error Correction.

Figure 10: Correction of topological handles. A, B. Location of handle in fiducial and inflated surfaces; C. Fiducial surface after patching; D, E. Parasagittal slice 56 before and after patching (arrow points to error in D).

• • • • • • • • • • •

To see how the Dilate/Erode Mask feature works, we will use an error in the initial (uncorrected) segmentation as our example. Load SEGMENTATION/Test.L.occipital.segment_pad.mnc as Vol2. Load SURFACES/Test.L.occipital.segment.fiducial.44539.vtk (the uncorrected surface) as Surface 1 and SURFACES/Test.L.occipital.segment.fiducial.44539.vtk as Surface 2. Paint the surface using SURFACES/Test.L.occipital.segment.errors.44539.RGB_paint. Use the Locate Objects button to get a list of trouble spots, as described in the previous example. (Note that there are more trouble spots this time, because this is the uncorrected segmentation.) Use the techniques described in the previous example to pinpoint the error within 56-63, 14-18, 16-20. In this case, it is necessary to rotate to a posterior and medial view within the surface windows, in order to see the red sphere near the donut at the occipital pole. In the slice window, move to 61, 17, 17. Press the Set Mask Center button and use the arrow key to adjust the Mask slider bar (on the far left) to a value of 4. Adjust the number of erosion iterations to 1 (using the arrow to the right of the field; leave the number of dilation iterations at 0). Press the Patch button. Switch to Vol2 and note that the topological handle has been eliminated by erosion of voxels within the small masked region. To confirm that the error has in fact been corrected, press Update Handle Count. The number of handles reported should be reduced from 3 to 2. (This is the initial segmentation, which includes handles fixed by the error correction routine. The "_corr" version had only one handle, which was fixed in the previous example. The uncorrected volume is being used here only to show how to use the Dilate/Erode Mask feature.) Note that the Toggle Voxels method also could be 30

SureFit User’s Guide (Version 4.38) used to remove the voxel at 61,17,17. The Dilate/Erode Mask feature is useful where there is a block of voxels to be removed/added. 3.4.3 A la Carte. [NOTE: During normal usage, it should not be necessary to use any of the A la Carte options, so this section can be skipped if desired.] Selection of the A la Carte (Figure 11) tab allows a number of the component SureFit processes to be carried out separate from the main SureFit sequence.

Figure 11: A la Carte menu

-

Extract Cerebrum only. Removes the skull and brainstem, leaving the cerebral white matter.

-

Extract Cerebrum, Segment. Removes the skull and brainstem, segments the cerebral cortex, but does not generate any surfaces.

-

Segmentation on Full Volume. Generates a segmentation without first removing the skull or brainstem, and it does not generate surface from the segmentation.

-

Pad Cut Face. Pads volumes 1 and 2 along each of the cut faces identified in the Volume Preparation stage. The amount of padding can be adjusted in the Parameters List (default = 30 voxels for all cut faces). Note: If you will be mapping fMRI data to the surface, make sure the pad parameter doesn't exceed the number of slices cropped for a given face.

-

Fill Ventricles. Applies the ventricle-filling process to the currently loaded Vol2. The suffix "_vent" is appended to Vol2's filename (see Table 4).

-

Generate Surface, inflate, error identification. Generates a surface around the currently loaded Vol2 segmentation, creates several surfaces (raw, inflated, ellipse), plus maps of where errors are located, based on “crossovers” in the surface (tiles that are folded over on one another). These can be seen on the surface (paint file name) and in the volume (filenames).

-

Correct Errors. Applies the SureFit error correction process, and generates output volumes and surfaces.

31

SureFit User’s Guide (Version 4.38)

-

Full Error Correction Process: Combines the initial surface generation and error identification, corrects the errors, then repeats the error correction and surface generation/inflation.

-

Label Sulci. Automatically identifies buried regions of cortex as well as selected individual sulci.

-

Prepare for Flattening. Generates the surfaces and associated files needed for automated flattening in Caret (assuming that a satisfactorily corrected segmentation is loaded into Vol2).

3.5 Formatting and Visualizing fMRI Data Note: The following section describes a method for mapping fMRI data so that both volume and surface data can be viewed in SureFit. An alternative strategy is also available, in which data are mapped directly to surfaces using the Map2surface command line utility. This offers a number of improvements to SureFit's menu-driven functional mapping (e.g., no need to split pos/neg, multiple data types supported, byteswapping, flipping, multiple mapmethods). For full usage, enter "Map2Surface" at the command line. Also, see Caret User's Guide and Tutorial Part I (http://brainmap.wustl.edu/caret/pdf/caret_user_guide_part1.pdf). Caret includes many excellent tools for visualizing functional data (thresholding, pos/neg/both toggling, userspecifiable palette, min/max, underlay, toggling between various data sets, etc.). A future Caret release will incorporate the Map2Surface functionality directly into the Caret user interface. 3.5.1 Formatting fMRI Volume Data In order to visualize fMRI volume data in SureFit and to project the volume data onto surface reconstructions, the data need to in 8-bit Minc format at the same resolution (voxel spacing) as the structural image data (generally 1x 1x 1 mm). For data that are in a "raw" format (no header, often identified as a .img file), options in Appendix II can be used for file conversion.

-

If the fMRI data are 16 bit (Analyze format), and if it is desired to split the data into separate files for the positive and negative activations, a conversion utility (run by using the menu item fMRIData: Split fMRI Volume) will automatically convert a 16-bit volume to two 8-bit character volumes for the functional activity data. One represents the positive fMRI data and the other volume represents the negative fMRI data. The newly generated volumes are also cropped to the correct VOI interest (based on data contained in the .params file. This requires, however, that the current structural MRI volume has been cropped from an initial volume having the same dimensions as the fMRI image volume. (More precisely, it requires that in the .params file the values for WholeXdim, WholeYdim, and WholeZdim correspond to the fMRI volume extent and that Xmin, Ymin, and Zmin reflect the appropriate cropping relative to those dimensions.) If the structural image volume was rotated or mirror-flipped in SureFit, it also requires that the fMRI image volume be appropriately re-oriented by a process not currently available in SureFit.

-

Depress fMRIData: Split fMRI Volume and choose the volume .img. You will be prompted for the name of the cropped fMRI img file. This creates two new volumes that are sized to the dimensions of the loaded volume: .NEG.mnc and .POS.mnc.

-

Choose fMRIData: Read fMRI Volume as Vol2 and choose .POS.mnc or .NEG.mnc according to whether you wish to visualize positive or negative activation signals.

-

Choose the desired color scale using the fMRIData: Toggle fMRI Color Map option). •

For the test volume, press fMRIData: Split fMRI Volume and choose the volume Demo.LR.full.fMRI.img.



When prompted for the cropped img file name, save the files as Test.L.occipital.EyeMovement_fMRI_pad.img



Choose fMRIData: Read fMRI Volume as Vol2 and choose Test.L.occipital.EyeMovement_fMRI_pad.POS.mnc 32

SureFit User’s Guide (Version 4.38) •

Toggle the fMRIData: Toggle fMRI Color Map button to see the different options for coloring.

Painting fMRI Data onto Surfaces SureFit maps fMRI data onto surfaces using a weighting method that takes into account local surface orientation. The intensity value for each surface node is a weighted sum of the values for nearby voxels. The weighting factor is a gaussian along the direction of the local surface normal (plus a cutoff at specified upper and lower bounds) multiplied by a gaussian in the plane tangential to the surface normal. The default gaussian standard deviations (sigma ) are 2 voxels normal to the surface and 1 voxel tangential to the surface; the cutoffs are 2 voxels above and below the surface and 3 voxels tangential to the surface. For these calculations, the surface normal of each node is averaged with those of immediately neighboring nodes to reduce local surface irregularities. •

Select fMRI Data: Adjust fMRI mapping parameters. In the popup window, adjust as desired: sigma: normal (default = 2 mm; lower numbers emphasize data closer to the surface); sigma: tangential (default = 1 mm; lower numbers emphasize only nearby data on the surface); NormBelowCutoff (default = 2 mm; excludes data below the surface that are more distant than the cutoff); NormAboveCutoff (default = 2; excludes data above the surface that are more distant than the cutoff); TangCutoff (default = 3; excludes data along the surface that are more distant than the cutoff).



Select fMRI Data: Map fMRI Data to Surface and choose the desired fMRI volume (. NEG/POS.mnc) and the desired fiducial surface. This creates a new “paint” file named like .NEG/POS.node_number.RGB_paint.



Choose fMRIData: View Painted fMRI Data and select .NEG/POS.node_number.RGB_paint. After the operation is complete, the fiducial and inflated surfaces will be displayed showing the associated fMRI pattern. •

For the test volume, select fMRI Data: Map fMRI Data to Surface, choose Test.L.occipital.Eye_Movement_fMRI_pad.POS.mnc for the fMRI volume, and choose the corresponding fiducial surface SURFACES/Test.L.occipital.segment_corr2.fiducial.43306.vtk for the surface.



Select Surface Operations: Read Surface 1: SURFACES/Test.L.occipital.segment_corr2.fiducial.43306.vtk and Surface Operations: Read Surface 2: Test.L.occipital.segment_corr2.inflated.43306.vtk to bring the two surfaces into view.



Paint the currently visualized surfaces by choosing fMRIData: View Painted fMRI Data and selecting SURFACES/Test.L.occipital.EyeMovement_fMRI.POS.RGB_paint.

3.6 Volume and surface specification files A volume specification file includes key files generated during segmentation. Appendix IVA shows an exemplar volume specification file from the demo volume. A volume specification file can be used to enter all of the data into a surface oriented database, SuMS (Dickson et al., 2001; see Appendix V) in a single step. A surface specification file includes a list of key files associated with a particular "surface family" (a set of surfaces from the same segmentation and including the same number of surface nodes). Appendix IVB shows an exemplar surface specification file from the demo surface family. Data related to a given surface family can be entered into SuMS in a single step using the corresponding surface specification file. SureFit automatically generates volume and surface specification files as part of the segmentation and surface generation process.

3.7 Segmentation of a full hemisphere The SureFit demonstration data set includes a segmentation and surface reconstruction of a complete hemisphere. These are stored in a directory, SUREFIT.DEMO_FullHemisphere that is available at 33

SureFit User’s Guide (Version 4.38) http://brainmap.wustl.edu/SureFit/DemoData.html. To review the results of the demonstration data sets, download the DEMO.L.FULLHEM subdirectory. To replicate the results, change to the SUREFIT.TEST_FullHemisphere directory and return to Section 3.2. The segmentation was generated with ventricle filling and sulcal identification selected using the parameters listed in Demo.L.full.sMRI.params. The initial segmentation had 35 handles detected by the error counting process. Those visible from the lateral side are shown on an inflated surface in Figure 12A (black arrows). After error correction, the number of errors reported was reduced to 12, but only a few of these warrant correction in order to obtain a good flat map (red arrows in Figure 12B, C). Most of the errors are in non-cortical regions along the medial wall (green arrows, Figure 12D) and can be safely ignored (see Section 4.2.2).

Figure 12. Segmentation of a full hemisphere. A. Lateral view of inflated surface before error correction. B-D. Inflated surface after error correction from later (B), ventral (C), medial (D) views.

34

SureFit User’s Guide (Version 4.38)

APPENDICES I. Installation Instructions SureFit can be downloaded from http://brainmap.wustl.edu after a brief registration process. A. Installing Surefit SureFit is written using C for the underlying computationally intensive modules and python (www.python.org) as the wrapper language. VTK (www.kitware.com) is used for the volume and surface visualization code. The SureFit distribution supplies the necessary python and vtk libraries and executables so that these packages do not need to be independently installed. The distribution is a gzipped tar file: SUREfit_IRIX6.tar.gz: 230 Mbytes gunzipped, 60 Mbytes gzipped SUREfit_Linux.tar.gz: 200 Mbytes gunzipped, 54 Mbytes gzipped SUREfit_SunOS.tar.gz: 360 Mbytes gunzipped, 87 Mbytes gzipped It includes an INSTALL csh script that copies the libraries, executables, and example data sets supplied with SureFit to a user-specified directory (/usr/local by default). The login used to install SureFit must have write privileges on the SFROOT directory (usually root, if the default /usr/local location is used). To install the SureFit software type: gunzip SUREfit_*.tar.gz tar xvf SUREfit_*.tar cd SUREfit [ become super-user/root, if needed to write to SFROOT ] ./INSTALL You should see the following message: Running Installation Enter the full pathname of the directory into which SureFit should be installed (hit enter to accept default '/usr/local'): Hit enter to accept the default SFROOT (/usr/local), or enter an alternate pathname. Make sure the pathname starts with a slash (i.e., absolute rather than relative pathname). Then you will see the message: SureFit will be installed in /usr/local. Confirm to begin installation (y/n): If you entered a pathname other than /usr/local, that pathname will be displayed in the above message. Hit 'y' to begin installation. When the INSTALL script has finished running, a message will advise you to append lines to the users' .cshrc files, as described below. B. Customizing Users' Environment Users running SureFit need the following lines appended to their startup/environment files: csh users, add to ~/.cshrc: setenv SFHOME /usr/local/SUREfit set path = ($SFHOME/bin $SFHOME/mni/bin $path) setenv LD_LIBRARY_PATH $SFHOME/lib/python1.5/site-packages:$SFHOME/lib setenv TCL_LIBRARY $SFHOME/lib/tcl8.0 35

SureFit User’s Guide (Version 4.38) bash users, append these lines to $HOME/.bash_profile: SFHOME=/usr/local/SUREfit PATH=$SFHOME/bin:$SFHOME/mni/bin:$PATH LD_LIBRARY_PATH=$SFHOME/lib/python1.5/site-packages:$SFHOME/lib TCL_LIBRARY=$SFHOME/lib/tcl8.0 export PATH SFHOME TCL_LIBRARY LD_LIBRARY_PATH Replace "/usr/local" in the SFHOME setting with whatever path was entered as the directory into which SureFit should be installed. Add ":$LD_LIBRARY_PATH" to the LD_LIBRARY_PATH setting above if that variable is already defined. After you have edited the users' startup files, it is necessary to either log out and log back in or otherwise re-read the startup files (e.g., 'source ~/.cshrc' for csh users), in order to make sure these settings take effect. Otherwise, you are likely to get "command not found" and/or other errors when entering "SureFit" at the command line. C. Bug Reporting Thanks to the many users who have provided excellent feedback, SureFit is substantially revised and improved over preceding releases. Still, there are likely to be bugs and glitches still to be worked out. We definitely want to hear your suggestions and your bug reports. If you have a general suggestion feel free to e-mail [email protected].

II. Loading Your Own Data SureFit reads 8-bit NetCDF or Minc volume data. SureFit includes several command line utilities to help get your data into (and out of) a format SureFit can read: Raw2Minc - converts "raw" volume data to Minc format.

Usage: Raw2Minc image-file xdim ydim zdim Example: Raw2Minc -flipx -flipy -byteswap anatomy.img 256 256 123 CAUTION: NOT FOR USE ON FUNCTIONAL DATA; VALUES ARE SCALED 0-255! For functional data, use Map2Surface. image-file must be one of the following types: * Minc (.mnc) file * 8bit (byte) raw (no header); filesize = xdim*ydim*zdim * 16bit (short) raw (no header); filesize = xdim*ydim*zdim*2 * 32bit (float) raw (no header); filesize = xdim*ydim*zdim*4 Note that these files are 3d volumes -- not two-dimensional slices. Examples of raw files include Analyze .img and AFNI .BRIK files. The data type is guessed from the filesize: - byte or unsigned char if filesize=zdim*ydim*xdim - signed short if filesize=zdim*ydim*xdim*2 - float if filesize=zdim*ydim*xdim*4 Options (float is decimal number like 1.0): -outfname -- allows user to specify output filename By default, output file is named like input file with .mnc appended. If .BRIK, .img, or .raw, .mnc will replace that extension. -flipx -- flip input volume(s) about x axis -flipy -- flip input volume(s) about y axis 36

SureFit User’s Guide (Version 4.38) -flipz -- flip input volume(s) about z axis -byteswap -- byteswap image-file see http://brainmap.wustl.edu/SureFit/RELEASE_NOTES.html#byteswap Afni2Minc - converts anatomical AFNI BRIK volumes to Minc. Usage: Afni2Minc * There must be an afni_case.HEAD in the same directory. * Afni's 3dAttribute must be in your path and executable. * Afni's 3daxialize must be in your path and executable when orientation is neither LPI nor RAI. * This utility is intended for anatomical +orig.BRIK files. * Non-byte BRIKs are scaled from 0-255, making Afni2Minc unsuitable for functional data. Try Map2Surface. Resample - resamples Minc files (typically to get anatomical volume into cubic 1mm voxel dimensions, as required by SureFit's segmentation algorithm). Usage: Resample input_volume is a Minc (.mnc) file Options: -outfname filename (default=input_volume_basename.resample.mnc) -pixdim_in_x float (default=1.0) -pixdim_in_y float (default=pixdim_in_x if !=1.0; otherwise 1.0) -pixdim_in_z float (default=pixdim_in_x if !=1.0; otherwise 1.0) -pixdim_out_x float (default=1.0) -pixdim_out_y float (default=pixdim_out_x if !=1.0; otherwise 1.0) -pixdim_out_z float (default=pixdim_out_x if !=1.0; otherwise 1.0) -interp linear|cubic|nearest-neighbor (default=linear) Output dimensions are computed as follows: xdim_out integer portion of (xdim_in*pixdim_in_x/pixdim_out_x) ydim_out integer portion of (ydim_in*pixdim_in_y/pixdim_out_y) zdim_out integer portion of (zdim_in*pixdim_in_z/pixdim_out_z) Minc2Raw - converts Minc files into 8-bit raw volume data. Usage: Minc2Raw minc-file Minc2Afni - starts up AFNI's to3d with some sensible defaults. Usage: Minc2Afni This utility calls afni's to3d program, which must be in your path. This utility assumes SureFit norms (e.g., -orient LPI, datatype byte). Rescale - spreads out intensities if they are not distributed 0-255. Usage: Rescale input_volume output_volume cutoff compression Cutoff is point at which histogram drops off to almost nothing; newcutoff = 255.0 - (255.0-cutoff)/compression Below cutoff => volume [i]*(newcutoff/cutoff) At or above => 255.0 - (255.0-volume [i])/compression When in doubt, use compression=4 vtk2caret - converts vtk surface files into standard Caret format (topology and coordinate files). Note, though, that Caret can read vtk files directly. 37

SureFit User’s Guide (Version 4.38) Usage: vtk2caret vtk-file. The output is vtk_file, topo, vtk_file.3Dcoord, and a surface specification file, vtk_file.spec per http://brainmap.wustl.edu/caret/html4.36/file_formats/file_formats.html. Map2Surface - maps functional volumes onto 3d surfaces. This information is changing rapidly. You can find links to the latest information at http://brainmap.wustl.edu/SureFit/RELEASE_NOTES.html#mapper. Map2Surface requires that the functional volume to be mapped be in the same grid (dimensions, voxel spacing, orientation except as can be corrected by flipping) as the "full brain" (uncropped) anatomical from which vtkfname was generated. For surfaces generated by SureFit, the anatomical volume should be 1mm cubic voxels. If you can get your anatomical and functional data sets into AFNI so that they are properly aligned with one another, then you can use techniques described at http://afni.nimh.nih.gov/afni/afni_faq.shtml#Axialize to get your functional and anatomical in the same grid. Contact [email protected] for details.

III. Troubleshooting Segmentation Quality Problems. Sometimes, the quality of the anatomical scan simply does not provide enough gray-white matter contrast for SureFit to generate an acceptable segmentation. In most cases, however, SureFit's Gray Matter (GM) and White Matter (WM) peaks can be "tweaked" to improve segmentation results. Segmentation based towards white matter. If the segmentation boundary was too close to white matter and in places lies actually within the white matter, this may be alleviated by using lower values for the White Matter Peak and perhaps also the Gray Matter Peak. Try decreasing the White Matter Peak by ~5-10% and repeat the segmentation. Skip Error correction until the near-optimal value has been determined. Segmentation biased towards pial surface. If the segmentation boundary runs too close to the pia, leading to inappropriate fusion across sulcal banks, use higher values for the Gray Matter Peak (and perhaps also the White Matter Peak.) Segmentation is missing chunks of cortex. If erroneous cropping can't account for it, then adjusting your white matter and gray matter peaks can sometimes improve your result. An important thing to realize is that if your initial segmentation is this bad (i.e., missing big chunks of cortex rather than just having several handles), then there is no point letting error correction and the steps that follow continue, because they won't fix major segmentation problems. You need to get the segmentation right (not perfect, but not missing chunks) first. Fortunately, the part that responds to peak tweaking occurs early on in segmentation (first ten minutes -- usually less), and there is a shortcut on the A La Carte tab to run that step only (Extract Cerebrum Only). This step produces a file in INTERMEDIATE_VOLUMES named like *CerebralWhiteMatter.mnc (CWM volume). If chunks are missing from this file, tweak the peaks; run extract cerebrum only; and look at the CWM volume. Only when it this file is no longer missing major chunks should you go back to the Run SureFit tab. Filled Sulci. Very rarely, SureFit's error correction routine fills a sulcus. If this happens, you can try loading ERROR_CORRECTION_INTERMEDIATES/*segment*.flood.mnc in volume 1, while the corrected segmentation is loaded in volume 2. In the Interactive Error Correction Tab of the Run SureFit menu, try to adjust the mask and center to include just the area affected by the erroneously filled sulcus. Press the vol1->vol2 button to copy the masked area from the pre-corrected segmentation into the corrected segmentation. Correct any resulting handles or other errors and save your changes before generating a final surface and preparing to flatten. Common Mistakes. When you cropped the hemisphere, did you save the cropped volume before setting the white matter and gray matter peaks? If you can't recall, then were your white and gray matter peaks fairly evident? If you load a full brain and click on the set peaks tab, the histogram will look flat. But if you crop 38

SureFit User’s Guide (Version 4.38) first, the peaks will be evident. These peaks affect your segmentation quality. The temporal area is especially susceptible, since the whole area tends to be a bit darker, and it's difficult to distinguish white from gray. If none of these tips help, please email [email protected]. We'll try to help, and you may help us improve the SureFit segmentation algorithm. Note: The Troubleshooting list will grow longer as we hear from users about matters on which tips would be helpful. Other Problems. For other problems not mentioned above, see the SureFit Release Notes at http://brainmap.wustl.edu/SureFit/RELEASE_NOTES.html#issues. Known issues and work-arounds are posted there and updated frequently.

39

SureFit User’s Guide (Version 4.38)

IV. Parameter files and specification files A. Exemplar Volume specification file: Test.L.occipital.volume.spec subject Test species human hem_flag left datatype MRI region occipital layer middle method sureFit date 2001-01-18 investigator donna comment "This cut of the structural scan will be used to generate a surface onto which we will map eye movement fmri data. " commentfile Params_Recon_file ../Test.L.occipital.sMRI.params Structural_Image_file ../Test.L.occipital.sMRI.mnc Segmentation_Recon_file Test.L.occipital.segment.mnc PreCorrection_Recon_file RadialPositionMap_Recon_file Test.L.occipital.RadialPositionMap.mnc Inner_Boundary_Recon_file ../INTERMEDIATE_VOLUMES/Test.L.occipital.InnerBoundary.mnc Outer_Boundary_Recon_file ../INTERMEDIATE_VOLUMES/Test.L.occipital.OuterBoundary.mnc CerebralWhiteMatter_Recon_file ../INTERMEDIATE_VOLUMES/Test.L.occipital.CerebralWhiteMatter.mnc B. Exemplar Surface specification file: CLOSEDtopo_file Demo.L.occipital.segment_corr2.43306.topo RAWcoord_file Demo.L.occipital.segment_corr2.raw.43306.coord FIDUCIALcoord_file Demo.L.occipital.segment_corr2.fiducial.43306.coord INFLATEDcoord_file Demo.L.occipital.segment_corr2.inflated.43306.coord ELLIPSOIDcoord_file Demo.L.occipital.segment_corr2.ellipsoid.43306.coord hem_flag left paint_file Demo.L.occipital.segment_corr2.geography.43306.paint area_color_file Geography.areacolor params_file ../Demo.L.occipital.sMRI_pad.params RAWvtk_file Demo.L.occipital.segment_corr2.raw.43306.vtk FIDUCIALvtk_file Demo.L.occipital.segment_corr2.fiducial.43306.vtk INFLATEDvtk_file Demo.L.occipital.segment_corr2.inflated.43306.vtk ELLIPSOIDvtk_file Demo.L.occipital.segment_corr2.ellipsoid.43306.vtk padded yes date 2001-01-24 sampling ORIGINAL resolution FULL Segmentation_Recon_file ../SEGMENTATION/Demo.L.occipital.segment_pad_corr2.mnc investigator vanessen comment "Demo

C. Exemplar Parameters file: Except for dates, investigator, group, and comments, the parameters file contents should read as follows: 40

SureFit User’s Guide (Version 4.38) Date this parameters file was created: "2001-01-24 09:01:10.17" Most recent update: "2001-01-24 09:04:05.45" subject="Test" investigator="vanessen" species="human" group="corbetta_raichle" datatype="MRI" resolution=1.0 Structural image file: "Test.L.occipital.sMRI.mnc" Volume dimensions: xdim=76 ydim=77 zdim=104 hemisphere="left" region="occipital" Volume in standard SureFit orientation?: "yes" Volume cropped from a larger volume?: "yes" Volume padded?: "no" Padded from: "" comment="Starting volume for SureFit test\n" commentfile="" Coordinates of key landmarks: Anterior Commissure: ACx=70 ACy=108 ACz=18 Corpus callosum: CCant=0 CCdors=0 CCpost=0 CCvent=0 If volume has been reoriented: BeforeReOrientationVolume="" If volume has been cropped: WholeVolume="Test.LR.full.sMRI.mnc" Dimensions of "whole volume": WholeXdim=192 WholeYdim=256 WholeZdim=160 Coordinates of current volume origin[0,0,0] in space of "whole volume": Xmin=24 Ymin=24 Zmin=45 Volume where anterior commissure identified: "Test.LR.full.sMRI.mnc" Anterior commissure coordinates in this volume: ACx_WholeVolume=94 ACy_WholeVolume=132 ACz_WholeVolume=63 41

SureFit User’s Guide (Version 4.38) Padding to be applied when SureFit segmentation is run: PadNegX=0 PadPosX=0 PadNegY=0 PadPosY=30 PadNegZ=0 PadPosZ=0 Padding already applied to current volume: OldPadNegX=0 OldPadPosX=0 OldPadNegY=0 OldPadPosY=0 OldPadNegZ=0 OldPadPosZ=0 Segmentation: method="sureFit" layer="middle" SureFit segmentation parameters: White matter parameters: WMThresh=92 WMpeak=104 WMlow=92 WMhigh=152 WMsignum=1.300000 Gray matter parameters: CGMpeak=80 CGMlow=40 CGMhigh=92 CGMsignum=1.300000 Intensity parameters for inner boundary: InITpeak=92 InITlow=80 InIThigh=104 InITsignum=2.000000 Intensity parameters for outer boundary: OutITpeak=40 OutITlow=20 OutIThigh=80 OutITsignum=2.000000 Other segmentation parameters: CSFThresh=40 EyeThresh=118 fMRI mapping parameters: sigmanorm=2 sigmatang=1 NormBelowCutoff=2 NormAboveCutoff=2 TangCutoff=3 Note: The values for CCant, CCdors, CCpost, and CCvent will be changed to 76, 51, 65, and 36 after segmentation.

42

SureFit User’s Guide (Version 4.38)

V. Related Software SureFit and Caret are key components of an integrated set of software tools for the systematic and comprehensive surface-based analyses of cerebral cortex (Figure 13).

Figure 13: An integrated software suite for surface-based analyses. Another component to this software is a surface-oriented database, SuMS (Surface Management System). SuMS provides a systematic framework for entering and retrieving volume and surface data. Data files are entered and retrieved as specification files, which include key information (metadata) to allow data sets to be organized and searched efficiently (Dickson et al., 2001) The exemplar data sets used in the User Guide can be downloaded direct from SuMS website. Specifically, to download any of the demo volume and surface data sets, make a hyperlink connection to http://brainmap.wustl.edu/sums/sums.cgi?specfile= where is Demo.L.occipital.volume.spec Demo.L.occipital.surface.spec Demo.L.full.volume.spec Demo.L.full.surface.spec Surface-Based Atlases We have developed new surface-based atlases of human and macaque cerebral and cerebellar cortex as substrates for bringing increasing amounts of experimental data from different hemispheres into a common framework. We are using these atlases to begin generating probabilistic maps of architectonic and/or functional sub-divisions on each atlas (Drury et al., 1999; Van Essen et al., 2001b; 2002). The new atlases can be downloaded as part of the Caret tutorials. •

Download the Caret User's Guide, Part I (http://brainmap.wustl.edu/caret/pdf/caret_user_guide_part1.pdf) and follow its instructions for

downloading Caret and the atlases.

43

SureFit User’s Guide (Version 4.38)

VI. SureFit Design Principles

Figure 14: Structural MRI showing a coronal slice through the human frontal cortex.

Cortical surface reconstruction is inherently challenging because of the complex and irregular shape of cortical convolutions (especially in humans) and because of the noisy, low-contrast image quality attainable using current structural MRI methods, such as the MRI slice shown in Figure 14. When viewing such images, neuroanatomists use a variety of cues to infer the configuration of cortical folds and the location of cortical boundaries. SureFit capitalizes on many of the same cues in order to infer the underlying structure of the cortical sheet.

A. Underlying physical and imaging model SureFit is based on an underlying physical model of cerebral cortex and its appearance in structural MRI images. Cerebral neocortex is a slab-like sheet of gray matter, approximately constant in thickness, but folded into gyri (outward folds) and sulci (inward folds) as schematized in Figure 15. The transition from cortical gray matter to the underlying white matter is identified as the inner boundary. The pial surface, where cortical gray matter adjoins cerebrospinal fluid (CSF), is identified as the outer boundary. In sulcal regions, the gap between opposing sulcal banks is generally narrow, and there may be little or no CSF between adjoining outer boundaries.

Figure 15. A schematic model showing a patch of folded cortex

44

SureFit User’s Guide (Version 4.38) As substrates for the segmentation process, SureFit generates a set of probabilistic maps for the location of gray matter, white matter, the inner (gray-white) boundary, and the outer (pial) boundary. This involves a complex set of filtering operations, intensity transformations, and other volumetric operations applied to the image intensity data. Importantly, all filtering operations are applied to the 3-D image volume and are thus not limited to the data contained in individual slice planes. The maps of the inner and outer boundaries are particularly important, as they are combined to form a map of position along the radial axis (i.e., the axis delineated by arrows in Figure 15), which runs from the inner to the outer boundary. The resultant map of position along the radial axis is then thresholded, thereby generating an initial cortical segmentation whose boundary runs approximately midway through the thickness of the cortical sheet (dashed line in Figure 15. SureFit Cortical Surface Reconstruction

Volumes & Surfaces

Process

Raw image intensity Orient Volume Define Volume Of Interest (VOI)

I.

Resample (optional) Oriented, cropped intensity volume Set Parameters

Generate probabilistic volumes Composite inner boundary

II.

Composite outer boundary

Radial position map Segment volume Initial cortical segmentation

III.

Generate surface Initial surface reconstruction

IV.

Correct errors Corrected cortical segmentation

V.

Generate fiducial surface Fiducial surface reconstruction

VI.

Map fMRI data (optional) Functional activation maps

Figure 16. Processing steps and stages in SureFit.

B. Processing Stages SureFit currently involves six major processing stages (one of which is optional). Figure 16 shows a flow chart of the main processing steps and the resultant volumes and surfaces. 1. Initial Preparatory Steps. See main text part 3.3, Volume Preparation for details. 2. Main Process Probabilistic maps of cortical structure. Starting with the output of the initial pre-processing (e.g., the image slice shown in Figure 17A), SureFit applies a combination of filtering and intensity transformation steps in order to generate a number of probabilistic maps. As noted above, the most important of these are (i) a composite map of the inner boundary Figure 17B); (ii) a composite map of the outer boundary (Figure 17C); and (iii) a map of position along the radial axis (cf. Figure 18A). 45

SureFit User’s Guide (Version 4.38) The composite inner boundary map Figure 17B), is based on two types of evidence, one related to absolute image intensity and the other based on intensity gradients. Note that there is good agreement between the profile of the inner boundary map and the trajectory of the inner boundary as seen in the corresponding input image in panel A. To see the inner boundary map in the demo volume, load the MRI intensity data as Vol1 if it is not already there (Volume:Read Volume 1 Demo.L.occipital.sMRI.mnc) Select Volume:Read Volume2 INTERMEDIATE.VOLUMES/Demo.L.occipital.InnerBoundary.mnc to load the composite inner boundary into Vol2. Switch to viewing Vol1, move the cursor to (40, 30, 20) in the coronal plane and note that it is centered right at the boundary between cortical gray and white matter. Switch to Vol2 and note that the cursor is centered at a high value of the composite inner boundary map, which is the desired outcome. The composite inner boundary map (cf. Figure 17B) reflects a combination of steps that estimate the position of the inner boundary based on cues of intensity and intensity gradients. The match is very good in most places, though by no means perfect everywhere as you can judge for yourself by repeating the above steps for different locations and different slices. The quality of the fit depends greatly on whether key parameters have been set at optimal values. Note that the volume being viewed has intentionally been spatially blurred in order to reduce local irregularities.

Figure 17. Probabilistic maps of cortical structure. A. Structural MRI image. B. Probabilistic composite map of the inner boundary. C. Probabilistic composite map of the outer boundary. Outer Boundary Map Figure 17C shows a probabilistic map of where the outer (pial) boundary is located, based on evidence relating to absolute image intensity and to the presence of a nearby inner boundary at an appropriate distance away on one or both sides. Note that the outer boundary profile extends deep into all visible sulci, even in places where there is little or no visible CSF between opposite banks of a sulcus. To see the outer boundary map in the demo volume, select Volume:Read Volume2 INTERMEDIATE.Volumes/Demo.L.occipital.OuterBoundary.mnc to load the composite outer boundary map (after blurring; cf. Figure 17C). While viewing Vol1, move the cursor to (34, 30, 27) and note that it is centered right at the pial surface. Switch to Vol2 and note that the cursor is centered at a high value of the composite outer boundary map, which is the desired outcome. Switch back to Vol1, and move the cursor to (49, 30, 25). Note that it is centered midway between the banks of a sulcus, at a place where there is no intensity gradient to reveal the presence of two outer boundaries opposed to one another.

46

SureFit User’s Guide (Version 4.38) Switch to Vol2 and note that the cursor is centered at a high value of the composite outer boundary map. Once again this volume represents the desired outcome for the outer boundary map. It results from the collection of evidence about the presence of two inner boundaries, each about 3 mm away and of the opposite orientation to one another. Scroll through other slices and compare Vol1 and Vol2 to evaluate the quality of the fit between the outer boundary map and your own assessment of where the outer boundary is located. Bear in mind that this is an intentionally blurred map (like that for the inner boundary), so it is fuzzier than the actual outer boundary but has the appropriate general trajectory.

Figure 18: Combining the inner and outer boundaries. A. Radial position map. Intensity values are high near the inner boundary and in the sub-cortical interior, low near the outer boundary and in the CSF, and change smoothly along the radial axis of the cortex. B. Thresholded radial position map. C. Segmentation (translucent red) overlaid on intensity image. Note that the boundary of the segmentation runs consistently close to cortical layer 4.

Radial Position Map The inner and outer boundary maps are combined to form a radial position map, which represents distance along the radial axis of the cortex. The radial position map (Figure 18) has high values (white) near the estimated inner boundary, low values (black) near the estimated outer boundary, and is smoothly graded in between the two boundaries. In addition, regions completely interior to the inner boundary (e.g., white matter) are designated white, and regions completely exterior to the outer boundary (e.g., CSF) are designated black. Select Volume:Read Volume2:SEGMENTATION/Demo.L.occipital.RadialPositionMap.mnc to load the radial position map. Scroll to coronal slice 40 and select Vol2. This is the map of position along the radial axis, generated by appropriately combining inner and outer boundary maps. It should appear identical to Figure 18A. Adjust the upper threshold slider bar to an intensity level of 150. The thresholded region should have a shape identical to that in Figure 18B. Select Vol1+2 and toggle between Vol1+2 and Vol1. Note that the boundary of the thresholded region runs near the mid-thickness of the cortex in most regions. Adjust the threshold level to a value of 180 and toggle between Vol1+2 and Vol1. Note that the boundary of the thresholded region runs closer to the white matter. Adjust the threshold to 100 and note that the boundary of the thresholded region runs closer to the pial surface. Initial Cortical Segmentation The radial position map is thresholded at an intermediate intensity level (in this case an intensity of 150 relative to a maximum of 255) in order to generate a segmentation whose boundary runs approximately midway through the cortical thickness. The degree to which this objective is attained can be evaluated by showing the segmentation as a translucent overlay on the intensity image (Figure 18C). 47

SureFit User’s Guide (Version 4.38) Select Volume: Read Volume 2: SEGMENTATION/ Demo.L.occipital.segment.mnc. This is the initial segmentation. Toggle between Vol1, Vol2, and Vol1+2 and scroll through the volume to assess the quality of the segmentation. 3. Surface Reconstruction The boundary of a segmented volume delineates a surface that runs along the interface between segmented (white) and non-segmented (black) voxels. However, in a standard volumetric representation, this is only an “implicit” surface, because the topological neighborhood relationships of voxel faces along this interface have not been explicitly defined. The segmentation boundary can be converted to an “explicit” surface representation by methods such as the Marching Cubes algorithm. This specifies not only a set of nodes that lie precisely along the boundary of interest, but also the linkages that define the topological neighbors of each node (i.e., a wire-frame tessellation). Explicit surface representations are advantageous for several reasons, most importantly because their shape can be manipulated by repositioning of nodes (e.g., for inflation or flattening) while preserving topological relationships between neighbors (cf. Drury et al., 1998). 4. Error Detection and Correction The initial segmentation obtained by thresholding the radial position map may contain topological errors that arise from noise, low contrast, or regional inhomogeneities in the intensity distribution. SureFit uses methods of digital topology to detect, localize, and correct these errors. The objective is a segmentation that is a single object (set of connected voxels) having no internal cavities and no topological “handles” (i.e., donut-like toroidal configurations). The total number of objects, cavities, and handles in the segmented volume is computed using the Euler method, which is based the connectivity between voxels (Lee et al., 1994). Flood-filling and cavity-filling steps are used to generate a segmentation that is assured of being a single object with no cavities. The automated error-localization process highlights the approximate location of each topological handle within the segmented volume. However, no automated method currently exists for determining precisely which voxels need correction within each of these highlighted regions. The final stage of error correction entails an interactive process that is described and illustrated in the Tutorial. During this stage, it is also advisable to inspect the volume for artifactual invaginations and bulges that could lead to undesirable inaccuracies in the reconstructed surface even though they may not represent topological errors.

C. Comparisons to Other Methods There have been many efforts over the past decade to develop automated or semi-automated methods for reconstructing the convolutions of the cerebral cortex. Methods that are currently available outside the laboratory in which they were developed include mrGray (Teo et al., 1998) and FreeSurfer (Dale et al., 1999) in the freely available domain, and Brain Voyager (Goebel et al., 1998) in the commercial domain. SureFit differs from these and other published methods for cortical segmentation in several respects. The primary differences are: SureFit’s emphasis on explicitly localizing the outer as well as inner cortical boundary; its emphasis on probabilistic rather than binary segmentations at early and intermediate stages of processing; and the use of initial image resampling to enhance the spatial fidelity of subsequent stages of analysis. A variety of issues, both theoretical and practical, arise when evaluating and comparing different surface reconstruction methods. Our preliminary assessment is that the SureFit surface reconstruction provides a more faithful reflection of the actual trajectory of cortical layer 4 than other available methods. However, this is an issue that warrants quantitative evaluation. We are currently working to develop a set of metrics and validation strategies that will facilitate the quantitative, systematic, and objective evaluation of each method.

48

SureFit User’s Guide (Version 4.38)

VII. Planned Future Enhancements Improved resampling features. Improved segmentation of subcortical structures. Add ability to directly read AFNI and Analyze format volumes. Progress indicators on longish operations. Dialog window within SureFit indicating current operation being performed and history. Faster vtk libraries for Solaris that use Sun's Open GL.

VIII. Acknowledgments We thank James Dickson, Chris Lee, and Charles Anderson for valuable contributions to the development of the SureFit software and documentation. We also thank Maurizio Corbetta for permission to use an MRI data set from his laboratory as our “demo” volume in the SureFit manual. We also thank Ken Martin and Travis Oliphant for numerous discussions relating to VTK and python. The development of SureFit and Caret was supported from NIMH, NASA, NSF, NCI, and NLM under the Human Brain Project Grant MH/DA52158 and by the National Institutes of Health Grant EY02091. A patent is pending on the SureFit method.

49

SureFit User’s Guide (Version 4.38)

IX. References Bakircioglu, M., S. Joshi, M.I. Miller. (1999). Landmark matching on the sphere via large deformation diffeomorphisms, Proceedings of SPIE Medical Imaging. Image Processing, vol. 3661, pp.710-715. Corbetta, M., Akbudak, E., Conturo, T.E., Snyder, A.Z , Ollinger, J.M.,Drury, H.A., Linenweber, M.R., Raichle, M.E., Van Essen, D.C. Petersen, S.E and Shulman, G.L. (1998) A common network of functional areas for attention and eye movements. Neuron 21, 761-773. Dale, A.M., Fischl, B., and Sereno, M.I. (1999) Cortical surface-based analysis. I. Segmentation and surface reconstruction. NeuroImage 9:179-194. Dickson, J., Drury, H., and Van Essen, D.C. (2001) Surface management system (SuMS): A surface-based database to aid cortical surface reconstruction, visualization and analysis. Phil. Trans. Royal Soc, Ser B 356:1277-1292. Drury, H.A., Van Essen, D.C., Corbetta, M., and Snyder, A.Z. (1999) Surface-based analyses of the human cerebral cortex. In: Brain Warping, A.Toga et al., eds., Academic Press, pp. 337-363. Goebel, R. Khorram-Sefat, D., Muckli, L., Hacker, H. and Singer, W. (1998) The constructive nature of vision: direct evidence from functional magnetic resonance imaging studies of apparent motion and motion imagery. Eur. J. Neuroscience 10:1563-1573. Joshi, S. C. (1997) Large deformation landmark based differeomorphic for image matching.” Ph.D. Thesis, Sever Institute, Washington University, September. Lee, T.-C, Kashyap, R., and Chu, C.-N. (1994) Building skeleton models via 3-D medial surface/axis thinning algorithms. Graphical Models and Image Processing 56: 462-478. Lutz, M. (1996) Programming Python, O'Reilly & Associates, Inc., Sebastopol, CA. Schroeder, W.I., Martin, K., and Lorensen, B. (1998) The Visualization Toolkit, 2nd ed., Prentice Hall PTR, Upper Saddle River, NJ. Sled, J.G., Zijdenbos, A.P. and Evans, A.C. (1998) A non-parametric method for automatic correction of intensity non-uniformity in MRI data. Information Processing in Medical Imaging, 17: 87-97. Teo, P. C., Sapiro, G., and Wandell, B. A. (1998) Creating connected representations of cortical gray matter for functional MRI visualization. IEEE Transactions on Medical Imaging 16: 852-863. Van Essen, D.C., Drury, H.A., and Anderson, C.H. (1999a) An automated method for accurately reconstructing the cortical surface. NeuroImage 9:173. Van Essen, D.C., Drury, H.A., and Anderson, C.H. (1999b) An automated method for reconstructing complex surfaces, including the cerebral cortex. Soc. Neurosci. Abstr. 25: 1929. Van Essen DC, Drury HA, Joshi S, and Miller MI (1998) Functional and Structural Mapping of Human Cerebral Cortex: Solutions are in the Surfaces. PNAS 95:788-795. Van Essen, D.C., Dickson, J., Harwell, J., Hanlon, D., Anderson, C.H. and Drury, H.A. 2001a An Integrated Software System for Surface-based Analyses of Cerebral Cortex. Journal of American Medical Informatics Association . (Special issue on the Human Brain Project) 8:443-459. Van Essen, D.C. Lewis, J.W,. Drury, H.A., Hadjikhani, N., Tootell, R.B.H., Bakircioglu, M. and Miller, M.I. (2001b) Mapping visual cortex in monkeys and humans using surface-based atlases. Vision Research (special issue). 41: 1359-1378. Van Essen, D.C., Harwell, J., Hanlon, D., Dickson, J., Snyder, A. and Cox, R. (2002) Mapping functional activation patterns onto surface-based atalses of cerebral and cerebellar cortex. Neuroimage (Abst) in press. 50

SureFit User’s Guide (Version 4.38)

51