Skip to content

Conversation

titaiwangms
Copy link
Collaborator

@titaiwangms titaiwangms commented Jul 27, 2023

Stack from ghstack (oldest at bottom):

The official move of OnnxRegistry to torch.onnx allows it to become one of the parameters in torch.onnx.ExportOption. By incorporating OnnxRegistry in torch.onnx.ExportOption, users gain access to various functionalities, including the ability to register custom operators using register_custom_op, check whether an operator is supported using is_registered_op, and obtain symbolic functions that support specific operators using get_functions.

Additionally, opset_version is now exclusively available in torch.onnx.OnnxRegistry as it is removed from torch.onnx.ExportOption. The initialization of the registry with torchlib under the provided opset version ensures that the exporter uses the specified opset version as the primary version for exporting.

These changes encompass scenarios where users can:

  1. Register an unsupported ATen operator with a custom implementation using onnx-script.
  2. Override an existing symbolic function (onnx invariant).

NOTE: The custom registered function will be prioritized in onnx dispatcher, and if there are multiple custom ones, the one registered the last will be picked.

@pytorch-bot
Copy link

pytorch-bot bot commented Jul 27, 2023

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/106140

Note: Links to docs will display an error until the docs builds have been completed.

⏳ No Failures, 3 Pending

As of commit e5fd932:
💚 Looks good so far! There are no failures yet. 💚

This comment was automatically generated by Dr. CI and updates every 15 minutes.

@pytorch-bot pytorch-bot bot added the release notes: onnx torch.onnx related changes that should show up in the release notes label Jul 27, 2023
@titaiwangms titaiwangms marked this pull request as draft July 27, 2023 15:53
titaiwangms added a commit that referenced this pull request Jul 27, 2023
ghstack-source-id: bb96c82
Pull Request resolved: #106140
@titaiwangms titaiwangms added the module: onnx Related to torch.onnx label Jul 28, 2023
titaiwangms added a commit that referenced this pull request Jul 28, 2023
ghstack-source-id: 30f4dee
Pull Request resolved: #106140
@titaiwangms titaiwangms added the topic: new features topic category label Jul 28, 2023
titaiwangms added a commit that referenced this pull request Jul 29, 2023
ghstack-source-id: 750d47d
Pull Request resolved: #106140
@titaiwangms titaiwangms marked this pull request as ready for review July 29, 2023 03:38
@titaiwangms titaiwangms requested a review from jeffdaily as a code owner July 29, 2023 03:38
@titaiwangms titaiwangms removed the request for review from jeffdaily July 29, 2023 23:42
The official move of `OnnxRegistry` to `torch.onnx` allows it to become one of the parameters in `torch.onnx.ExportOption`. By incorporating `OnnxRegistry` in `torch.onnx.ExportOption`, users gain access to various functionalities, including the ability to register custom operators using `register_custom_op`, check whether an operator is supported using `is_registered_op`, and obtain symbolic functions that support specific operators using `get_functions`.

Additionally, `opset_version` is now exclusively available in `torch.onnx.OnnxRegistry` as it is removed from `torch.onnx.ExportOption`. The initialization of the registry with torchlib under the provided opset version ensures that the exporter uses the specified opset version as the primary version for exporting.

These changes encompass scenarios where users can:

1. Register an unsupported ATen operator with a custom implementation using onnx-script.
2. Override an existing symbolic function (onnx invariant).

[ghstack-poisoned]
titaiwangms added a commit that referenced this pull request Jul 29, 2023
ghstack-source-id: a2e0e0c
Pull Request resolved: #106140
The official move of `OnnxRegistry` to `torch.onnx` allows it to become one of the parameters in `torch.onnx.ExportOption`. By incorporating `OnnxRegistry` in `torch.onnx.ExportOption`, users gain access to various functionalities, including the ability to register custom operators using `register_custom_op`, check whether an operator is supported using `is_registered_op`, and obtain symbolic functions that support specific operators using `get_functions`.

Additionally, `opset_version` is now exclusively available in `torch.onnx.OnnxRegistry` as it is removed from `torch.onnx.ExportOption`. The initialization of the registry with torchlib under the provided opset version ensures that the exporter uses the specified opset version as the primary version for exporting.

These changes encompass scenarios where users can:

1. Register an unsupported ATen operator with a custom implementation using onnx-script.
2. Override an existing symbolic function (onnx invariant).

NOTE: The custom registered function will be prioritized in onnx dispatcher, and if there are multiple custom ones, the one registered the last will be picked.

[ghstack-poisoned]
The official move of `OnnxRegistry` to `torch.onnx` allows it to become one of the parameters in `torch.onnx.ExportOption`. By incorporating `OnnxRegistry` in `torch.onnx.ExportOption`, users gain access to various functionalities, including the ability to register custom operators using `register_custom_op`, check whether an operator is supported using `is_registered_op`, and obtain symbolic functions that support specific operators using `get_functions`.

Additionally, `opset_version` is now exclusively available in `torch.onnx.OnnxRegistry` as it is removed from `torch.onnx.ExportOption`. The initialization of the registry with torchlib under the provided opset version ensures that the exporter uses the specified opset version as the primary version for exporting.

These changes encompass scenarios where users can:

1. Register an unsupported ATen operator with a custom implementation using onnx-script.
2. Override an existing symbolic function (onnx invariant).

NOTE: The custom registered function will be prioritized in onnx dispatcher, and if there are multiple custom ones, the one registered the last will be picked.

[ghstack-poisoned]
titaiwangms added a commit that referenced this pull request Aug 2, 2023
ghstack-source-id: 004825a
Pull Request resolved: #106140
The official move of `OnnxRegistry` to `torch.onnx` allows it to become one of the parameters in `torch.onnx.ExportOption`. By incorporating `OnnxRegistry` in `torch.onnx.ExportOption`, users gain access to various functionalities, including the ability to register custom operators using `register_custom_op`, check whether an operator is supported using `is_registered_op`, and obtain symbolic functions that support specific operators using `get_functions`.

Additionally, `opset_version` is now exclusively available in `torch.onnx.OnnxRegistry` as it is removed from `torch.onnx.ExportOption`. The initialization of the registry with torchlib under the provided opset version ensures that the exporter uses the specified opset version as the primary version for exporting.

These changes encompass scenarios where users can:

1. Register an unsupported ATen operator with a custom implementation using onnx-script.
2. Override an existing symbolic function (onnx invariant).

NOTE: The custom registered function will be prioritized in onnx dispatcher, and if there are multiple custom ones, the one registered the last will be picked.

[ghstack-poisoned]
@titaiwangms titaiwangms added the ciflow/trunk Trigger trunk jobs on your pull request label Aug 4, 2023
The official move of `OnnxRegistry` to `torch.onnx` allows it to become one of the parameters in `torch.onnx.ExportOption`. By incorporating `OnnxRegistry` in `torch.onnx.ExportOption`, users gain access to various functionalities, including the ability to register custom operators using `register_custom_op`, check whether an operator is supported using `is_registered_op`, and obtain symbolic functions that support specific operators using `get_functions`.

Additionally, `opset_version` is now exclusively available in `torch.onnx.OnnxRegistry` as it is removed from `torch.onnx.ExportOption`. The initialization of the registry with torchlib under the provided opset version ensures that the exporter uses the specified opset version as the primary version for exporting.

These changes encompass scenarios where users can:

1. Register an unsupported ATen operator with a custom implementation using onnx-script.
2. Override an existing symbolic function (onnx invariant).

NOTE: The custom registered function will be prioritized in onnx dispatcher, and if there are multiple custom ones, the one registered the last will be picked.

[ghstack-poisoned]
titaiwangms added a commit that referenced this pull request Aug 4, 2023
ghstack-source-id: b650362
Pull Request resolved: #106140
@titaiwangms
Copy link
Collaborator Author

I will have another PR to address, if there is any, other comments.

@titaiwangms
Copy link
Collaborator Author

@pytorchbot merge

@pytorchmergebot
Copy link
Collaborator

Merge started

Your change will be merged once all checks pass (ETA 0-4 Hours).

Learn more about merging in the wiki.

Questions? Feedback? Please reach out to the PyTorch DevX Team

Advanced Debugging
Check the merge workflow status
here

titaiwangms added a commit to microsoft/onnxruntime that referenced this pull request Aug 7, 2023
Update the usage of torch.onnx.OnnxRegistry, as it's officially
published in PyTorch: pytorch/pytorch#106140.

---------

Co-authored-by: Wei-Sheng Chin <[email protected]>
@facebook-github-bot facebook-github-bot deleted the gh/titaiwangms/38/head branch August 8, 2023 14:16
jchen351 pushed a commit to microsoft/onnxruntime that referenced this pull request Aug 12, 2023
Update the usage of torch.onnx.OnnxRegistry, as it's officially
published in PyTorch: pytorch/pytorch#106140.

---------

Co-authored-by: Wei-Sheng Chin <[email protected]>
Cyril-Anto pushed a commit to Cyril-Anto/pytorch that referenced this pull request Aug 17, 2023
The official move of `OnnxRegistry` to `torch.onnx` allows it to become one of the parameters in `torch.onnx.ExportOption`. By incorporating `OnnxRegistry` in `torch.onnx.ExportOption`, users gain access to various functionalities, including the ability to register custom operators using `register_custom_op`, check whether an operator is supported using `is_registered_op`, and obtain symbolic functions that support specific operators using `get_functions`.

Additionally, `opset_version` is now exclusively available in `torch.onnx.OnnxRegistry` as it is removed from `torch.onnx.ExportOption`. The initialization of the registry with torchlib under the provided opset version ensures that the exporter uses the specified opset version as the primary version for exporting.

These changes encompass scenarios where users can:

1. Register an unsupported ATen operator with a custom implementation using onnx-script.
2. Override an existing symbolic function (onnx invariant).

NOTE: The custom registered function will be prioritized in onnx dispatcher, and if there are multiple custom ones, the one registered the last will be picked.
Pull Request resolved: pytorch#106140
Approved by: https://github.com/justinchuby, https://github.com/thiagocrepaldi
kleiti pushed a commit to kleiti/onnxruntime that referenced this pull request Mar 22, 2024
Update the usage of torch.onnx.OnnxRegistry, as it's officially
published in PyTorch: pytorch/pytorch#106140.

---------

Co-authored-by: Wei-Sheng Chin <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ciflow/trunk Trigger trunk jobs on your pull request Merged module: onnx Related to torch.onnx open source release notes: onnx torch.onnx related changes that should show up in the release notes topic: new features topic category
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

6 participants