ModuleNotFoundError: No module named 'six.moves.collections_abc'

ⅰ亾dé卋堺 提交于 2020-12-15 05:34:23

问题


i am just starting with machine learning i am following this tutorial from Weights&Bias where they gave us some code and asked to run it i am unable to run the code

First I was getting the error

Keras requires TensorFlow 2.2 or higher

for which I tried this method

Following the advice given here, downgrading Keras did the trick for me without having to touch any other packages. Just do:

pip install keras==2.3.0

from this link

Error "Keras requires TensorFlow 2.2 or higher"

then I started getting the error

Using TensorFlow backend.
Traceback (most recent call last):
File "perceptron-single.py", line 6, in <module>
import wandb
File "C:\Users\hp\AppData\Local\Programs\Python\Python37\lib\site-packages\wandb\__init__.py", line 37, in <module>
from wandb import sdk as wandb_sdk
File "C:\Users\hp\AppData\Local\Programs\Python\Python37\lib\site-packages\wandb\sdk\__init__.py", line 9, in <module>
from .wandb_config import Config  # noqa: F401
File "C:\Users\hp\AppData\Local\Programs\Python\Python37\lib\site-packages\wandb\sdk\wandb_config.py", line 10, in <module>
from six.moves.collections_abc import Sequence
*ModuleNotFoundError: No module named 'six.moves.collections_abc'

for which I tried this method

easy_install six

from this link

ImportError: No module named six

but it did not solve my issue


回答1:


Using this method

pip install --ignore-installed six

From the following link solved the problem for me.

ImportError: No Module named six; six already installed

Although I still don't understand about what was actually wrong and how it got fixed.



来源:https://stackoverflow.com/questions/64357732/modulenotfounderror-no-module-named-six-moves-collections-abc

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!