Skip to content

✨[Feature] A CLI arg to load torch custom op libraries for compilation #877

Closed
@narendasan

Description

@narendasan

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

Right now compilation will fail with torchtrtc if you use custom operators, i.e. ops defined by libraries other than torch. This is because the PyTorch operator registry is missing information about these operators and so when trying to deserialize, TorchScript does not know what to do

This includes torchvision and torch_squeeze (#876 )

Describe the solution you'd like

Be able to add paths to .so files that need to be DL_OPEN before compilation so that custom ops are available for deserialization.

Describe alternatives you've considered

Right now the work around is to use C++ or Python with the libraries imported by the user

Additional context

Metadata

Metadata

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions