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

error in component_binning.py #22

Open
heleeno opened this issue Feb 17, 2023 · 3 comments
Open

error in component_binning.py #22

heleeno opened this issue Feb 17, 2023 · 3 comments

Comments

@heleeno
Copy link

heleeno commented Feb 17, 2023

Hi,

I'm trying to run metabinner on coassembly data and it seems that I successfully created a coverage file and kmer file but I'm running into an error, see below. I have tried to remove the _ from "sklearn.cluster._kmeans" because I thought this may be the problem but I get the same error.
Do you maybe know what is going on?

Thank you, Heleen

Traceback (most recent call last):
File "./component_binning.py", line 23, in
from sklearn.cluster._kmeans import euclidean_distances, stable_cumsum, KMeans, check_random_state, row_norms, MiniBatchKMeans
ImportError: No module named _kmeans

real 0m0.888s
user 0m0.582s
sys 0m1.142s
Something went wrong with generating component binning results. Exiting.

@ziyewang
Copy link
Owner

Hi,

It seems that the version of scikit-learn in your environment is different from that we used. Could you please check the version of scikit-learn and make sure it equals 0.22.1?

Best,
Ziye

@heleeno
Copy link
Author

heleeno commented Feb 18, 2023

Hi Ziye,

Thanks for your reply. I checked and the scikit-learn version in my environment is 0.22.1. Can you think of anything else it could be?

Best,
Heleen

@ziyewang
Copy link
Owner

Hi, Heleen,

It seems that only sklearn versions older then 0.22 cannot import sklearn.cluster._kmeans. Could you please add "import sklearn" and "print(sklearn.version)" before the "from sklearn.cluster._kmeans import euclidean_distances, stable_cumsum, KMeans, check_random_state, row_norms, MiniBatchKMeans" in the component_binning.py, and test whether the code successfully calls this sklearn version (0.22.1)?

Best,
Ziye

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

2 participants