random graph generation with networkx