Skip to content

Commit

Permalink
Merge pull request #87 from psav/psav/add_dot_generate_back
Browse files Browse the repository at this point in the history
Added back dot generate for visualization
  • Loading branch information
psav authored Dec 20, 2019
2 parents d0ed4d7 + 3dd44ec commit ea82507
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions test/perf/affinity.py
Original file line number Diff line number Diff line change
Expand Up @@ -382,6 +382,14 @@ def generate_routes(self):
routes.add(Conn(node_data.name, conn, 1))
return routes

def generate_dot(self):
dot_data = "graph {"
for node, node_data in self.nodes.items():
for conn in node_data.connections:
dot_data += f"{node} -- {conn}; "
dot_data += "}"
return dot_data

def start(self, wait=True):
self.dump_yaml()

Expand Down

0 comments on commit ea82507

Please sign in to comment.