-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cannot find DGL C++ graphbolt library
for torch 2.4.1
#7822
Comments
Same error, have tried all combination of versions. Would appreciate a head up if someone managed to solve this :) |
Anyone got this working yet? |
We still have this problem in new versions, has anyone fixed this problem? |
As a workaround, I was able to make import $ pip install torch==2.2.1
$ pip install torchdata==0.7.1 |
In dgl website,it says: Since 2024.06.27, we have stopped providing packages for Windows and MacOS. The latest version of available package is 2.2.1. For newer versions, please install from source.If you have installed dgl-cudaXX.X package, please uninstall it first.may be this can give you some ideas. And i also met this problem,but i need to install 2.2.1version of dgl in windows 10.it seems like i should install it from source code?If anybody knows that ,please tell me how i could solve this ,thank you so much. |
I have managed to make mine working, under the DGL package site there are several "libgraphbolt_pytorch_2.x.x.dylib" files you could find and you will know which versions of pytorch you should use. Mine issue arose from having a corrupted pytorch version registered and DGL could not properly recognize the pytorch 2.2.1 that I have installed, manually removing the corrupted pytorch files from site-packages has fixed the problem for me |
Thanks for sharing the info. Also I appreciate everyone's comment, however downgrading to It turns out dgl does ship pre-built binary here, but only for certain versions of |
I could confirm building from source following the guidance works for my Ubuntu 22.04 machine. For a CPU-only build with torch==2.4.1, python==3.12: git clone --recurse-submodules https://github.com/dmlc/dgl.git && cd dgl
bash script/create_dev_conda_env.sh -c -t 2.4.1 -p 3.12 # or other versions of your choice
bash script/build_dgl.sh -c
cd python && pip install . $ pip freeze | grep torch
torch==2.4.1+cpu
torch-geometric==2.6.1
torcheval==0.0.7
torchmetrics==1.5.1
$ pip freeze | grep dgl
dgl @ file:///home/yang/dgl/python
$ python -c "import dgl" # no error this time Worth noting is it takes quite some time to download & install the conda env (> 10 min) and a lot of RAM to build (~ 30 GB), make sure you have enough RAM otherwise you might see OOM errors. |
🐛 Bug
I believe this is a duplicate of #7247 (but for
torch
2.4.1).To Reproduce
Steps to reproduce the behavior:
Environment
conda
,pip
, source): pipAdditional context
The text was updated successfully, but these errors were encountered: