Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CircleGraph] Support onnx #1659

Merged
merged 1 commit into from
Sep 20, 2023
Merged

[CircleGraph] Support onnx #1659

merged 1 commit into from
Sep 20, 2023

Conversation

glistening
Copy link
Contributor

Now, CircleGraph can show onnx.

onnx.js, onnx-proto.js and onnx-metadata.json are copied from original netron r5.2.1.

To avoid name conflicts with others (e.g. tflite, circle), all occurrences of $root are replaced with onnx_root from onnx-proto.js.

ONE-vscode-DCO-1.0-Signed-off-by: Sanggyu Lee [email protected]

Now, CircleGraph can show onnx.

onnx.js, onnx-proto.js and  onnx-metadata.json are copied from original
netron r5.2.1.

To avoid name conflicts with others (e.g. tflite, circle), all occurrences
of `$root` are replaced with `onnx_root` from onnx-proto.js.

ONE-vscode-DCO-1.0-Signed-off-by: Sanggyu Lee <[email protected]>
Copy link
Contributor

@dayo09 dayo09 left a comment

Choose a reason for hiding this comment

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

It works very well :-D Thanks.

Copy link
Collaborator

@jyoungyun jyoungyun left a comment

Choose a reason for hiding this comment

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

LGTM

@dayo09 dayo09 merged commit 5b5b428 into Samsung:main Sep 20, 2023
10 checks passed
@glistening
Copy link
Contributor Author

Just for recording, I add more explanation why I chosen onnx-* from r5.2.1.

In short, the latest onnx-* does not work with old one in CircleGraph.
view.Parameter is renamed to Argument and there is no more getter arguments().
It makes trouble while accessing arguments. For example,

media/CircleGraph/view.js

  renderGraph(model, graph) {
        ...
        const rotate = graph.nodes.every(
          (node) =>
            node.inputs.filter((input) =>
              input.arguments.every((argument) => !argument.initializer)
            ).length === 0 && node.outputs.length === 0
        );

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants