0.12.5
New Features
-
Add
dimod::ConstrainedQuadraticModel::constraints()method that returns a view of the constraints that is easily iterated over. -
Improve the performance of fixing and removing variables from constrained quadratic model expressions.
-
Implement the
Expression::fix_variable()C++ method. Previously it would throwstd::logic_error("not implemented - fix_variable"). -
Improve the performance of
ConstrainedQuadraticModel.fix_variable()andConstrainedQuadraticModel.fix_variables(). -
Add
inplacekeyword argument toConstrainedQuadraticModel.fix_variables().
Upgrade Notes
-
Add an overload to the C++
QuadraticModel::remove_variable()method. This is binary compatible, but it makes&remove_variableambiguous. -
The
ConstrainedQuadraticModel.fix_variables()function now returns aConstrainedQuadraticModelrather than an empty dictionary. -
Change
lp.load()andlp.loads()to raise aValueErrorrrather than aRuntimeErrorwhen given an invalid file format. -
Make
beta_range,num_reads, andnum_sweepskeyword-only arguments forSimulatedAnnealingSampler.sample(). -
Make
num_readsandseedkeyword-only arguments forRandomSampler.sample(). -
Make
initial_states,initial_states_generator,num_readsandseedkeyword-only arguments forIdentitySampler.sample(). -
Make
rtolandatolkeyword-only arguments forExactCQMSolver.sample_cqm().
Bug Fixes
- Fix
lp.load()andlp.loads()functions to correctly handle maximization objectives. See #1321.