Ask Your Question
0

Sagenb long (graph) calculations silently terminating

asked 2013-01-19 17:05:15 -0500

Zomulgustar gravatar image

updated 2013-01-19 17:13:35 -0500

To recapitulate the title, I've been having quite a few different sagenb runs silently terminate lately...the green sidebar just goes away, and the full_output.txt link appears, but the results are clearly incomplete. Just wondering if anyone knew why this might be happening, or could suggest a remedy... I considered the possibility of a memory limit issue, but processing items from generators one at a time rather than building large lists seems to have no impact. I have no tracebacks to post, as whatever is stopping the execution is doing so without raising an exception. By printing intermediate results, I've found that the execution doesn't stop deterministically at the same point, though certain runs will consistently be cut off before completion. Here is a sample which never seems to complete: In this case, I'm cataloguing the automorphism groups of cubic graphs, but can't seem to get through the 18-vertex case...thanks in advance for any help!


import collections
lglist=collections.Counter()

for k in range(4,19): lglist.clear() gen = (graphs.nauty_geng(str(k) + "-C -d3 -D3")) while 0==0: try: g=gen.next() except StopIteration: break if g.vertex_connectivity()>=3: a=[] a.append(k) a.append(g.vertex_connectivity()) try:
b=g.automorphism_group().group_id() except RuntimeError: b=[g.automorphism_group().cardinality(),0] a=a+b lglist.update((tuple(a),))

for item in lglist.items(): print item

edit retag flag offensive close merge delete

Comments

1

I'm using sage 5.5. After running the code I get an error, not a silent termination. RuntimeError: Gap produced error output recursion depth trap (5000) executing Size($sage119); Perhaps this is a bug?

fidbc gravatar imagefidbc ( 2013-01-19 17:34:12 -0500 )edit

Though avoiding unnecessary gap calls seems to help a bit, there appears to be something else going wrong as well... adding gap.SetRecursionTrapInterval(0) at the start doesn't allow the example code above to complete in my sagenb.

Zomulgustar gravatar imageZomulgustar ( 2013-01-20 11:04:26 -0500 )edit
1

When you say using sagenb, do you mean www.sagenb.org? I believe that does indeed have a time limit set, since it is a free resource.

kcrisman gravatar imagekcrisman ( 2013-01-21 01:49:56 -0500 )edit

Yes, that was my first thought but I figured there would be an error message or something prominent in the documentation.

Zomulgustar gravatar imageZomulgustar ( 2013-01-21 05:10:43 -0500 )edit

1 answer

Sort by ยป oldest newest most voted
1

answered 2013-01-21 04:19:28 -0500

Jason Grout gravatar image

updated 2013-01-21 04:22:29 -0500

First, there are time limits on calculations on sagenb.org which you may be running into. Have you tried running it on a computer that you can run long-running calculations on?

Second, I simplified your code quite a bit. I use the actual automorphism group as an item in the tuple, since apparently the calls to gap may be part of the problem, from the discussion above:

import collections
lglist=collections.Counter()

lglist.clear()
for k in range(4,15):
    for g in graphs.nauty_geng(str(k) + "-C -d3 -D3"):
        if g.vertex_connectivity()>=3:
            lglist[(k, g.vertex_connectivity(), g.automorphism_group())]+=1

for k,v in lglist.items():
    print v,k
edit flag offensive delete link more

Comments

Thanks! Given the lack of blindingly obvious references to those timeouts, I assumed the limit would take the form of throttling instead, or at least come with an error message so I didn't waste even more cycles repeating variations off the same (evidently sloppy) code. ^_^ Now if I could just get the Sage VM to install the gap packages correctly (or get a stable internet connection under Ubuntu), I'd be in business.

Zomulgustar gravatar imageZomulgustar ( 2013-01-21 05:03:07 -0500 )edit

Seems to work ok (if slowly) on the sagevm, thanks! I'm pretty sure using g.automorphism_group like that doesn't distinguish between isomorphic permutation groups exchanging different vertex sets (or even differently-labeled versions of the same set?) so I'll try it both ways now that i have some confidence it will actually complete.

Zomulgustar gravatar imageZomulgustar ( 2013-01-21 15:00:24 -0500 )edit

Unfortunately this doesn't seem to have solved the problem after all...it seems to take longer to happen, at least (even when measured in terms of processing done). Any more ideas?

Zomulgustar gravatar imageZomulgustar ( 2013-01-21 20:34:07 -0500 )edit

Upgrading to the 5.6 appliance seems to have resolved the remaining issues.

Zomulgustar gravatar imageZomulgustar ( 2013-02-09 17:03:52 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2013-01-19 17:05:15 -0500

Seen: 179 times

Last updated: Jan 21 '13