import error
See original GitHub issueEnvironment:
- ubuntu 18.04
- PyTorch 1.5.0+cpu
Run:
$ pip install torch-scatter==latest+${CUDA} -f https://pytorch-geometric.com/whl/torch-1.5.0.html
$ pip install torch-sparse==latest+${CUDA} -f https://pytorch-geometric.com/whl/torch-1.5.0.html
$ pip install torch-cluster==latest+${CUDA} -f https://pytorch-geometric.com/whl/torch-1.5.0.html
$ pip install torch-spline-conv==latest+${CUDA} -f https://pytorch-geometric.com/whl/torch-1.5.0.html
$ pip install torch-geometric
All packages are installed correctly. But when i import module
import torch
from torch_geometric.data import Data
Report Error:
RuntimeError:
Tried to access nonexistent attribute or method 'true_divide_' of type 'Tensor'.:
File "/usr/local/lib/python3.6/dist-packages/torch_scatter/scatter.py", line 53
count = broadcast(count, out, dim)
if torch.is_floating_point(out):
out.true_divide_(count)
~~~~~~~~~~~~~~~~ <--- HERE
else:
out.floor_divide_(count)
Can you help me to solve this problem ?
Issue Analytics
- State:
- Created 3 years ago
- Comments:8 (3 by maintainers)
Top Results From Across the Web
How to Fix ImportError: Cannot Import Name in Python - Rollbar
The Python ImportError: cannot import name error occurs when an imported class is not accessible or is in a circular dependency.
Read more >Python Import Error (ModuleNotFoundError) - Finxter
Python's ImportError ( ModuleNotFoundError ) indicates that you tried to import a module that Python doesn't find. It can usually be eliminated by...
Read more >Python Exception Handling: ImportError and ... - Airbrake Blog
The ImportError is raised when an import statement has trouble successfully importing the specified module. Typically, such a problem is due to ...
Read more >import error: 'No module named' *does* exist - python
I set the PYTHONPATH to '.' and that solved it for me. export PYTHONPATH='.' For a one-liner you could as easily do: PYTHONPATH='....
Read more >How to catch ImportError Exception in Python? - Tutorialspoint
ImportError is raised when a module, or member of a module, cannot be imported. There are a two conditions where an ImportError might...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Ok, I managed to work around it by specifying
pip install --no-cache-dir --find-links https://pytorch-geometric.com/whl/torch-1.5.0+cu102.html torch-scatter==2.0.5
. I find it weird because even though that’s the latest version listed inhttps://pytorch-geometric.com/whl/torch-1.5.0+cu102.html
, pip insisted in downloading 2.0.6. Hope it helps.This issue had no activity for 6 months. It will be closed in 2 weeks unless there is some new activity. Is this issue already resolved?