#18346: Easier handling of vertex labels in graph backends
-------------------------+-------------------------------------------------
       Reporter:         |        Owner:
  ncohen                 |       Status:  needs_review
           Type:         |    Milestone:  sage-6.7
  enhancement            |   Resolution:
       Priority:  major  |    Merged in:
      Component:  graph  |    Reviewers:
  theory                 |  Work issues:
       Keywords:         |       Commit:
        Authors:         |  25765bb3c4cb4c5f49e5078d7e6e3968c62310e1
  Nathann Cohen          |     Stopgaps:
Report Upstream:  N/A    |
         Branch:         |
  public/18346           |
   Dependencies:         |
-------------------------+-------------------------------------------------
Changes (by ncohen):

 * status:  needs_info => needs_review


Comment:

 Hello,

 > 1. Would it be bad to access directly the `._cg` or `._cg_rev`
 attributes? (ok it seems to be for python code)

 I do not think that it is if you do not modify them. Some functions (like
 isomorphism test) use it directly. The guy who wrote the code that does
 that knew what he was doing, unfortunately he is the only one `:-P`

 > 2. Is there a description somewhere of the attributes `vertex_ints` and
 `vertex_labels`?

 Not that I know. I am not sure that I remember exactly what they do
 either. What I remember is that not all vertices have an associated label,
 so that you don't spend your time playing with a dictionary when your
 graph is defined over integers.

 This being said, I plan to rewrite all this (and of course the new code
 will have a proper documentation). I spent several hours thinking of how
 this should all be done, and my hardest constraint was that the changes
 should be "reviewable". Which is not very easily achieved when you plan to
 merge two classes together `:-P`

 The 'first step' was #18185, the second is this one (or #18317, but that's
 only doc). Then I will turn NetworkX backend into a CGraph, and deprecate
 a lot of things in there. And then... Merge the classes `O_O;;`

 > 3. In a cython file, there is no need to declare `cdef object x` or
 `object x`, just do `x`.

 Okay. Well, I don't think I did anything like that but I may have met such
 a line somewhere. Really, this does not matter for the moment: this code
 will be heavily rewritten.

 Nathann

--
Ticket URL: <http://trac.sagemath.org/ticket/18346#comment:5>
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 unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sage-trac.
For more options, visit https://groups.google.com/d/optout.

Reply via email to