安装torch==1.8.0+cu111 torch-scatter torch-cluster、sparse、geometric

首先安装torch == 1.8.1+cu111

pip install torch==1.8.1+cu111 torchvision==0.9.1+cu111 torchaudio==0.8.1 -f https://download.pytorch.org/whl/torch_stable.html

然后再安装其他库

pip install torch-scatter==2.0.6 -f https://data.pyg.org/whl/torch-1.8.1+cu111.html
pip install torch-sparse==0.6.9 -f https://data.pyg.org/whl/torch-1.8.1+cu111.html
pip install torch-cluster==1.5.9 -f https://data.pyg.org/whl/torch-1.8.1+cu111.html
pip install torch-geometric==1.6.3

创建demo.py

echo "import torch
import torch_scatter
import torch_sparse
import torch_cluster
import torch_spline_conv
import torch_geometric

def print_version(module, name):
    try:
        print(f'{name} version: {module.__version__}')
    except AttributeError:
        print(f'{name} version could not be determined.')

def main():
    print_version(torch, 'torch')
    print_version(torch_scatter, 'torch-scatter')
    print_version(torch_sparse, 'torch-sparse')
    print_version(torch_cluster, 'torch-cluster')
    print_version(torch_spline_conv, 'torch-spline-conv')
    print_version(torch_geometric, 'torch-geometric')

if __name__ == '__main__':
    main()
" > demo.py

  • 2
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 打赏
    打赏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

思量.

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值