Skip to content

Commit

Permalink
Fix dependencies (un-breaks Linux/MacOS CI pipeline) (#775)
Browse files Browse the repository at this point in the history
* Pin huggingface_sb3 version.

* Properly specify the compatible seals version so it does not auto-upgrade to 0.2.

* Make random_mdp test deterministic by seeding the environment.

* Update setup.py

* Remove HuggingFace pin

---------

Co-authored-by: Adam Gleave <[email protected]>
  • Loading branch information
ernestum and AdamGleave authored Sep 7, 2023
1 parent 5b0b531 commit 6e377b4
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 2 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -203,11 +203,11 @@ def get_local_version(version: "ScmVersion", time_format="%Y%m%d") -> str:
"torch>=1.4.0",
"tqdm",
"scikit-learn>=0.21.2",
"seals>=0.1.5",
"seals~=0.1.5",
STABLE_BASELINES3,
"sacred>=0.8.4",
"tensorboard>=1.14",
"huggingface_sb3>=2.2.1",
"huggingface_sb3~=2.3",
"datasets>=2.8.0",
],
tests_require=TESTS_REQUIRE,
Expand Down
2 changes: 2 additions & 0 deletions tests/algorithms/test_mce_irl.py
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,8 @@ def test_infinite_horizon_error(random_mdp, rng):
def test_policy_om_random_mdp(discount: float):
"""Test that optimal policy occupancy measure ("om") for a random MDP is sane."""
mdp = gym.make("seals/Random-v0")
mdp.seed(0)

V, Q, pi = mce_partition_fh(mdp, discount=discount)
assert np.all(np.isfinite(V))
assert np.all(np.isfinite(Q))
Expand Down

0 comments on commit 6e377b4

Please sign in to comment.