Closed mkoeppe closed 6 years ago
Dependencies: #24782
It's certainly better to make different tickets to avoid conflicts since we will touch different modules. Furthermore, we can take the opportunity to improve some codes. For instance in src/sage/numerical/optimize.py
, the binpacking
method needs some polishing.
binpacking
from src/sage/numerical/optimize.py
src/sage/graphs/comparability.pyx
flat_cover
of src/sage/matroids/matroid.pyx
SatLP
of src/sage/sat/solvers/sat_lp.py
.The parameter solver was here but not used.
We have added parameter solver
to all calls to MixedIntegerLinearProgram
. The last possible improvement is to allow to give the parameters solver
and verbose
to methods calling methods calling methods calling MixedIntegerLinearProgram
. For instance, method is_hamiltonian
calls traveling_salesman_problem
without allowing to give the parameters.
Do you think we should (try to) do it ? I don't know to trace calls to methods...
Replying to @dcoudert:
We have added parameter
solver
to all calls toMixedIntegerLinearProgram
. The last possible improvement is to allow to give the parameterssolver
andverbose
to methods calling methods calling methods calling
no typo here? this looks scary...
MixedIntegerLinearProgram
. For instance, methodis_hamiltonian
callstraveling_salesman_problem
without allowing to give the parameters. Do you think we should (try to) do it ? I don't know to trace calls to methods...
one way would be to add print statements and then watch doctests failing...
Probably there are some static code analysis tools to help here too, but I'm no expert in these.
Author: David Coudert
I added parameter solver to many methods in graphs/
. I have certainly missed some, but it's already an improvement. Not sure if I should do the same for other modules in this ticket. it's already a lot of modifications...
Last 10 new commits:
6c596d4 | trac #20416: correct max_cut |
2927b79 | trac #20416: correct longest_path |
ae072ef | trac #20416: add parameter solver to hamiltonian_cycle |
c30b59a | trac #20416: improvement of flow |
55dc77b | trac #20416: improvement of multicommodity_flow |
46abf3e | trac #20416: improvement of disjoint_routed_paths |
236abc1 | trac #20416: add parameter solver to edge and vertex disjoint paths |
15b0955 | trac #20416: corrections in generic_graph.py |
d5d8c6a | trac #20416: add parameter solver to methods in graph.py |
ee6d1d7 | trac #20416: add parameter solver to methods in graph_coloring.py |
update milestone 8.3 -> 8.4
Branch pushed to git repo; I updated commit sha1. New commits:
bb832ce | trac #22050: Merged with 8.4.beta1 |
Branch pushed to git repo; I updated commit sha1. New commits:
4e27e2c | trac #20416: resolve merge conflicts with 8.4.beta4 |
I fixed the conflicts with 8.4.beta4.
Changed dependencies from #24782 to none
Seems to be OK. Tests fail, but they are marked as # optional - magma
, so are not related to this patch.
Reviewer: Jori Mäntysalo
Changed branch from u/dcoudert/20416_parameter_solver to 4e27e2c
CC: @dimpase @videlec @jdemeyer @dcoudert @jm58660
Component: numerical
Author: David Coudert
Branch/Commit:
4e27e2c
Reviewer: Jori Mäntysalo
Issue created by migration from https://trac.sagemath.org/ticket/20416