another 'Tensor' object has no attribute '_trt'
See original GitHub issueHi Trying out EfficientNet_b1 for jetson
seems like I get the following warning and error
Warning: Encountered known unsupported method torch.nn.functional.has_torch_function_variadic
Warning: Encountered known unsupported method torch.nn.functional.linear
File "model_convert.py", line 24, in <module>
model_trt = torch2trt(model, [x])
File "/usr/local/lib/python3.6/dist-packages/torch2trt-0.2.0-py3.6.egg/torch2trt/torch2trt.py", line 546, in torch2trt
File "/usr/local/lib/python3.6/dist-packages/torch2trt-0.2.0-py3.6.egg/torch2trt/torch2trt.py", line 407, in mark_outputs
AttributeError: 'Tensor' object has no attribute '_trt'
I am aware SiLU is not implemented for onnx so I have changed them to ReLU but it seems like there is another error
Issue Analytics
- State:
- Created 2 years ago
- Comments:6 (3 by maintainers)
Top Results From Across the Web
'Tensor' object has no attribute '_trt' #15 - GitHub
I get error AttributeError: 'Tensor' object has no attribute '_trt' when I meet MaxPool2d.
Read more >'Tensor' object has no attribute 'numpy' while extending keras ...
AttributeError : 'Tensor' object has no attribute 'numpy' while extending keras sequential model ; # encoders is a bunch of Dense layers encoder....
Read more >AttributeError: 'Tensor' object has no attribute '_trt'的一种可能性
1. 遇到的问题在自己搭建模型的时候,遇到了这个问题,这个问题的意思,归根结底是:keras中定义的tensor和tensorflow(theano) ...
Read more >'Tensor' object has no attribute or method 'forward' - jit
Hi everyone. I am working on the CLIP project. I am trying to parse models from it, script them and save them, but...
Read more >IExecutionContext — NVIDIA TensorRT Standard Python API ...
Trivially true if network has no dynamically shaped input tensors. ... Application-implemented error reporting interface for TensorRT objects.
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 FreeTop 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
Top GitHub Comments
Hi @ooodragon94,
I was able to convert the model by registering converters for
torch.nn.functional.silu
andtorch.nn.functional.linear
Below is the program I used to convert the model.
Please let me know if this works for you and I’ll work on a pull-request to integrate these converters into the project.
Best, John
Your explanation rocks. Thank you so much for your kind and thorough response!