Adding tooltips to graphviz representation
See original GitHub issueWhile working on https://github.com/dask/dask/issues/7919, I was looking for ways to represent the layer_type attribute in the graphviz representation. I stumbled upon the tooltip - Tooltip (mouse hover text) attached to the node, edge, cluster, or graph.
This opens up many doors to add more information 🚀
Demo
(image shows the layer_type as the tooltip)

So, on hover, we can display any kind of information we want per Layer. We can use this discussion thread to discuss what information would benefit users when they see a Task Graph.
Idea
We can show the attributes stored in collecton_annotations in the tooltip.
- This could be
shape, dtype, chunksize, type, chunk_type(layer_typetoo) for Dask Arrays. - This could be
npartitions, columns, type, dataframe_type, series_dtypes(layer_typetoo) for Dask DataFrames. - Anything else.
Issue Analytics
- State:
- Created 2 years ago
- Comments:7 (7 by maintainers)
Top Results From Across the Web
tooltip - Graphviz
Tooltip (mouse hover text) attached to the node, edge, cluster, or graph.
Read more >Attributes - Graphviz
The tools accept standard C representations for int and double types. ... Tooltip annotation attached to the non-label part of an edge.
Read more >FAQ - Graphviz
Run neato -n . This will add the necessary edge information. I already have all the coordinates for the nodes and edges of...
Read more >Node Shapes - Graphviz
Visually, a record is a box, with fields represented by alternating ... Adding HTML labels to record-based shapes (record and Mrecord) is ...
Read more >DOT Language - Graphviz
First, a subgraph can be used to represent graph structure, indicating that certain nodes and edges should be grouped together.
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

Yes, true. The tooltips are stored in the .SVG image. If you open the SVG in a browser later, it would still possess the tooltips.
My personal preference would be
.svgif it’s easy to open on all operating systems. If it isn’t easy, then I’d prefer.pngto match the default format used to save the low level graph visualizations. It’s also worth double checking that default filenames used to save the high & low level graphs are not the same, and adequately describe which is which.