Skip to content
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view

@justinchuby justinchuby Jul 30, 2025 •

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe call the module just patching, for simplicity, and move it into the onnx exporter directory?

@justinchuby justinchuby Jul 30, 2025 •

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can then do

with optimum.exporters.onnx.patching.patch_xxx():
    …

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wanted to keep onnx-diagnostic patches independently, so we can have more flexibility when it comes to TS deprecation and exporter updates.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you say more about the flexibility? What flexibility do we loose or gain with either option?

@titaiwangms titaiwangms Jul 30, 2025 •

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For me, it's like building new things under the legacy folders (for example, building dynamo exporter under torchscript exporter folders.). When TS exporter is removed, we can just delete onnx/exporters without further checking it. Same logic goes to model_patcher.py, mixing them up increases the maintain complexity.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds good thanks. I do want to make sure the api we create can stay for a long time so we need to be careful about naming and where we expose them.

Empty file.
Loading