Skip to content
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

Importing torch2trt hides tracebacks from exceptions #98

Open
xsacha opened this issue Oct 5, 2019 · 7 comments
Open

Importing torch2trt hides tracebacks from exceptions #98

xsacha opened this issue Oct 5, 2019 · 7 comments

Comments

@xsacha
Copy link

xsacha commented Oct 5, 2019

Just like title. Once I import torch2trt, I no longer get tracebacks from exceptions. It just tells me 'Segmentation Fault' for simple things such as 'File not found'.
Simply removing the import fixes this.

@jaybdub
Copy link
Contributor

jaybdub commented Oct 5, 2019

Hi xsacha,

Thanks for reaching out.

I'm currently unable to reproduce this. Could you share more information regarding your system?

  1. Python version
  2. CPU/GPU

Or perhaps a minimal sample script to reproduce.

Best,
John

@xsacha
Copy link
Author

xsacha commented Oct 7, 2019

Python 3.6.8

import torch
from torch2trt import torch2trt

torch.load('file_does_not_exist.pt')

Segmentation fault

import torch

torch.load('file_does_not_exist.pt')

Traceback (most recent call last):
File "ok.py", line 3, in
torch.load('file_does_not_exist.pt')
File "/usr/local/lib/python3.6/dist-packages/torch/serialization.py", line 381, in load
f = open(f, 'rb')
FileNotFoundError: [Errno 2] No such file or directory: 'file_does_not_exist.pt'

@spolezhaev
Copy link

spolezhaev commented Oct 28, 2019

+1, the same issue. Plus Segmentation fault (core dumped) is shown after the successful running of code.

@BUAAtao
Copy link

BUAAtao commented Nov 22, 2019

I have tried the Option 1 - Without plugins and Option 2 - With plugins (experimental). It would return "Segmentation fault" when I excuted "from torch2trt import torch2trt" .

@alchemi5t
Copy link

Any updates on this?

@czs1886
Copy link

czs1886 commented May 19, 2020

My environment is Centos 7.7.1908, python: 3.6.8, Cuda 10.1.
I have successfully installed my torch2trt environment on Ubuntu and all the code can run without any problem. But when I install it on Centos, this problem occurs. There's no unknown symbol when I do ldd -r libtorchtrt.so.

@DableUTeeF
Copy link

Any update on this?

This problem is still there in the most recent version.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants