I was curious to know if anyone know how I could serialize a jit graph into something that we can visualize. I am currently using graph->dump() and node->dump()'s to debug. I wanted to know how we could visualize the graph.
You can print out the graph as valid Python code with
my_module.code. We used to have a helper to turn a
Graph into a visualization via GraphViz, but it wasn’t maintained and was deleted.
Thanks. I used .graph and .code to look at the graph. But wanted to get something more visual :). I hadn’t seen the helper. I also have a interesting case. I want to use this from the C++ side . Is there a similar dump function that can be invoked from C++ side or do we need to write one.
We don’t have anything like that for C++ and probably won’t (it’s outside of our scope), but you should have all the tools / APIs for
Node to make something for your own purposes.