跑代码发现会Segmentation fault (core dumped),最后定位到是import torch_scatter导致的,但卸载torch_scatter重装也没解决。
一番折腾后意识到我刚改过gcc环境,可能这个包是要重新编译的。所以清理pip缓存后再重装torch_scatter:
pip cache purge
pip uninstall torch_scatter
pip install torch_scatter
编译时间比较久,需要等待一下。重装后问题成功解决。