-
-
Notifications
You must be signed in to change notification settings - Fork 596
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Meta-ticket: make graphs compatible with Python 3 #26640
Comments
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
comment:4
I'm answering here the question of #26567#comment:9 about how to make So far, I don't know what's the best option.
All these options have pros and cons, and each of them will require a significant amount of work to fix doctests and algorithms. In the last months, we did significant progresses on reducing the dependency on ordering, but this is not enough and this central issue is very complex to fix. Which is the best option in the short/long term ? |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
comment:9
May I ask in which ticket, if any, you do touch the "is_isomorphic" method ? I would really like this to work with python 3: sage: G = Graph()
sage: G.add_edge((1,'a'))
sage: G
Graph on 2 vertices
sage: G.is_isomorphic(G) |
comment:10
I have not touched any method related to isomorphism. I have only opened a ticket to show a bug with |
comment:11
ok.. Then either we wait for all these tickets to be closed (and this may take a lot of time) or we can try to fix this isomorphism problem now.. |
comment:12
We can start working on it. In the worst case, I will have to fix some merge conflicts. |
comment:13
I have made a first tentative at |
comment:14
I'm not good enough with git to know what you have changed, except the first 2 calls to |
comment:15
I made #26846 for graph isomorphism |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
comment:24
Salut !
|
comment:68
Replying to @dcoudert:
My gut reaction was that seems heavy handed. It would make sense, but I suspect the reason we don't is because it would be too expensive (relatively) to return a |
This comment has been minimized.
This comment has been minimized.
comment:70
Some doctests are failing with
|
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
comment:75
We are almost done. We have currently 3 open tickets for the remaining failing doctests. Needs work (contributors are more than welcome):
Needs review / help / comment:
|
This comment has been minimized.
This comment has been minimized.
comment:76
Replying to @dcoudert:
For this one, I would be tempted to label it |
comment:77
It is related to sage notebook, but doctests are failing only with py3... So I don't know which is the best approach. Should we try to make a little change to sagenb to make #27435 fixing the issue, although sagenb will be removed in the future (but when?) ? |
comment:78
I apologize, my comments really belong on #27435. I'll continue the discussion there. |
This comment has been minimized.
This comment has been minimized.
comment:79
All doctests in the standard graphs module are now fixed ! Thanks to all of you for your great help. We can now check all optional packages. For instance, |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
comment:82
it's time to close this ticket. |
Author: David Coudert |
comment:83
Yes, I agree. |
Reviewer: John Palmieri |
This ticket is used to keep track of the progress towards python3 in graphs.
Major issues
.vertices()
and.edges()
iterator_edges
ofbase/sparse_graph.pyx
)adjacency_matrix
,distance_matrix
, etc. For all these methods, we can now give as input an ordering of the vertices (and edges) that will be used to order rows and columns. Currently, we use.vertices()
and.edges()
by default. If we switch tolist(G)
by default, we have to check that it's not breaking algorithms using these matrices.Needs work:
Needs review:
sort=None
as the plan is to setsort=False
by default.Done
graph_plot.py
graph_plot_js.py
,graph_list.py
andgraph_input.py
graph_coloring.py
and avoid comparison of vertex labelssrc/sage/graphs/graph_decomposition/
- avoid .vertices() in bandwidth.pyx #26827, pep8 cleaning of bandwidth.pyx #26828, improve cutwidth.pyx #26829, avoid .vertices() and .edges() in graph_products.pyx #26830, avoid .vertices() in rankwidth.pyx #26831, avoid using .vertices() in tdlib.pyx #26832, avoid using .vertices() in vertex_separation.pyx #26833, pep8 cleaning in vertex_separation.pyx #26834.vertices()
in comparability, hyperbolicity and distances_all_pairs.vertices()
in asteroidal_triples.vertices()
in weakly_chordal.pyx.vertices()
.vertices()
incentrality.pyx
.vertices()
and.edges()
inbliss.pyx
.vertices()
in convexity_properties.pyx.vertices()
in graph_coloring.py.vertices()
in independent_sets.pyxBlanusaSecondSnarkGraph
HortonGraph
generatorSzekeresSnarkGraph
generatorgraph_input.py
andhypergraph_generators.py
canonical_label
fixed by Produce consistent graph6 and dig6 strings in python3 #27695static_sparse_graph.pyx
graph_generators.py
.vertices()
and.edges()
inunion
of graphsis_aperiodic
to fix doctests (due to deprecation warning in networkx)map
instrongly_regular_db.pyx
digraph_generators.py
.vertices()
ingraph_plot.py
.vertices()
inplanarity.pyx
.vertices()
in methodapex_vertices
.vertices()
in methods_ford_fulkerson
,edge_cut
,bounded_outdegree_orientation
andgomory_hu_tree
.vertices()
ingraph_isom_equivalent_non_edge_labeled_graph()
spanning_tree.pyx
automorphism_group()
shouldn't sort verticesgraph.py
.vertices()
in methodear_decomposition
graph.py
digraph_generators.py
(part 4)digraph_generators.py
(part 5)connectivity.pyx
dense_graph.pyx
,sparse_graph.pyx
,static_sparse_graph.pyx
centrality.pyx
comparability.pyx
vertex_separation.pyx
boost_graph.pyx
strongly_regular_db.pyx
hyperbolicity
andgraph_coloring
c_graph.pyx
NetworkXGraphDeprecated
andNetworkXDiGraphDeprecated
distances_all_pairs.pyx
digraph.py
generic_graph
(part 1)generic_graph
(part 2) -- cycle_basisgeneric_graph
(part 3) -- _build_flow_graphgeneric_graph
(part 4)generic_graph
(part 5)generic_graph
(part 6) --graphviz_string
generators/families.py
vertex_separation.pyx
generic_graph
(part 7) -- relabelgeneric_graph
(part 8) --coarsest_equitable_refinement
generic_graph
(part 9) --automorphism_group
generic_graph
(part 10) --is_isomorphic
graph_database.py
withinteractive_query
automorphism_group
and fix one doctest inMathonPseudocyclicStronglyRegularGraph
Optional packages:
With #27628, #27811, #27948, #28108 and #28371 all failing doctests of the optional packages used in the graph module are fixed: benzene, bliss, buckygen, csdp, dot2tex and graphviz, gap_packages, igraph and python_igraph, mcqd, plantri, tdlib
CC: @tscrim @fchapoton @jhpalmieri @jfraymond
Component: graph theory
Author: David Coudert
Reviewer: John Palmieri
Issue created by migration from https://trac.sagemath.org/ticket/26640
The text was updated successfully, but these errors were encountered: