Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cannot import name '_get_dataset_dir' from 'nilearn.datasets.utils' (/opt/conda/lib/python3.11/site-packages/nilearn/datasets/utils.py) #444

Open
stebo85 opened this issue Sep 10, 2024 · 1 comment

Comments

@stebo85
Copy link

stebo85 commented Sep 10, 2024

Dear nltools team,

It seems nltools 0.5.1 is currently not working with nilearn 0.10.4 under Python 3.11.6. The error I get when running:

from nltools import *

is

---------------------------------------------------------------------------
ImportError                               Traceback (most recent call last)
Cell In[30], line 1
----> 1 from nltools import *

File /opt/conda/lib/python3.11/site-packages/nltools/datasets.py:25
     23 import pandas as pd
     24 from nltools.data import Brain_Data
---> 25 from nilearn.datasets.utils import _get_dataset_dir, _fetch_file
     26 from pynv import Client
     28 # Optional dependencies

ImportError: cannot import name '_get_dataset_dir' from 'nilearn.datasets.utils' (/opt/conda/lib/python3.11/site-packages/nilearn/datasets/utils.py)
@stebo85
Copy link
Author

stebo85 commented Sep 11, 2024

If anyone else runs into this problem, before this toolbox is fixed, this is a combination of older dependency versions that works with Python 3.11.6:

pip install nltools==0.4.7 nilearn==0.10.2 scipy==1.11.4

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant