A Julia implementation of an algorithm similar to FSL's topup. As input, it uses two (NIfTI format) echo planar MR images with opposite traversals of k-space, and outputs a voxel displacement map for correcting the resulting distortions. Note that some experimentation to optimise the regularisation setting (sig2) may be needed to achieve adequate results.
Optimisation is done over multiple spatial scales (coarse-to-fine). At each scale, updates are made using Gauss-Newton, where the system of equations are solved via a multigrid V-cycle.
SCOPE depends on compiled functions, which are currently part of the PushPull.jl package. Note that this is still early days, so there may yet be some major restructuring.
- Andersson, J.L., Skare, S. and Ashburner, J., 2003. How to correct susceptibility distortions in spin-echo echo-planar images: application to diffusion tensor imaging. Neuroimage, 20(2), pp.870-888.