Pycharm导入项目遇到问题及解决办法
导入项目出现错误:
(1)pip版本太老:
WARNING: You are using pip version 20.2.1; however, version 21.0.1 is available. You should consider upgrading via the '/usr/local/python38/bin/python3.8 -m pip install --upgrade pip' command.
执行命令(很慢):python -m pip install --upgrade pip
执行命令(很快):python -m pip install --upgrade pip -i https://pypi.douban.com/simple

(2)Downloading numpy下载太慢
pip._vendor.urllib3.exceptions.ReadTimeoutError: HTTPSConnectionPool(host='files.pythonhosted.org', port=443): Read timed out.
下载很慢:pip install numpy

据说下载速度提升:pip --default-timeout=100 install numpy -i http://pypi.douban.com/simple/ --trusted-host pypi.douban.com
2020.07.22更新:如果上面那个豆瓣依然不快(虽然还没出现过这种情况),可以换成下面的国内镜像网站。
清华:https://pypi.tuna.tsinghua.edu.cn/simple 阿里云:http://mirrors.aliyun.com/pypi/simple/
中国科技大学 https://pypi.mirrors.ustc.edu.cn/simple/ 华中科技大学:http://pypi.hustunique.com/
山东理工大学:http://pypi.sdutlinux.org/ 豆瓣:http://pypi.douban.com/simple/
目前还是豆瓣的下载速度最有保障。
————————————————
版权声明:本文为CSDN博主「是杰夫呀」的原创文章,遵循CC 4.0 BY-SA版权协议,转载请附上原文出处链接及本声明。
原文链接:https://blog.csdn.net/sinat_26811377/article/details/99698807
(3)pycharm如何对JSON文件格式化
使用组合键ctrl+alt+L进行格式化。


(4)AssertionError: Torch not compiled with CUDA enabled
浙公网安备 33010602011771号