Which graph library is best suited for large graphs?

Tiago de Paula Peixoto tiago at forked.de
Sat Dec 12 07:01:36 EST 2009


Hi there,

On 12/11/2009 08:12 AM, Wolodja Wentland wrote:
> I really like the API of networkx but have no problem in switching to
> another one (right now) .... I have the impression that graph-tool might
> be faster and have a smaller memory footprint than networkx, but am
> unsure about that.

I'm the author of graph-tool, so my opinion may be biased. :-)

Nevertheless, I do think that graph-tool will be faster and have a
smaller memory footprint than networkx, since the graph data structures
and most algorithms are written in C++, using the Boost Graph Library,
whereas networkx is mostly pure python. I have made this library due to
my own requirements of being able to work with large graphs.

The only other library I can think of which may be comparable in
performance is igraph, which is implemented in C. But I think
graph-tool's interface is a bit more polished (my opinion
only). Moreover, since graph-tool uses template metaprograming to obtain
specialized versions of algorithms, it may be that it is even faster
than igraph, but I have at the moment no benchmarks to back this up.

Cheers,
Tiago

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 262 bytes
Desc: OpenPGP digital signature
URL: <http://mail.python.org/pipermail/python-list/attachments/20091212/60800e14/attachment-0001.sig>


More information about the Python-list mailing list