Closed brian220 closed 3 years ago
Hi. In that case could you please just try cloning the repository, checkout the revision 6bda19fdc57f176cb82f58d287602f4ccf4cfc23
and install using python setup.py install --cuda-ext
?
Hi, it works, I can run the code with neuralnet-pytorch now.
Thank you very much!
Hi,
I meet another error when running the training code.
AttributeError: module 'neuralnet_pytorch' has no attribute 'ext'
Training...
Traceback (most recent call last):
File "train.py", line 92, in <module>
train_valid()
File "/media/itri/Files_2TB/chaoyu/pointcloud3d/graphx-conv/graphx_venv/lib/python3.6/site-packages/gin/config.py", line 1069, in gin_wrapper
utils.augment_exception_message_and_reraise(e, err_str)
File "/media/itri/Files_2TB/chaoyu/pointcloud3d/graphx-conv/graphx_venv/lib/python3.6/site-packages/gin/utils.py", line 41, in augment_exception_message_and_reraise
raise proxy.with_traceback(exception.__traceback__) from None
File "/media/itri/Files_2TB/chaoyu/pointcloud3d/graphx-conv/graphx_venv/lib/python3.6/site-packages/gin/config.py", line 1046, in gin_wrapper
return fn(*new_args, **new_kwargs)
File "train.py", line 86, in train_valid
valid_freq=val_freq, reduce='mean')
File "/media/itri/Files_2TB/chaoyu/pointcloud3d/graphx-conv/graphx_venv/lib/python3.6/site-packages/neuralnet_pytorch-1.0.0+fancy.144.g6bda19f-py3.6-linux-x86_64.egg/neuralnet_pytorch/monitor.py", line 843, in run_training
loss = net.train_procedure(batch, *args, **kwargs)
File "/media/itri/Files_2TB/chaoyu/pointcloud3d/graphx-conv/src/networks.py", line 306, in train_procedure
loss = self.get_loss(batch, reduce, normalized)
File "/media/itri/Files_2TB/chaoyu/pointcloud3d/graphx-conv/src/networks.py", line 302, in get_loss
gt_pc) if isinstance(gt_pc, (list, tuple)) else normalized_chamfer_loss(pred_pc, gt_pc, reduce=reduce, normalized=normalized)
File "/media/itri/Files_2TB/chaoyu/pointcloud3d/graphx-conv/src/networks.py", line 301, in <listcomp>
loss = sum([normalized_chamfer_loss(pred[None], gt[None], reduce=reduce, normalized=normalized) for pred, gt in zip(pred_pc, gt_pc)]) / len(
File "/media/itri/Files_2TB/chaoyu/pointcloud3d/graphx-conv/src/networks.py", line 20, in normalized_chamfer_loss
loss = nnt.chamfer_loss(pred, gt, reduce=reduce)
File "/media/itri/Files_2TB/chaoyu/pointcloud3d/graphx-conv/graphx_venv/lib/python3.6/site-packages/neuralnet_pytorch-1.0.0+fancy.144.g6bda19f-py3.6-linux-x86_64.egg/neuralnet_pytorch/metrics.py", line 117, in chamfer_loss
from .extensions import chamfer_distance
File "/media/itri/Files_2TB/chaoyu/pointcloud3d/graphx-conv/graphx_venv/lib/python3.6/site-packages/neuralnet_pytorch-1.0.0+fancy.144.g6bda19f-py3.6-linux-x86_64.egg/neuralnet_pytorch/extensions/__init__.py", line 1, in <module>
from .dist_chamfer import chamfer_distance
File "/media/itri/Files_2TB/chaoyu/pointcloud3d/graphx-conv/graphx_venv/lib/python3.6/site-packages/neuralnet_pytorch-1.0.0+fancy.144.g6bda19f-py3.6-linux-x86_64.egg/neuralnet_pytorch/extensions/dist_chamfer.py", line 3, in <module>
import neuralnet_pytorch.ext as ext
AttributeError: module 'neuralnet_pytorch' has no attribute 'ext'
In call to configurable 'GraphX' (<function train_valid at 0x7efeddcfcbf8>)
2020-12-30 15:12:02,628 [Thread-1 ] [INFO ] Elapsed time 0.16mins run2 Epoch 1 Iteration 0/32514 (0.00%)
My environment setting
Package Version
----------------- ------------------------
cycler 0.10.0
future 0.18.2
gin-config 0.4.0
imageio 2.9.0
kiwisolver 1.3.1
matplotlib 3.0.3
neuralnet-pytorch 1.0.0+fancy.144.g6bda19f
numpy 1.19.4
Pillow 8.0.1
pip 20.3.3
protobuf 3.14.0
pyparsing 2.4.7
python-dateutil 2.8.1
scipy 1.5.4
setuptools 50.3.2
six 1.15.0
tensorboardX 2.1
torch 1.2.0
torchvision 0.4.0
wheel 0.35.1
I think I have successfully installed the right version of neuralnet-pytorch
(revision 6bda19fdc57f176cb82f58d287602f4ccf4cfc23
)
But something went wrong, could you give me some advice about this?
Thanks.
Hello.
It means you didn't successfully install the package.
Could you replace line 28 in setup.py
by ext_root = os.path.join(os.getcwd(), 'neuralnet_pytorch/extensions')
and run the setup again? This bug was fixed in 1c78fe3
.
Hi, how do you modify the version as '6bda19fdc57f176cb82f58d287602f4ccf4cfc23' ?
Hi, how do you modify the version as '6bda19fdc57f176cb82f58d287602f4ccf4cfc23' ?
I have same question, how did you deal with it?
Hi @justanhduc, Thanks for your nice implementation, I meet an error when using the command in readme
pip install "neuralnet-pytorch[gin] @ git+git://github.com/justanhduc/neuralnet-pytorch.git@6bda19fdc57f176cb82f58d287602f4ccf4cfc23" --global-option="--cuda-ext"
it said option --cuda-ext not recognizedFollowing is my environment
I can't find out the problem, thanks.