1、确保已安装PyTorch。如果没有,使用以下命令安装适合你ARM架构的PyTorch版本:
pip install torch
2、安装torch-cluster
。由于torch-cluster
可能还没有针对M1芯片优化的wheel,需要从源码安装。使用pip
从GitHub安装最新版本的torch-cluster
:
pip install git+https://github.com/rusty1s/pytorch_cluster.git
遇到任何与依赖或兼容性有关的问题:
(1)确保你的Python环境是最新的
(2)查看torch-cluster
的GitHub仓库以获取可能的问题解决方案或特定ARM的安装说明