Skip to content

Average repetitions Bruker 7t

Eduardo Garza-Villarreal edited this page Feb 13, 2020 · 7 revisions

If the animal is ex-vivo (did not move), then you can directly average. Otherwise, I prefer to include registration using antsRegistration

This is an example from a T1w FLASH for DBM.

Transform the nifti (Bruker2Nifti) to MNC. Separate the time using fslsplit, then use ants.

fslsplit rat.nii.gz -t

nii2mnc rat.nii.gz rat.mnc

antsRegistration --dimensionality 3 --float 0 --output [reg_1,rat1_reg.mnc] --interpolation Linear --use-histogram-matching 0 --initial-moving-transform [rat1.mnc,rat2.mnc,1] --transform Rigid[0.1] --metric MI[rat1.mnc,rat2.mnc,1,64,None] --convergence [2000x1000x500x250x100,1e-6,10] --shrink-factors 4x3x2x1x1 -s 2x1.5x1x0.5x0vox -v

Ants changes the dimensions, so we need to change that.

ConvertImage 3 input.nii.gz output.mnc

Then you average

mincaverage rat1.mnc rat2.mnc rat_out.mnc

Clone this wiki locally