1. Introduction This manual describes how to use the Field Map Toolbox Version 2.0 for creating unwrapped field maps that can be used to do geometric distortion correction of EPI images in SPM5. 1. 1. Downloading the Field Map Toolbox FieldMap Version 2.0 can be downloaded as part SPM5: http://www.fil.ion.ucl.ac.uk/spm/software 1. 2. Before you Begin a) The data processing stream described in this manual is applicable only for data collected at the A.A. Martinos Imaging Center at MIT. For a general overview and manual, please visit: http://www.fil.ion.ucl.ac.uk/spm/toolbox/fieldmap/ b) The convention used to describe the direction of the k-space traversal is based on the coordinate system used by SPM. In this coordinate system, the phase encode direction corresponds with the y-direction and is defined as positive from the posterior to the anterior of the head. The x-direction is defined as positive from left to right and the z-direction is defined as positive from foot to head. The polarity of the phase-encode blips describes in which direction k-space is traversed along the y-axis with respect to the coordinate system described here. c) All versions of FieldMap and Unwarp are only designed to work with images collected with the phase-encode direction in y. d) For the geometric distortion correction to work, it is extremely important that the number of slices, voxel size and slice orientation of the EPI and field map are the same. Please make sure that this is examined at the scanner before data collection. e) Make sure that you use the most recent version of SPM5, including updates (ftp://ftp.fil.ion.ucl.ac.uk/spm/spm5_updates) with the field map toolbox. 2. Creating Field Maps Using the Field Map GUI (Version 2.0) in SPM5 The FieldMap Toolbox GUI, which can be invoked using the toolbox menu in SPM5 GUI, is shown on the left in figure 1. It is divided into two parts. The top part (see section 2.1) deals with creating the field map in Hz and the bottom part (see section 2.2) deals with creating the voxel displacement map (VDM) and unwarping the EPI. The toolbox can be used by working through the different inputs in the following order: 2.1 Create field map in Hz 2.1.1 Load defaults file Select the defaults file from which to load default parameters. If necessary, the parameters used to create the field map can be temporarily modified using the GUI. To change the default parameters, edit pm_defaults.m or create a new file called pm_defaults_NAME.m. 1 2.1.2 Data Input Format PM – The acquired field map images are in phase and magnitude format. There is a single pair of phase and magnitude images (i.e. 2 images). The phase image that is available from the scanner is actually the difference image from the phase images of the two echo times. The magnitude image corresponds to that of the short echo time. The units for the phase images MUST BE RADIANS BETWEEN +pi and -pi. User will be asked if this is required when the images are selected. 2.1.3 File Selection Create VDM and unwarp EPI Create field map The acquired scanner files will be in dicom format which can be correctly converted using the dicom converter in SPM5. After making sure that the radio button corresponding to PM is enabled, load Phase and Magnitude images: a) Single phase image i.e., pre-subtracted phase image for Siemens generated images. b) Single magnitude image from one of the echo times. c) LEAVE EMPTY as input consists of a single phase and magnitude pair. d) LEAVE EMPTY as input consists of a single phase and magnitude pair. Figure 1 – FieldMap GUI and Results 2 2.1.4 Short TE/Long TE (ms) Specify the short and long echo times in milliseconds (ms) associated with the field map acquisition. You could find these values from the Routine tab of the acquisition protocol. Both of these values are required even if a single phase and magnitude image is used as input. 2.1.5 Mask Brain Specify yes to generate a brain mask using the magnitude data which will be used to exclude regions of the field map outside of the brain. 2.1.6 Calculate Calculate an unwrapped field map in Hz which is stored in memory. It involves some or all of the following steps (as specified in pm_defaults.m): a) calculation of a Hz fieldmap from input data b) segmentation to exclude regions outside of the brain c) phase unwrapping d) smoothing and dilation of the processed fieldmap The processed field map (in Hz) is displayed in the graphics window (top row, right figure 1) and the field at different points can be explored. The field map in Hz is converted to a VDM using the parameters shown in the FieldMap GUI and saved with the filename vdm5_NAME-OF-FIRST-INPUT-IMAGE.img in the same directory as the acquired field map images. The VDM file is overwritten whenever the field map is recalculated or when any parameters are changed. The resulting VDM file can be used for unwarping the EPI using Realign & Unwarp in SPM5 (see section 3). 2.1.7 Write Write out the processed field map (in Hz). The image will be saved with the filename fpm_NAME-OF-FIRST-INPUT-IMAGE.img in the same directory as the acquired field map images. 2.1.8 Load Pre-calculated Load a precalculated unwrapped field map (fpm_*.img). This should be a single image volume with units of Hz. The precalculated field map may have been created previously using the FieldMap toolbox or by other means. Once loaded, the field map is displayed in the graphics window (top row, right, figure 1) and the field at different points can be explored. 2.1.9 Field map value (Hz) Interrogate the value of the field map in Hz at the location specified by the mouse pointer in the graphics window. 3 2.2. Create voxel displacement map (VDM) and unwarp EPI When any of the parameters below are changed, a new VDM is created and written out as vdm5_NAMEOF-FIRST-INPUT-IMAGE.img. 2.2.1. EPI-based field map - Yes/No Select No as the field map is non-EPI. 2.2.2. Polarity of phase-encode blips - +ve/-ve Select +ve or –ve blip direction. When images are acquired k-space can be traversed using positive or negative phase-encode blips. This direction will influence the geometric distortions in terms of whether the affected regions of the image are stretched or compressed. By convention, phase encode in anterior to posterior (A>P) direction is –ve and vice versa. 2.2.3. Apply Jacobian modulation - Yes/No This is not recommended for unwarping EPI data at this stage, so select No. The functionality is to do Jacobian Modulation to adjust the intensities of voxels that have been stretched or compressed. 2.2.4. Total EPI readout time (ms) Enter the total time in ms for the readout of the EPI echo train which is typically 10s of ms. This is the time taken to acquire all of the phase encode steps required to cover k-space (i.e., one image slice). For example, if the EPI sequence has 64 phase-encode steps, the total readout time is the time taken to acquire 64 echoes: Total EPI readout time = number of echoes * echo spacing. Echo spacing is the time (ms) between the start of the readout of two successive lines in k-space during the EPI acquisition. It can be obtained from the acquisition protocol. Open the protocol for the functional scan. Go to the sequence tab. Go to Part 1. The Echo spacing is displayed on bottom right. If the echo spacing is say, 0.5 ms; then the total read out time in the above given example is calculated as 64*0.5=32 ms. Depending on the phase encode steps, say 128, the total EPI readout time has to be calculated accordingly. 2.2.5. Load EPI image Select a sample EPI image, which is the first image in the series (first time point). This image is automatically unwarped using the VDM calculated with the current parameters. The warped and the unwarped image are displayed in the graphics window underneath the field map (middle rows, right, figure 1). 2.2.6. Match VDM to EPI Select this option to match the field map magnitude data to the EPI image before it is used to unwrap the EPI. In general, the field map data should be acquired so that it is as closely registered with the EPI data as possible but matching can be selected if 4 required. If at step 2.1.3, a precalculated field map was loaded then the user is prompted to select a magnitude image in the same space as the field map. 2.2.7. Write unwarped Write unwarped EPI Analyze image with the filename uNAME_OF_EPI.img. 2.2.8. Load structural Load a structural image for comparison with unwarped EPI. This is displayed in the graphics window below the other images (bottom row, right fig 1). 2.2.9. Match Structural Coregister the structural image to the unwarped EPI and write the resulting transformation matrix to the .hdr file of the selected structural image. 2.2.10. Help Call spm_help to display FieldMap.man. 2.2.11. Quit Quit the toolbox and closes all windows associated with it. 3. Using the VDM file with Unwarp In SPM, select the Realign + Unwarp option. When requested, select the vdm5_* file for the subject and/or session (figure 2). If you acquired more than one session and a field map for each session, select the vdm file for each corresponding session. If you acquired more than one session but only one fieldmap, select the vdm file for the first session and then when asked to select the vdm file for the other sessions, select the first one again. For more information about Unwarp see: http://www.fil.ion.ucl.ac.uk/spm/toolbox/unwarp 4. Example from a self-reference task Base>Sem (Before Correction) Base>Sem (SPM5 Field Map Correction) p-value = 0.01 (unc) Extend threshold=20 5 Figure 2 – Using the VDM file with Realign & Unwarp 5. References 1) Jezzard P and Balaban RS (1995) Correction for geometric distortions in echoplanar images from B0 field variations. Magn Reson Med 34:65-73 2) Andersson JLR, Hutton C, Ashburner J, Turner R, Friston K (2001) Modelling geometric deformations in EPI time series. NeuroImage 13:903-919 3) Hutton C, Bork A, Josephs O, Deichmann R, Ashburner J, Turner R. (2002). Image distortion correction in fMRI: A quantitative evaluation. NeuroImage 16:217-240 4) Jenkinson M. (2003). Fast, automated, N-dimensional phase-unwrapping algorithm. MRM 49:193-197 5) Hutton, C., Deichmann, R., Turner R., Andersson, J. L. R., (2004). Combined correction for geometric distortion and its interaction with head motion in fMRI. Proceedings of ISMRM 12, Kyoto, Japan 6