mirror of
https://github.com/ANL-CEEESA/MIPLearn.git
synced 2025-12-08 18:38:51 -06:00
Remove sample.{get,set}
This commit is contained in:
@@ -93,7 +93,7 @@ def test_usage_with_solver(instance: Instance) -> None:
|
||||
|
||||
stats: LearningSolveStats = {}
|
||||
sample = instance.get_samples()[0]
|
||||
assert sample.get("lazy_enforced") is not None
|
||||
assert sample.get_set("lazy_enforced") is not None
|
||||
|
||||
# LearningSolver calls before_solve_mip
|
||||
component.before_solve_mip(
|
||||
@@ -142,7 +142,7 @@ def test_usage_with_solver(instance: Instance) -> None:
|
||||
)
|
||||
|
||||
# Should update training sample
|
||||
assert sample.get("lazy_enforced") == {"c1", "c2", "c3", "c4"}
|
||||
assert sample.get_set("lazy_enforced") == {"c1", "c2", "c3", "c4"}
|
||||
#
|
||||
# Should update stats
|
||||
assert stats["LazyStatic: Removed"] == 1
|
||||
|
||||
Reference in New Issue
Block a user