Hi all,
When i try to learn the searchlight analysis in https://nilearn.github.io/decoding/searchlight.html. It echos errors when i ran
searchlight = nilearn.decoding.SearchLight(
mask_img,
process_mask_img=process_mask_img,
radius=5.6, n_jobs=n_jobs,
verbose=1, cv=cv)
searchlight.fit(fmri_img, y)
.
The errors were: AttributeError: ‘module’ object has no attribute ‘decoding’
How to fix that.
Thanks.
Ahoi hoi @rujing_cha,
following the link you posted and checking the code there, it seems
like this guide/example is missing an necessary import function, more specifically
import nilearn.decoding
. Try running that before you define the searchlight and
everything should work fine. You could also have a look at the searchlight example
using the same data and approach here.
Regarding the missing import I’ll open an issue on nilearn’s github page.
HTH, best, Peer