开发者

Importing Large iGraph Memory Exhausted

I'm trying to import a large LGL file (~2GB) and I am attempting to import this in igraph using

graph = Graph.Read_Lgl("Biggraph.lgl")

The error it is throwing is

Traceback (most recent call last):
  File "graph.py", line8, in <module>
    graph = Graph.Read_Lgl("Biggraph.lgl")
igraph.core.InternalError: Error at foreign.c:359: Parse error in LGL file, line 9997 (memory exhausted), Parse Error

I'm unsure as to what exactly is going on here. The memory exhausted error is making me think that the memory allocated to python (or the underlying C) is being used up when trying to read 开发者_开发问答the file, but it almost happens instantly, like it isn't even trying to do much. Maybe it's looking at the file size and saying 'woah, can't do that.'

Seriously though, I have no idea what is happening. What I assumed from iGraph is that it can handle extremely large graphs, and I dont think my graph is too large for it.

I did generate the lgl file myself, but I believe I have the syntax correct. This error doesn't really seem like there is a problem with my lgl file, but I could be wrong ("Parse error" kind of scares me).

I just figured I'd try here and see if anyone more keen on how iGraph operates would know how to quickly solve this problem (or extend the memory). Thanks.


For the record, the poster has found a bug in the igraph library and we are working on a fix right now. The problem is caused by a right-recursive rule in the bison parser specification for the LGL format. Once we have an official patch for it in the trunk of the project, I will post the URL of the patch here should others run into the same problem.


Update: The URLs to the patches are:

  • http://bazaar.launchpad.net/~igraph/igraph/0.5-main/revision/1696 (for igraph 0.5.x)
  • http://bazaar.launchpad.net/~igraph/igraph/0.6-main/revision/2543 (for igraph 0.6)
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜