異常信息:
Retrying (Retry(total=2, connect=None, read=None, redirect=None)) after connection broken by ‘ReadTimeoutError(“HTTPSConnectionPool(host=’pypi.python.org’, port=443): Read timed out. (read timeout=15)”,)’: /simple/scipy/
通過pip安裝scipy、scikit-learn等庫的時候,可能會報上面的錯誤,國內通過翻牆手段,是可能解決該問題的。下面給個不用翻牆的辦法。
以下載pandas爲例,終端輸入命令(前提是python正確安裝):
pip install --index https://pypi.mirrors.ustc.edu.cn/simple/ pandas
注:--index後面也可以換成別的鏡像,比如http://mirrors.sohu.com/python/