* Signals that an I/O exception has occurred.
*/
public static void saveGraphToDOT(String fileName,
ILabeledGraph<Integer, ?, Double, Double> graph,
Map<Integer, Integer> partition) throws IOException {
IRandom rand = SimSystem.getRNGGenerator().getNextRNG();
try (FileWriter file = new FileWriter(fileName)) {
int vertexCount = graph.getVertexCount();
Map<Integer, Double> vertexLabels = graph.getVertexLabels();
Map<Integer, Map<Integer, Double>> edgeLabels = graph.getEdgeLabels();
List<List<Integer>> adjacencyLists = graph.getAdjacencyLists();