[onnx2circle] Add option to list supported operators#16419
Closed
arkq wants to merge 1 commit intoSamsung:masterfrom
Closed
[onnx2circle] Add option to list supported operators#16419arkq wants to merge 1 commit intoSamsung:masterfrom
arkq wants to merge 1 commit intoSamsung:masterfrom
Conversation
There was a problem hiding this comment.
Pull request overview
This PR adds a --list-operators option to the onnx2circle tool that prints all supported ONNX operators with their opset versions. It also refactors the NodeConverterRegistry API to use a structured Operator type (a std::pair<std::string, unsigned int>) instead of separate name/opset parameters.
Changes:
- Introduces
NodeConverterRegistry::Operatortype alias and updateslookup/registerConvertersignatures accordingly - Adds
getRegisteredOperators()andgetSupportedOperators()functions to expose the list of supported ops - Adds
--list-operatorsCLI option inonnx2circle.cpp
Reviewed changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
compiler/onnx2circle/src/onnx2circle.cpp |
Adds --list-operators argument handling and help text |
compiler/mir/src/mir_onnx_importer/ONNXNodeConverterRegistry.h |
Introduces Operator type alias; updates method signatures |
compiler/mir/src/mir_onnx_importer/ONNXNodeConverterRegistry.cpp |
Implements updated signatures and new getRegisteredOperators() |
compiler/mir/src/mir_onnx_importer/ONNXOpRegistration.h |
Updates REG_CONVERTER macro to pass Operator struct |
compiler/mir/src/mir_onnx_importer/ONNXImporterImpl.cpp |
Adds getSupportedOps() and public getSupportedOperators() |
compiler/mir/include/mir_onnx_importer/ONNXImporterImpl.h |
Declares public getSupportedOperators() |
compiler/mir/src/mir_onnx_importer/ONNXNodeConverterRegistry.test.cpp |
Updates tests to new API; adds registered_ops test |
Comments suppressed due to low confidence (1)
compiler/mir/src/mir_onnx_importer/ONNXNodeConverterRegistry.test.cpp:28
- Corrected spelling of 'Regsitry' to 'Registry'.
class NodeConverterRegsitryTest : public ::testing::Test
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
mbencer
reviewed
Mar 5, 2026
mbencer
reviewed
Mar 5, 2026
This commit adds --list-operators option to the onnx2circle tool which lists all supported ONNX operators with their opset numbers. Such list should help in ONNX model operators conversion in case when converted model uses not supported operators versions. > $ onnx2circle --list-operators > AveragePool-1 > AveragePool-7 > AveragePool-10 > ... > MatMul-1 > MatMul-9 > ... ONE-DCO-1.0-Signed-off-by: Arkadiusz Bokowy <a.bokowy@samsung.com>
Contributor
Author
|
Closing this PR because the |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This commit adds
--list-operatorsoption to theonnx2circletool which lists all supported ONNX operators with their opset numbers. Such list should help in ONNX model operators conversion in case when converted model uses not supported operators versions.