Standard graph API?

wes weston wweston at att.net
Mon Aug 23 16:29:44 EDT 2004


Magnus Lie Hetland wrote:
> Is there any interest in a (hypothetical) standard graph API (with
> 'graph' meaning a network, consisting of nodes and edges)? Yes, we
> have the standard ways of implementing graphs through (e.g.) dicts
> mapping nodes to neighbor-sets, but if one wants a graph that's
> implemented in some other way, this may not be the most convenient (or
> abstract) interface to emulate. It might be nice to have the kind of
> polymorphic freedom that one has with, e.g, with the DB-API. One could
> always develop factories or adaptors (such as for PyProtocols) to/from
> the dict-of-sets version...
> 
> So, any interest? Or am I just a lone nut in wanting this?
> 

Magnus,
    Do you have any design thoughts. It would be good to have weighted,
directed graphs and depth first traversal.
wes




More information about the Python-list mailing list