我使用 miniconda 版本 4.12.0。当我使用 pip 安装时,一切都运行良好。但每当我安装一些大型软件包时cudnn
,它都无法完成下载。我不认为这是网络问题,因为下载过程在安装过程中突然停止。有人能帮我解决这个问题吗?提前谢谢您!!
以下是示例日志:
$ conda install cudnn=8.2.1
.
.
.
The following NEW packages will be INSTALLED:
cudatoolkit pkgs/main/linux-64::cudatoolkit-11.3.1-h2bc3f7f_2
cudnn pkgs/main/linux-64::cudnn-8.2.1-cuda11.3_0
Proceed ([y]/n)?
Downloading and Extracting Packages
cudnn-8.2.1 | 865.2 MB | ##############################################3 | 29%
cudatoolkit-11.3.1 | 549.3 MB | ####################################################################################4 | 52%
CondaError: Downloaded bytes did not match Content-Length
url: https://repo.anaconda.com/pkgs/main/linux-64/cudnn-8.2.1-cuda11.3_0.conda
target_path: /home/thanhtvt/miniconda3/pkgs/cudnn-8.2.1-cuda11.3_0.conda
Content-Length: 907179703
downloaded bytes: 260946309
CondaError: Downloaded bytes did not match Content-Length
url: https://repo.anaconda.com/pkgs/main/linux-64/cudatoolkit-11.3.1-h2bc3f7f_2.conda
target_path: /home/thanhtvt/miniconda3/pkgs/cudatoolkit-11.3.1-h2bc3f7f_2.conda
Content-Length: 575957943
downloaded bytes: 302037379
答案1
也许 miniconda 本身有问题,当我从anaconda
频道安装时,它运行得很好
conda install -c anaconda cudnn=8.2.1