This is more curiosity, rather than needing a solution (although solutions are welcome).
I tried adding a large number of nodes to my dot graph today, and started getting an error. If I leave DPI at the default, I get the error “dot: failure to create cairo surface: out of memory”. If I reduce the DPI to 64, or set the page size, my graph works.
It currently has about 350 nodes and 400 edges, and most nodes are ranked; the dot file is a bit over 1000 lines. The resulting JPG is large: 10554 x 14332 @ 64 DPI. If printed at full resolution, it would be 164 inches x 223.93 inches, or 13.74 feet 18.66 feet. I had hoped to print this, but that’s far too big to fit on my wall. Forcing the page size to 8’ x 6’ allows dot to build the graph, but even that size is too large. Most of the text is the default size, so even setting it to 8’ x 6’ makes the text kind of small.
I’m running version 2.44.1 on Windows 10. Using Task Manager, the highest I’ve seen the memory is between 600MB-700MB. Clearly, adding a lot of new nodes caused the problem to appear. Is there a limit on the number of nodes and edges? I may have to scale back my plans if I’m getting close to a node limit. Since my goal is to print this, setting the page size isn’t limiting me. Alternatively, is there a way around this error?