#9362: Invalidate None as a vertex label.
----------------------------+-----------------------------------------------
   Reporter:  boothby       |          Owner:  jason, mvngu, ncohen, rlm
       Type:  defect        |         Status:  needs_info               
   Priority:  major         |      Milestone:                           
  Component:  graph theory  |       Keywords:  sd35.5                   
Work_issues:                |       Upstream:  N/A                      
   Reviewer:                |         Author:                           
     Merged:                |   Dependencies:  #11739                   
----------------------------+-----------------------------------------------

Comment(by brunellus):

 BTW: I'm not sure how slow is exception handling in Python, but isn't it
 little unfortunate that this is used so extensively in the add_edge
 function? Every call add_edge((u, v)) raises an exception that is
 immediately caught.

 {{{
 sage: G=Graph(multiedge=True)
 sage: timeit("G.add_edge(1, 2)")
 625 loops, best of 3: 8.21 µs per loop
 sage: timeit("G.add_edge((1, 2))")
 625 loops, best of 3: 12.2 µs per loop
 }}}

-- 
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/9362#comment:8>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica, 
and MATLAB

-- 
You received this message because you are subscribed to the Google Groups 
"sage-trac" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/sage-trac?hl=en.

Reply via email to