-
Notifications
You must be signed in to change notification settings - Fork 293
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
AttributeError: module 'torchsparse_backend' has no attribute 'hash_forward' #21
Comments
I encountered nearly the same problem here. And I highly doubted that it should come from a mismatch in version. Can the version for each required package be specified according to your environment? |
Please refer to the version information I posted here. I'll get back to this problem once CVPR is over in the next week. |
Oh.Thanks a lot.I will try to udpate each packages version.Hope that is useful. |
I've added support for the new APIs in |
thanks for your advice.Finally,I solve this problem,but another erro happened. Is it the cuda version erro?My environment cuda == 10.2 ;GPU driver version == 465.27 |
This should be an environment problem. Maybe you can take a look at this reply. You can also try to reinstall the |
Hi Jiaming, I was using torch sparse 1.4.0, and it can be imported. But I ran into a similar but slightly different bug. Do you have any suggestions about this? AttributeError: module 'torchsparse.backend' has no attribute 'hash_cuda' Traceback (most recent call last): |
I've tried to recreate a new conda environment from scratch but I cannot reproduce this issue on my side. Since this is very likely to be a problem of |
this fixed my problem, thx a lot!! |
Hello,I'm sorry to have taken so long to get back to you.Recently,I've installed the system and configurate environment again,but this error is still display(I don't know how to reopen the past issue,so I create a new one.I feel sorry about that):
2021-06-05 15:28:46.856 | INFO | main::35 - Found SyncedPoses.txt, skipping data pre-processing...
2021-06-05 15:28:46.856 | INFO | main::37 - Running NeuralRecon...
2021-06-05 15:28:46.874 | INFO | main::50 - Initializing the model on GPU...
2021-06-05 15:28:50.821 | INFO | main::58 - Resuming from ./checkpoints/model_000047.ckpt
2021-06-05 15:28:51.211 | INFO | main::64 - Start inference..
0%| | 0/110 [00:00<?, ?it/s]/home/u/Documents/NeuralRecon-master/ops/back_project.py:29: UserWarning: This overload of nonzero is deprecated:
nonzero(Tensor input, *, Tensor out)
Consider using one of the following signatures instead:
nonzero(Tensor input, *, bool as_tuple) (Triggered internally at /opt/conda/conda-bld/pytorch_1595629427478/work/torch/csrc/utils/python_arg_parser.cpp:766.)
batch_ind = torch.nonzero(coords[:, 0] == batch).squeeze(1)
0%| | 0/110 [00:00<?, ?it/s]
Traceback (most recent call last):
File "demo.py", line 76, in
outputs, loss_dict = model(sample, save_scene)
File "/home/u/anaconda3/envs/neucon/lib/python3.7/site-packages/torch/nn/modules/module.py", line 722, in _call_impl
result = self.forward(*input, **kwargs)
File "/home/u/anaconda3/envs/neucon/lib/python3.7/site-packages/torch/nn/parallel/data_parallel.py", line 153, in forward
return self.module(*inputs[0], **kwargs[0])
File "/home/u/anaconda3/envs/neucon/lib/python3.7/site-packages/torch/nn/modules/module.py", line 722, in _call_impl
result = self.forward(*input, **kwargs)
File "/home/u/Documents/NeuralRecon-master/models/neuralrecon.py", line 82, in forward
outputs, loss_dict = self.neucon_net(features, inputs, outputs)
File "/home/u/anaconda3/envs/neucon/lib/python3.7/site-packages/torch/nn/modules/module.py", line 722, in _call_impl
result = self.forward(*input, **kwargs)
File "/home/u/Documents/NeuralRecon-master/models/neucon_network.py", line 157, in forward
feat = self.sp_convsi
File "/home/u/anaconda3/envs/neucon/lib/python3.7/site-packages/torch/nn/modules/module.py", line 722, in _call_impl
result = self.forward(*input, **kwargs)
File "/home/u/Documents/NeuralRecon-master/models/modules.py", line 147, in forward
x0 = initial_voxelize(z, self.pres, self.vres)
File "/home/u/Documents/NeuralRecon-master/ops/torchsparse_utils.py", line 19, in initial_voxelize
pc_hash = spf.sphash(torch.floor(new_float_coord).int())
File "/home/u/anaconda3/envs/neucon/lib/python3.7/site-packages/torchsparse/nn/functional/hash.py", line 39, in sphash
return HashGPU.apply(idx)
File "/home/u/anaconda3/envs/neucon/lib/python3.7/site-packages/torchsparse/nn/functional/hash.py", line 11, in forward
return torchsparse_backend.hash_forward(idx.contiguous())
AttributeError: module 'torchsparse_backend' has no attribute 'hash_forward'
I'm sure torchsparse is correctly installed and compilation by the end of the installation is succeeded.Is this casused by a mismatch between the torch version and the torchsparse version?
my pytorch = 1.6.0;torchvision == 0.7.0
The text was updated successfully, but these errors were encountered: