Skip to content
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

1.2.5 #139

Merged
merged 78 commits into from
Oct 19, 2017
Merged

1.2.5 #139

merged 78 commits into from
Oct 19, 2017

Conversation

KristianJensen
Copy link
Contributor

Add missing unpacking in symengine Mul

KristianJensen and others added 30 commits January 4, 2017 14:01
Only update the _variables_to_constriants_mapping dict when new_name !=
old_name
Only _round_primals_to_bounds if solution is optimal
E.g. numpy and sympy
* feat: add get_linear_coefficients method

Abstract non-implemented method

* feat: implement glpk get_linear_coefficients method

* fix: typo

* feat: implement get_linear_coefficients in cplex

* feat: implement get_linear_coefficients in gurobi

* feat: implement get_linear_coefficients in scipy

* test: add tests for get_linear_coefficients

* test: more tests for get_linear_coefficients

* fix: flake8

* fix: missing arguments in test

* fix: make scipy consistent with other interfaces

the get_linear_coefficients and set_linear_coefficients methods now
raise an exception if the objective/constraint doesn’t belong to a model
Some cplex versions don’t have all the statuses that optlang tries to
import, which would result in a crash.
For range constraints, rhs is now equal to lb
This is due to a bug where gurobi can get stuck
* checking if __del__ is needed

* testing against miplib

* using problems from miplib2003

* needs to implement variable comparison for problems that converge

* more problems
runtime: 10 min per problem

* fixed milp test value (same as in devel)

* delete problem from memory only if it exists (__del__ method)

* add a .keep file to keep the miplib2003 directory on tests/data

* miplib test with cplex - some problems also fail...

* need to implement a parser for .sol files

* set 9 min limit for optimization to run, otherwise travis halts after 10 min without output

* refactor: tests and move into slow_tests top directory

* style: flake8

* fix: no point in searching ImportError for 'cplex'

* test: add slow MILP tests for gurobi
* Fix LB/UB Coefficient Change (#82)

* Fix LB/UB Coefficient Change

If coeff is negative, the lower bound could become larger than the upper bound causing an error. Now, the upper bound is first removed and then both bounds are reapplied with the shift.

* Update interface.py

* test: add unittest for constraint expression standardisation

* fix: flake8

* fix: flake8 again

* refactor: simplify logic in constraint offset handling
* feat: add cloned model tests to netlib test suites

* chore: add cloned model tests also for gurobi

* fix: critical bug affecting ranged constraints in cplex interface

* test: skip netlib cloning tests on travis
KristianJensen and others added 28 commits May 17, 2017 09:22
* feat: add tolerance parameters to Configuration

* fix: pickling cplex configurations

* feat: default pickling method for models (json-based)

Fixes scipy pickling

* test: add tolerance param testing

* fix: test case bug

* fix: glpk tolerance names
The expression of an objective can now include constant terms, and the solver will correctly account for this when reporting the objective values.
Prevent objective values from being sympy types
Add symbolics.py module that handles sympy/symengine calls
Symengine.py 0.3 is required. Symengine can be installed with conda `conda install -c symengine -c conda-forge python-symengine`
If symengine is available optlang will attempt to use it automatically
Variables with empty names trigger's segfaults in glpk
interface. Easiest fix appears to simply not allow them as anyway not
meaningful.
- Make gurobi models picklable
- Fix gurobi infinite recursion
- Fix gurobi constraint primal calculation
- Fix a bug where cplex took forever to set a large objective (e.g. 10000 vars)
- Fix some issues with symengine compatibility
Bounds can be set to 0 or 1 (both lb and ub). Also added tests.
Conflicts:
	optlang/tests/test_scipy_interface.py
* Add basic types to optlang.symbolics

* Handle edge cases in add and mul

* also add Basic and Number to sympy wrapper
# Conflicts:
#	optlang/symbolics.py
@codecov-io
Copy link

codecov-io commented Oct 19, 2017

Codecov Report

Merging #139 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #139   +/-   ##
=======================================
  Coverage   89.86%   89.86%           
=======================================
  Files           9        9           
  Lines        2507     2507           
  Branches      553      553           
=======================================
  Hits         2253     2253           
  Misses        167      167           
  Partials       87       87
Impacted Files Coverage Δ
optlang/symbolics.py 100% <ø> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update c34103b...7e83521. Read the comment docs.

@KristianJensen KristianJensen merged commit 102437f into master Oct 19, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

9 participants