You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tvm.apache.org by GitBox <gi...@apache.org> on 2022/02/27 19:05:40 UTC

[GitHub] [tvm] chiwwang opened a new pull request #10400: [Relay] RelayViz graphviz renderer

chiwwang opened a new pull request #10400:
URL: https://github.com/apache/tvm/pull/10400


   Following https://github.com/apache/tvm/pull/10085, this PR adds a graphviz backend.
   It requires python `graphviz` package and `dot` executable in the PATH, similar to `tedd.py`.
   
   This implementation is a porting of `visualize` function in
   https://tvm.apache.org/2020/07/14/bert-pytorch-tvm, plus a callback `get_node_attr`.
   
   `get_node_attr` return specific graphviz-attributes for the node.
   It might be useful if we want to emphasize some nodes with certain types and attributes.
   
   An example is provided in
   https://github.com/chiwwang/tvm/blob/graphviz_renderer_example/test_viz.py
   
   Its outputs are:
   https://github.com/chiwwang/tvm/blob/graphviz_renderer_example/mod_with_subgraph.pdf
   https://github.com/chiwwang/tvm/blob/graphviz_renderer_example/mod_wo_subgraph.pdf
   Note that `nn.conv2d` with NCHW layout is green-colored.
   
   
   
   Thanks for contributing to TVM!   Please refer to guideline https://tvm.apache.org/docs/contribute/ for useful information and tips. After the pull request is submitted, please request code reviews from [Reviewers](https://github.com/apache/incubator-tvm/blob/master/CONTRIBUTORS.md#reviewers) by @ them in the pull request thread.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@tvm.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [tvm] comaniac edited a comment on pull request #10400: [Relay] RelayViz graphviz renderer

Posted by GitBox <gi...@apache.org>.
comaniac edited a comment on pull request #10400:
URL: https://github.com/apache/tvm/pull/10400#issuecomment-1055989494


   I just realized that we haven't updated the doc website for a while so this tutorial is even not there yet 😂\
   
   UPDATE: I just updated the TVM site based on the main branch commit b55997d


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@tvm.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [tvm] masahi commented on pull request #10400: [Relay] RelayViz graphviz renderer

Posted by GitBox <gi...@apache.org>.
masahi commented on pull request #10400:
URL: https://github.com/apache/tvm/pull/10400#issuecomment-1054976901


   Ok let's defer doc change to a follow-up and let @chiwwang continue.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@tvm.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [tvm] comaniac commented on pull request #10400: [Relay] RelayViz graphviz renderer

Posted by GitBox <gi...@apache.org>.
comaniac commented on pull request #10400:
URL: https://github.com/apache/tvm/pull/10400#issuecomment-1055989494


   I just realized that we haven't updated the doc website for a while so this tutorial is even not there yet 😂


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@tvm.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [tvm] chiwwang commented on pull request #10400: [Relay] RelayViz graphviz renderer

Posted by GitBox <gi...@apache.org>.
chiwwang commented on pull request #10400:
URL: https://github.com/apache/tvm/pull/10400#issuecomment-1054949620


   > would you add this rendering approach to the document as well?
   
   @comaniac Yes, it is already added in [contrib.rst](https://github.com/apache/tvm/pull/10400/files#diff-f32a6f55937730c6fd305bbad078c177735c6d03089386c66caeb66b463d2a5bR100).
   I wrote an example in [class DotPlotter](https://github.com/apache/tvm/pull/10400/files#diff-9dab85eb1299554c3e8adfff7f732c811f1f206e56b2261672f83c271376199dR142), which would be rendered by Sphinx. 
   
   But I didn't write this in tutorial, only added [one comment](https://github.com/apache/tvm/pull/10400/files#diff-9dab85eb1299554c3e8adfff7f732c811f1f206e56b2261672f83c271376199dR142). `graphviz` seems to be optional for TVM so I am not sure whether it's suitable to add in codes that will be run when building doc. (If it's ok then I can add some sections to the tutorial latter.)
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@tvm.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [tvm] masahi merged pull request #10400: [Relay] RelayViz graphviz renderer

Posted by GitBox <gi...@apache.org>.
masahi merged pull request #10400:
URL: https://github.com/apache/tvm/pull/10400


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@tvm.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org