introduction to fmri pre-processing - cubic | rhul cubic 2018-01-25 · head motion - realign first:...
TRANSCRIPT
Introduction to fMRI–
Pre-processing
Tibor AuerDepartment of PsychologyResearch Fellow in MRI
• Anatomical data: T1-weighted, 3D, 1/subject or session- (ME)MPRAGE/FLASH sequence, undistorted- High spatial resolution (~1 mm isotropic)- Optimised for structural contrast1
- Acquisition time ~5 minutes
• Functional data: T2*-weighted, 4D, 1/measurement- EPI sequence, distorted- Lower spatial resolution (2-3 mm non-isotropic)- Optimised for functional contrast2
- Acquisition time ~2 seconds (20-30 slices)
• Fieldmaps: 2×3D, 1/session- Dual-echo GE sequence, undistorted- Lower spatial resolution (same as fMRI)- Map of magnetic field inhomogeneities- Acquisition time ~1 minute.
Data – Types
• Time series
- showing BOLD signal changes
- in each point in the brain
3D
- at each repetition (e.g. 2 seconds)
+1D
Data – Functional
Time
BOLD signal
Time
Challanges Solutions• Different people’s brains are different shapes
• EPI images are distorted
• The head is likely to move during the fMRI scan
• Slices within the same image come from different time points (assuming standard 2D EPI)
• Head movements between fMRI scans and structural scans
• Signal is typically spatially smoothed
• HRF is delayed and temporally smooth
• Signal intensity drifts over time
• Normalisation to template (MNI)
• Undistort using B0 fieldmap
• Spatial realignment (rigid-body)
• Temporal realignment (slicetiming)
• Coregister (headers only)
• Spatial smoothing
• Just model it (next lecture)!
• Just model it (next lecture)!
Overview – Challanges
Courtesy to Johan Carlin
Challanges Interactions• Different people’s brains are different shapes
• EPI images are distorted
• The head is likely to move during the fMRI scan
• Slices within the same image come from different time points (assuming standard 2D EPI)
• Head movements between fMRI scans and structural scans
• Signal is typically spatially smoothed
• HRF is delayed and temporally smooth
• Signal intensity drifts over time
Overview – Challanges
realignunwarp
realign – slicetiming ordering
Preprocessing is no substitutefor collecting high quality data!
Courtesy to Johan Carlin
Overview
Images in dicomformat
Convert to format used by SPM (NIFTI)
Within series processing:• Spatial realignment• Undistortion• Temporal realignment
CoregisterEPI to structural
Normalise structural
Normalise EPI
Smooth EPI
Single subject stats
Group stats Publish…
Initial image diagnostics
Overview – aa modules (aamod_*)
autoidentifyseries_timtrioget_dicom_structuralget_dicom_epiget_dicom_fieldmap
convert_structuralconvert_episconvert_fieldmapsfieldmap2VDM
realignunwarpslicetiming
coreg_extended_2epi biascorrect_structural
coreg_extended_1
segment8_multichan
dartel_createtemplate
dartel_norm_write
+
freesurfer_initialise
freesurfer_autorecon_all
norm_write_dartel
worm_write_meanepi_dartel
smooth
firstlevel_model
firstlevel_contrasts
firstlevel_threshold
firstlevel_threshold_register2FS
secondlevel_model paper_maker ???
tsdiffana
• Scaled variance of difference from the 1st vol.:
- Volumewise
- Slicewise
• Descriptive stats:
- Volumewise mean
- Slicewise variance
Preprocessing – Initial diagnostics
Mean and varianceimages:
Diagnostic plots:
• People have different shaped brains Transforming brains to a common template- Group studies- Cross study comparison, meta analysis
• Template: universal space- Talairach and Tournoux, 1988 (based on a single subject)
- Montreal Neurological Institute: MNI152 Averaged from T1 images of 152 subjects
- Information eXtraction from Images (London): IXI (in SPM12) Also in MNI Fewer (but growing number of) subjects, geographically more representative More tissue classes (segmentation)
Preprocessing – NormalizationChallenge
• Direct:
1. EPI MNI modality + resolution/smoothness + shape
• Indirect (Coreg1+Norm):
1. Structural MNI smoothness + shape
2. EPI StructuralMNI modality + resolution
• Indirect+ (Coreg1+DARTEL+Norm):
1. Structural Study template smoothness + shape (intermediate)
2. Study template MNI shape (intermediate)
3. (Structural Study template MNI)
4. EPI Structural Study template MNI modality + resolution
Preprocessing – NormalizationApproaches
• Affine (12 DOF) registration:
- 3 translations
- 3 rotation
- 3 shears
- 3 zooms
Preprocessing – NormalizationTransformation
Zoom
Shear
Rigid-body(6DOF)
• Linear transformations:
- Assumes linear relationship between position and transformation
- Able to match overall size and shape, but not small details
• Nonlinear transformations:
- Deformation fields: nonlinear relationship between position and transformation
large DOF Caveat: overfitting (unnecessary warps) make a brains exactly the same
↓
- Regularisation: transformation within a certain range based on a priori knowledge1
Preprocessing – NormalizationTransformation
• Nonlinear transformations:
Preprocessing – NormalizationTransformation
Template Affine only• some differences
in shape
Affine + nonlinear with regularization• good match to
overall shape• some differences
in details
Affine + nonlinear without regularization• overfitting
• Coreg1+Norm:
1. Structural MNI smoothness + shape non-linear via segmentation2
2. EPI StructuralMNI modality + resolution rigid-body (6DOF)
• Coreg1+DARTEL+Norm:
1. Structural Study template smoothness + shape (intermediate) non-linear via segmentation2
2. Study template MNI shape (intermediate) affine (12DOF)
3. (Structural Study template MNI)
4. EPI Structural Study template MNI modality + resolution rigid-body (6DOF)
Preprocessing – NormalizationImplementation
• Diagnostics
Preprocessing – NormalizationSegmentation
• Diagnostics
Preprocessing – NormalizationSegmentation
• Movement confounds data:
- Signal recorded from different position
Correspondence
PVE (e.g. WM – GM)
- Signal recorded at a different field strength
Local inhomogeneities in the magnetic field affecting the brain area
Preprocessing – Motion correctionChallenge
• Movement confounds data:
- Signal recorded from different position
Correspondence
PVE (e.g. WM – GM)
↓
• Motion correction: transform each volume to the first
- same modality, same resolution, same shape Rigid-body (6DOF)
Preprocessing – Motion correctionSolution
• Movement confounds data:
- Signal recorded at a different field strength
Local inhomogeneities in the magnetic field affecting the brain area
↓
• Motion correction with Unwarping:
- Iteratively estimate the effects and compensate for them
Preprocessing – Motion correctionSolution
Motion correction
Estimate “derivative
fields”1
Compensate “derivative
fields”
Until minimal change in remaining variance
• Movement confounds data:
- No corection is perfect
Residual effect of motion
↓
• Include the realignment parameters as covariates in the statistical model
- Capture any movement related variance in the data.
- However!
Reduces design’s degree of freedom (usually > 100)
Problematic if movement is correlated with effects of interest
(e.g. button pushes, verbal responses etc.)Can remove the effects of interest.
Preprocessing – Motion correctionSolution
Preprocessing – Motion correctionDiagnostics
QAMoCo parameters
• Best solution: reduce movement to the minimum
- Comfort1
- Discourage talk during breaks (between-session movement2)
- Dummy scans, Instructions
- “End of measurement”
• Reject data to reduce heterogeneity (Summary)
- Scans
- Subjects
Preprocessing – Motion correctionDiagnostics
• Summary (outliers)
- Trans - x: None
- Trans - y: 12
- Trans - z: 1
- Pitch: None
- Roll: 19
- Yaw: 19
Preprocessing – Motion correctionDiagnostics
Preprocessing – Motion correctionDiagnostics
Subject #19 MoCo parameters Subject #2 MoCo parameters
• Acquisition
- 2D EPI sequence collect volume slice-by-slice
- Each slice is acquired at a different time
- TR = 2s, 32 slices:
62.5 ms between-slice difference
~1.9 s difference between the first and the last slices
↓
- Confound precise timing if TR is long (> 1s)
Event-related vs. epoch-based
Preprocessing – Temporal realignmentChallenge
• Slice time correction
- Interpolate timecourse1
• Implementation
- Preprocessing:
Calculate time shift
“Tags” slices
- Interpolation during HRF-estimation
Preprocessing – Temporal realignmentSolution
0 1 2 3 4 5 6 7 8 92468
0 1 2 3 4 5 6 7 8 9-202
0 1 2 3 4 5 6 7 8 9-202
0 1 2 3 4 5 6 7 8 9-202
0 1 2 3 4 5 6 7 8 9-202
Time (in TRs)
• Sliceorder/Slice timings
- Timings are more accurate than orders
- Specified manually (automatic in aa!)
• Reference slice: all other slices will be “adjusted” to it
- Middle slice: ↓ the maximum interpolation necessary ↓ interpolation artefacts
- It will not be altered: Chose according to your area of interest!
- Caveat:
Scanner sync pulse is at the acquisition of the first slice- Stimuli timing adjusted to the first slice
or
- Model needs to be adjusted (automatic in aa!)
Preprocessing – Temporal realignmentImplementation
• Slices acquired at different time pointsspin history effects
- Movement against slice direction Striping
- Interleaved: If you move up 1 voxel, the slices are excited every 1/2 or 3/2 TR instead of 1/1.
- Movement by slicetime interaction
Can’t correct
Motion parameters won’t show(but imply/correlate)
↓
- Need to look at your data!
Preprocessing – Motion correction and Temporal Realignment
Courtesy to Danny Mitchell
No motion Motion
Interleaved
Sequential
• Principle:
- Slice time first:
+ slice timing is fixed
- non-linear (i.e. non-correctable) spatial effects in your data if there is head motion
- Realign first:
+ head motion is fixed
- slice timings are a little bit wrong sometimesdue to head movement
Preprocessing – Motion correction and Temporal Realignment
Courtesy to Johan Carlin
• Guidelines
- Realign first if you use a sequential acquisition (slices are ~50ms apart) timing errors will be small
- Slice time correct first if you use an interleaved acquisition, where timing errors could be large
- Don’t bother with slice time correction if:
You acquire the slab at once (3D EPI) or TR is extremely short (e.g. multi-band)
If you plan to model HRF shape (FSL solution) Cave: overfitting!
• Goal: the functional in the same space as the structural
- Overlay functional results onto the structure to enhance localisation
- Use structural as a precursor to spatial normalization: EPI StructuralMNI
• Data types
- Reference image: Structural: T1-weighted, high resolution, fewer artefacts
- Source image: Functional: T2*-weighted, low resolution
↓
modality + resolution, but same shape Rigid-body (6DOF)
Preprocessing – CoregistrationChallenge
• Functional image to estimate transformation
- example EPI from ca. the middle – FSL
- mean EPI (temporally averaged) – SPM
Smoothed: lower noise level vs. smaller (effective) spatial resolution
• Requirements
- Reasonably good starting point (local optima)
Similar acquisition position (AutoAlign)
Reorient (?)
- Adequate overlapping with structural partial-brain fMRI requires two-step coregistration via a “whole-brain EPI”1
1. Whole-brain EPI Structural
2. Partial-brain EPI Whole-brain EPI Structural
Preprocessing – CoregistrationSource image
• Spatial weighted averaging: usually Gaussian kernel
- Value at each voxel: a weighted average of the values in surrounding voxels
- ↑ signal-to-noise ratio: assuming random noise
- Signal spread (depends on kernel size):
↑ between-subject spatial correspondence (by blurring minor differences)
↓ effective spatial resolution (RESEL) ↓ the number of multiple comparisons
“False” positives (voxel wise)!
Preprocessing – Smoothing
Original signal Signal plus noise Recovered signalApply kernelto each point
• Amount to smooth:
- Full Width at Half Maximum height (FWHM)
- Ideally: hypothesis-dependent1
According to the spatial extent of the signal
Neuroanatomical assumptions
- Visual areas: smaller kernel
- Prefrontal: larger kernel
- Methodologically: GRFT-dependent (inference)
Ensure minimum smoothness (RESEL ≥ 3×voxel)
Iterative?
- Practically:
Resolution-dependent: 1.5×voxel-size
8-10 mm is common (SPM default, history!)
Preprocessing – SmoothingKernel Size
FWHM
Questions?
House, M.D. Los Angeles, CA: Fox Broadcasting