Strange slow down when exporting to pajek under R

Bug #766812 reported by pms
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
igraph
New
Undecided
Unassigned

Bug Description

I experience fairly big slow down when 'id' field of vertices is defined and I try to export in pajek format, here is an example.

> g=erdos.renyi.game(200000,0.000001); V(g)$id=0:(vcount(g)-1)
> system.time( write.graph(g,file="rand.net.test",format="pajek") )
   user system elapsed
260.136 35.470 295.812
> g=erdos.renyi.game(200000,0.000001);
> system.time( write.graph(g,file="rand.net.test",format="pajek") )
   user system elapsed
  0.008 0.004 0.014

The exported file is around 1MB. This time does not scale linearly e.g.:

> g=erdos.renyi.game(10000,0.000001); V(g)$id=0:(vcount(g)-1)
> system.time( write.graph(g,file="rand.net.test",format="pajek") )
   user system elapsed
  0.560 0.000 0.566
> g=erdos.renyi.game(100000,0.000001); V(g)$id=0:(vcount(g)-1)
> system.time( write.graph(g,file="rand.net.test",format="pajek") )
   user system elapsed
 62.984 3.872 66.899

Meaning that exporting 1 million nodes can be painful...

Revision history for this message
Gábor Csárdi (gabor.csardi) wrote : Continue on github

The development of igraph has moved to github, so please do not comment on this bug here. You are of course welcome to comment on github, here:
https://github.com/igraph/igraph/issues/427

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.