[pymvpa] searchlight gets stuck, issues error
Sergey.V.Fogelson at Dartmouth.edu
Sergey.V.Fogelson at Dartmouth.edu
Tue Feb 2 23:46:42 UTC 2010
Hello,
Im running the searchlight algorithm on some data and it gets stuck
right around 68% complete.
Ive zscored and detrended the dataset before preprocessing. the error
that is issued says that the SVM classifier cannot converge because of
zero norm.
here's the code ive used to preprocess the data:
if __debug__:
debug.active += ["SLC"]
attr = SampleAttributes('FFA_class_25jan10sf0')
dataset = NiftiDataset(samples='25jan10sf.nii', labels=attr.labels,
chunks=attr.chunks, mask = 'mask.nii')
detrend(dataset, perchunk=True, model="linear", polyord = 1)
zscore(dataset, perchunk=True,targetdtype= 'float16')
dataset = dataset.select( labels = [1,2] )
clf = LinearCSVMC()
cv = CrossValidatedTransferError(TransferError(clf), NFoldSplitter())
s1 = Searchlight(cv, radius=9)
s1_map = s1(dataset)
orig_s1_map = dataset.mapReverse(N.array(s1_map))
data_hdr = dataset.niftihdr
NiftiImage(orig_s1_map,header=data_hdr).save('9mmSL_SVM_tr1_facevshouse.nii.gz')
thanks very much for your help,
Sergey.
More information about the Pkg-ExpPsy-PyMVPA
mailing list