No module named 'xxx’

这个问题CSDN有人解答过,链接为:https://blog.csdn.net/damotiansheng/article/details/43916881以及:https://blog.csdn.net/destinyuan/article/details/45640447或者

python -m pip install 缺少的模块

这里我要说的是安装setup.py文件后出现的no module named xxx问题。

例:安装的setup.py文件内容如下:


而pydm目录下的内容为:


当运行时可能会出现no module named trainset问题,所以这个时候需要将trainset写入setup.py中重新安装(记得要卸载已经安装的重安装)

写入:


卸载重安装

python2 -m pip uninstall xxx#(xxx表示安装的)
python2 setup.py install

猜你喜欢

转载自blog.csdn.net/mr_cat123/article/details/80449836
今日推荐