Skip to content

✨[Feature] Provide missing operators for YoloR #781

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

Closed
rodja opened this issue Dec 21, 2021 · 3 comments
Closed

✨[Feature] Provide missing operators for YoloR #781

rodja opened this issue Dec 21, 2021 · 3 comments
Assignees
Labels
feature request New feature or request No Activity

Comments

@rodja
Copy link

rodja commented Dec 21, 2021

Is your feature request related to a problem? Please describe.

While compiling YOLOR, Torch-TensorRT reports the following missing opperators:

  • aten::Int.Tensor(Tensor a) -> (int)
  • aten::div.Tensor_mode(Tensor self, Tensor other, *, str? rounding_mode) -> (Tensor)
  • prim::PythonOp(...) -> (...)

Describe the solution you'd like

I would like these converters to be available in Torch-TensorRT so I can run YoloR inferences.

Describe alternatives you've considered

I tried executing this operations with Torch instead of TensorRT by calling

ttrt_module = torch_tensorrt.compile(
    model,
    inputs=inputs,
    enabled_precisions=enabled_precisions,
    require_full_compilation=False,
    torch_executed_ops=['aten::Int', 'aten::div', 'prim::PythonOp'],
)

But the errors remained.

@rodja rodja added the feature request New feature or request label Dec 21, 2021
@rodja
Copy link
Author

rodja commented Dec 21, 2021

It looks like aten::Int.Tensor(Tensor a) is not so easy to implement: #513

@narendasan
Copy link
Collaborator

narendasan commented Dec 21, 2021

Yeah we are working on a solution for aten::Int. The suggestion here is to try to help torchscript here with explicit casting if possible for now. We can work on aten::div.Tensor_mode. prim::PythonOp I dont think we can support. Partial compilation would be the only option here

@github-actions
Copy link

This issue has not seen activity for 90 days, Remove stale label or comment or this will be closed in 10 days

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request New feature or request No Activity
Projects
None yet
Development

No branches or pull requests

2 participants