Skip to content

🐛 [Bug] An assertion error when upgrading to enqueueV3 interface #2811

@zewenli98

Description

@zewenli98

Bug Description

https://github.com/pytorch/TensorRT/blob/main/py/torch_tensorrt/dynamo/runtime/_PythonTorchTensorRTModule.py#L63-L65

This should be:

assert (
    self.engine.num_io_tensors == len(self.input_names) + len(self.output_names)
)

because num_io_tensors is not inflated by the number of optimization profiles, for enqueueV3 interface. This is different from the enqueueV2 interface:

assert engine.num_bindings == num_io_tensors * engine.num_optimization_profiles

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions