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

node.output().size() == 1 && "TensorRT does not support the indices output in MaxPool!" failure of TensorRT 8.6 when running ONNX model on GPU RTX 3090 #3761

Open
lhai37 opened this issue Apr 2, 2024 · 5 comments
Labels
triaged Issue has been triaged by maintainers

Comments

@lhai37
Copy link

lhai37 commented Apr 2, 2024

Description

I tried to run the attached ONNX model through trtexec, but it fails with the error: node.output().size() == 1 && "TensorRT does not support the indices output in MaxPool!". This is because MaxPool is being used in the model to produce 2 outputs: the values and indices. Upon checking the officially supported ONNX operators I see that MaxPool layer with indices output is not supported even in TensorRT 10 EA. Is there any plan to support this or workaround for this issue?

Environment

TensorRT Version: 8.6

NVIDIA GPU: RTX 3090

NVIDIA Driver Version: 545

CUDA Version: 11.6

CUDNN Version: 8.8

Operating System: Ubuntu 20.04 64-bit

Python Version (if applicable):

Tensorflow Version (if applicable):

PyTorch Version (if applicable):

Baremetal or Container (if so, version):

Relevant Files

Model link: https://drive.google.com/file/d/1ZvhQiG9NT92CbVK7oAznBR_rAlF5AzzF/view?usp=sharing

Steps To Reproduce

Run trtexec --onnx=model.onnx

Commands or scripts: Run trtexec --onnx=model.onnx

Have you tried the latest release?: N/A

Can this model run on other frameworks? N/A

@lix19937
Copy link

lix19937 commented Apr 2, 2024

ref
https://docs.nvidia.com/deeplearning/tensorrt/operators/docs/Pooling.html https://docs.nvidia.com/deeplearning/tensorrt/api/python_api/infer/Graph/Layers.html#ipoolinglayer

Computes a per-channel pooling using a sampling window on the input tensor into an output tensor. The supported sampling window shapes are 2-D or 3-D.
If you need 2 outputs of pooling layer, i think for now you’d need to use a plugin.

@lhai37
Copy link
Author

lhai37 commented Apr 2, 2024

Is there any existing plugin for MaxPool with 2 outputs? I looked through the default plugins that are shipped with TensorRT and didn't see any there, but perhaps someone has already created this elsewhere.

@lix19937
Copy link

lix19937 commented Apr 2, 2024

You can write a custom plugin by yourself.

@zerollzeng zerollzeng added the triaged Issue has been triaged by maintainers label Apr 4, 2024
@bs1119
Copy link

bs1119 commented Aug 2, 2024

Is there any existing plugin for MaxPool with 2 outputs? I looked through the default plugins that are shipped with TensorRT and didn't see any there, but perhaps someone has already created this elsewhere.

Were you able to solve the issue? If so, can you please share the plugin? Thanks.

@lix19937
Copy link

lix19937 commented Aug 3, 2024

You can upload your torch network code fragment about maxpool.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
triaged Issue has been triaged by maintainers
Projects
None yet
Development

No branches or pull requests

4 participants