trac #15978: Waste of time in g.edges()
changed to new method attribute names (im_func -> __func__)

5 .py modules were changed by the 2to3 tool
   (one was imcomplete as it had a hasattr() function)
2 .pyx were changed manually
1 additional .py module had im_func in a doc-test
update dot2tex to latest dev version
form valid keys for dot2tex
fix more doctest failures
pointless bikeshedding of tarball name
pyparsing is deprecating itself
delete previous dot2tex directory if it exists
fix sage -gdb
Do not import prun, it is provided by IPython
delete sage.misc.prun
trac #15978: Rebase on 6.2.beta5
trac #15978: Broken doc
trac #15978: Broken doctest in combinat/crystals/
Added the force float patch.
changes generated by 2to3 tool (tuple_params) for Python 3

Changes for 25 modules were generated.
Some changes are imcomplete (containing "xxx_todo_changeme").
These will be fixed in a subsequent commit.
fix manually the "xxx_todo_changeme" from previous commit

9 .py modules are affected
trac #15993 reviewer patch
trac #15993 one minor error corrected
Trac #15978: Waste of time in g.edges() (acually in iterator_edges)

Jernej reported that Sage took <a lifetime> to enumerate the edges of an
important graph of his. There was actually a comment in the source code
which I left then forgot, saying that this particular block of code was
totally awful.

Was.

With the latest release :

{{{
sage: g = graphs.CompleteGraph(3000)
sage: %time _ = g.to_dictionary()
CPU times: user 1.38 s, sys: 0 ns, total: 1.38 s
Wall time: 1.37 s
sage: %time _ = g.edges()
CPU times: user 1min 24s, sys: 8 ms, total: 1min 24s
Wall time: 1min 24s
}}}

With this branch :

{{{
sage: g = graphs.CompleteGraph(3000)
sage: %time _ = g.to_dictionary()
CPU times: user 1.38 s, sys: 0 ns, total: 1.38 s
Wall time: 1.37 s
sage: %time _ = g.edges()
CPU times: user 6.88 s, sys: 0 ns, total: 6.88 s
Wall time: 6.88 s
}}}

Which still does not make any sense.

Nathann

URL: http://trac.sagemath.org/15978
Reported by: ncohen
Ticket author(s): Nathann Cohen
Reviewer(s): Jernej Azarija