guruucsd / lateralized-components

Submission to OHBM 2016 on functional lateralization using the neurovault dataset.
0 stars 2 forks source link

RuntimeWarning error when getting dataset #60

Closed atsuch closed 7 years ago

atsuch commented 7 years ago

I was testing my code, and encountered the following;

File "main.py", line 365, in components=components, query_server=query_server, plot=plot, args) File "main.py", line 254, in loop_main_and_plot query_server=query_server) File "main.py", line 60, in get_dataset images, term_scores = fetch_neurovault(max_images=max_images, kwargs) File "/home/ami/Documents/Work/imaging/RL_ICA/OHBM-2016/nilearn_ext/datasets.py", line 174, in fetch_neurovault images, term_scores = _neurovault_remove_bad_images(images, term_scores) File "/home/ami/Documents/Work/imaging/RL_ICA/OHBM-2016/nilearn_ext/datasets.py", line 98, in _neurovault_remove_bad_images is_rejected = np.all(dat > 0) or np.all(dat < 0) or (np.unique(dat).size < 2000) RuntimeWarning: invalid value encountered in greater

Since I have ICA images, I don't really need to get new images unless I want to re-calculate ICA images with newer dataset, but currently we get dataset regardless. Maybe we should change that... :P But anyhow, dataset.py needs a fix, it seems..

bcipolli commented 7 years ago

Try running with --offline. Looks to me like one of the newer images has an unexpected data type in it. I haven't been able to replicate..

bcipolli commented 7 years ago

Ah, I had to upgrade my libraries (probably numpy), and was able to replicate. Debugging now.

bcipolli commented 7 years ago

Fixed in aac9af0