当前位置:网站首页>Moment Pool Cloud quickly installs packages such as torch-sparse and torch-geometric
Moment Pool Cloud quickly installs packages such as torch-sparse and torch-geometric
2022-07-31 04:56:00 【Machine learning is the devil】
Rent a machine and choose an environment according to the environment you need. I chose Pytorch 1.10 here.

Click the Jupyterlab link on the rental page after the rental is successful.

Create a new Terminal in Jupyterlab to install the environment. First check the Pytorch and CUDA versions. You can see my environment Pytorch 1.10.0 and CUDA 11.3 as shown below.

Next install torch-scatter torch-sparse torch-cluster torch-spline-conv torch-geometric packages.
- The official installation method provided by PyG (there will be errors in some torch versions):
pip install torch-scatter torch-sparse torch-cluster torch-spline-conv torch-geometric -f https://data.pyg.org/whl/torch-{version}+cu{version}.html
The torch and cuda versions in the official source link need to be changed to the corresponding ones in their own server environment.
https://data.pyg.org/whl/torch-{version}+cu{version}.htmlSuch as CUDA11.3 Pytorch1.10.0 corresponding link: https://data.pyg.org/whl/torch-1.10.0+cu113.htmlThere may be problems with the official installation method: If the version of the package is not specified during pip installation, the latest version will be installed by default. Take CUDA11.3 Pytorch1.10.0 as an example to install torch-sparse, fromOfficial sourceYou can see that the latest version of torch-sparse is 0.6.13, but the machine defaultsThe latest version in the source is: 0.6.14, so even if we specify the -f parameter during the installation process, pip will choose to install the updated 0.6.14 from the default source (error-prone, also need to compile, very troublesome).
- Our suggested installation method:
When installing torch-sparse, specify the version and the official source address, so that the installation will be installed from the official source download package. The official source is the whl installation package that has been compiled in the corresponding environment, which can avoid the compilation process., the installation is faster, and there are no unnecessary errors.
Get the following installation instructions (note that I am CUDA11.3 Pytorch1.10.0, if you have other versions, please change the torch and cuda versions in the official source to their corresponding ones):
pip install torch-scatter torch-sparse==0.6.13 torch-cluster torch-spline-conv -f https://data.pyg.org/whl/torch-1.10.0+cu113.htmlAfter the installation is complete, install torch-geometric, torch-geometric is not in the official source, so just pip install it directly:
pip install torch-geometricNote: If there is a version requirement, you can specify the version during installation, which will make the installation easier.
After the above installation is complete, the relevant packages can be successfully imported.

Specific use reference: official documentation
边栏推荐
- SQL行列转换
- Unity shader forge和自带的shader graph,有哪些优缺点?
- MySQL事务隔离级别详解
- STM32HAL库修改Hal_Delay为us级延时
- 开源汇智创未来 | 2022开放原子全球开源峰会OpenAtom openEuler分论坛圆满召开
- MySQL fuzzy query can use INSTR instead of LIKE
- MySQL optimization: from ten seconds to three hundred milliseconds
- 信息系统项目管理师核心考点(五十五)配置管理员(CMO)的工作
- DVWA靶场环境搭建
- mysql数据库安装(详细)
猜你喜欢

【R语言】【3】apply,tapply,lapply,sapply,mapply与par函数相关参数

The idea project obviously has dependencies, but the file is not displayed, Cannot resolve symbol 'XXX'

DVWA安装教程(懂你的不懂·详细)

ERROR 1819 (HY000) Your password does not satisfy the current policy requirements

mysql使用on duplicate key update批量更新数据

开源汇智创未来 | 2022开放原子全球开源峰会OpenAtom openEuler分论坛圆满召开

ERP生产作业控制 金蝶

信息系统项目管理师核心考点(五十五)配置管理员(CMO)的工作

npm、nrm两种方式查看源和切换镜像

The Vue project connects to the MySQL database through node and implements addition, deletion, modification and query operations
随机推荐
从零开始,一镜到底,纯净系统搭建除草机(Grasscutter)
MySQL开窗函数
110道 MySQL面试题及答案 (持续更新)
Numpy中np.meshgrid的简单用法示例
Mysql应用安装后找不到my.ini文件
centos7安装mysql5.7步骤(图解版)
ABC D - Distinct Trio (Number of k-tuples
Unity框架设计系列:Unity 如何设计网络框架
【wpf】wpf中的那些模板之深度解析
STM32HAL library modifies Hal_Delay to us-level delay
STM32 - DMA
VScode+ESP32 quickly install ESP-IDF plugin
打造基于ILRuntime热更新的组件化开发
WeChat applet uses cloud functions to update and add cloud database nested array elements
Mysql application cannot find my.ini file after installation
.NET-9. A mess of theoretical notes (concepts, ideas)
开放原子开源基金会秘书长孙文龙 | 凝心聚力,共拓开源
MySQL常见面试题汇总(建议收藏!!!)
Minesweeper game - C language
[debug highlights] Expected input batch_size (1) to match target batch_size (0)