Boost logo

Boost Users :

From: Brian Stadler (bdotstadler_at_[hidden])
Date: 2007-09-14 16:06:12


Hi all,

I'm reading in thousands of files in the graphviz language into a program
using read_graphviz(), library version 1.33.1. I noticed a problem with
some of my results and discovered that read_graphviz doesn't appear to be
interpreting the files correctly. The structure of the graphs is preserved
(no edges gone astray). However, the labeling of the nodes is changed. I
confirmed this by reading in a file and immediately writing it back out
using write_graphviz(). Below is the code used to read in the files. It's
very simple as I have nothing special being reprsented. Could someone else
check this and confirm this is a problem. I've checked the bugs list and
1.34.x release notes and found nothing addressing the particular issue.

thanks all.

My read_graphviz code:

bool file;
ifstream in(openfile.c_str(), ios::in);
dynamic_properties dp;
dp.property("node_id", get(&ed_node::vertex_name, ug)); <--simple adjacency
list with bundled properties being used
file = read_graphviz(in, ug, dp, "node_id");

Source graphviz file:

strict graph {
    0 -- 3;
    0 -- 4;
    1 -- 3;
    1 -- 4;
    2 -- 3;
    2 -- 4;
    3 -- 4;
}

Output graphviz file:

graph G {
0;
1;
2;
3;
4;
0--1 ;
0--2 ;
3--1 ;
3--2 ;
4--1 ;
4--2 ;
1--2 ;
}



Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net