running the mriqc_clf on docker
Opened this issue · 2 comments
Hi,
I am running the latest version of mriqc (21.0.0rc2), and are trying mriqc_clf on docker.
I've tried the following command:
docker run -v $PWD:/scratch -w /scratch --entrypoint=mriqc_clf nipreps/mriqc:21.0.0rc2 --load-classifier -X group_T1w_copy.tsv
But it didn't work.
Error:
Traceback (most recent call last):
File "/opt/conda/bin/mriqc_clf", line 8, in
sys.exit(main())
File "/opt/conda/lib/python3.8/site-packages/mriqc/bin/mriqc_clf.py", line 303, in main
cv_helper = CVHelper(
File "/opt/conda/lib/python3.8/site-packages/mriqc/classifier/helper.py", line 200, in init
self.load(load_clf)
File "/opt/conda/lib/python3.8/site-packages/mriqc/classifier/helper.py", line 716, in load
from sklearn.externals.joblib import load as loadpkl
ModuleNotFoundError: No module named 'sklearn.externals.joblib'
and I tried command: from sklearn.externals import joblib on spyder, and did't get any errors.
Please give me some advice.
Many Thanks!
Wenjun
And I installed mriqc on a Python 3 environment and ran 'mriqc_clf --load-classifier -X group_T1w.tsv'
But it didn't work o(╥﹏╥)o
Error:
Traceback (most recent call last):
File "/home/lipalab/anaconda3/bin/mriqc_clf", line 8, in
sys.exit(main())
File "/home/lipalab/anaconda3/lib/python3.8/site-packages/mriqc/bin/mriqc_clf.py", line 241, in main
cvhelper = CVHelper(
File "/home/lipalab/anaconda3/lib/python3.8/site-packages/mriqc/classifier/helper.py", line 184, in init
self.load(load_clf)
File "/home/lipalab/anaconda3/lib/python3.8/site-packages/mriqc/classifier/helper.py", line 705, in load
self._estimator = loadpkl(filehandler)
File "/home/lipalab/anaconda3/lib/python3.8/site-packages/sklearn/externals/joblib/numpy_pickle.py", line 585, in load
obj = _unpickle(fobj, filename, mmap_mode)
File "/home/lipalab/anaconda3/lib/python3.8/site-packages/sklearn/externals/joblib/numpy_pickle.py", line 504, in _unpickle
obj = unpickler.load()
File "/home/lipalab/anaconda3/lib/python3.8/pickle.py", line 1210, in load
dispatchkey[0]
File "/home/lipalab/anaconda3/lib/python3.8/pickle.py", line 1526, in load_global
klass = self.find_class(module, name)
File "/home/lipalab/anaconda3/lib/python3.8/pickle.py", line 1577, in find_class
import(module, level=0)
File "/home/lipalab/anaconda3/lib/python3.8/site-packages/mriqc/classifier/sklearn/init.py", line 5, in
from .cv_nested import ModelAndGridSearchCV
File "/home/lipalab/anaconda3/lib/python3.8/site-packages/mriqc/classifier/sklearn/cv_nested.py", line 34, in
from sklearn.model_selection._validation import (
ImportError: cannot import name '_index_param_value' from 'sklearn.model_selection._validation' (/home/lipalab/anaconda3/lib/python3.8/site-packages/sklearn/model_selection/_validation.py)
Many thanks!!!
The classifier has been discontinued here under the main repo. We are slowly setting it back up at nipreps/mriqc-learn. I'm transferring this issue there.