Back to the main page.

Bug 62 - spm_brainwarp is missing from fieldtrip/external/spm2

Status CLOSED FIXED
Reported 2010-04-08 12:00:00 +0200
Modified 2012-10-02 18:39:46 +0200
Product: FieldTrip
Component: core
Version: unspecified
Hardware: PC
Operating System: Mac OS
Importance: P5 normal
Assigned to: Joint development user
URL:
Tags:
Depends on:
Blocks:
See also:

Jan-Mathijs Schoffelen - 2010-04-08 12:00:29 +0200

The functions spm_brainwarp.* are missing from fieldtrip/external/spm2. This causes a crash when ft_volumenormalise wants to apply nonlinear normalisation. The functions have to be added.


Robert Oostenveld - 2012-10-02 18:39:46 +0200

I noticed on the dashboard that this test script failed. Initially I was not able to reproduce the error, but then with this I was: >> restoredefaultpath >> addpath ~/matlab/fieldtrip >> ft_defaults mrifile = '/home/common/matlab/fieldtrip/data/Subject01.mri'; mri = ft_read_mri(mrifile); cfg = []; cfg.nonlinear = 'yes'; mri2 = ft_volumenormalise(cfg, mri); the input is volume data with dimensions [256 256 256] Converting the coordinate system from ctf to spm ??? Undefined function or method 'spm' for input arguments of type 'char'. Error in ==> align_ctf2spm at 50 switch spm('ver') Error in ==> ft_convert_coordsys at 63 obj = align_ctf2spm(obj); Error in ==> ft_volumenormalise at 114 interp = ft_convert_coordsys(interp, 'spm'); ---------- The low level function expects spm to be on the path, whereas it is only added later. I fixed the regression issue, moved the spm path check to earlier in the code manzana> svn commit ft_volumenormalise.m Sending ft_volumenormalise.m Transmitting file data . Committed revision 6639.