TensorRT icon indicating copy to clipboard operation
TensorRT copied to clipboard

Implement embedding bag convertor

Open Christina-Young-NVIDIA opened this issue 1 year ago • 5 comments

Christina-Young-NVIDIA avatar Sep 25 '23 20:09 Christina-Young-NVIDIA

https://docs.nvidia.com/deeplearning/tensorrt/developer-guide/index.html#work-with-loops https://github.com/pytorch/pytorch/blob/main/torch/nn/functional.py#L2368-L2391 https://github.com/pytorch/pytorch/issues/25469

Helpful links

narendasan avatar Jan 02 '24 22:01 narendasan

  1. 1D input with DD-offsets (ITensor) -> TensorRT logic directly (ILoop)
  2. 2D input -> flattening, generating the offsets on the fly, then running 1D and reshape
  3. Undefined 2D behavior, unclear what happens in this case in PyT

narendasan avatar Jan 02 '24 22:01 narendasan

https://github.com/pytorch/pytorch/issues/25469

narendasan avatar Jan 09 '24 22:01 narendasan

TensorRT team just replied: "There's a known bug 4411383 where a network with DDS but not DS requires an optimization profile. For that bug, the easy way to avoid it in 9.2 was to enable profile sharing (PROFILE_SHARING_0806)."

zewenli98 avatar Jan 16 '24 22:01 zewenli98

https://github.com/pytorch/pytorch/blob/8ca8729321a8c858c6bc33318ce2b80b8a5c900e/torch/onnx/symbolic_opset11.py#L1309

narendasan avatar Feb 02 '24 01:02 narendasan