Skip to content

Commit

Permalink
Update test and version
Browse files Browse the repository at this point in the history
  • Loading branch information
araffin committed Jun 5, 2024
1 parent d673a98 commit 801d409
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 6 deletions.
2 changes: 1 addition & 1 deletion docs/misc/changelog.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
Changelog
==========

Release 2.4.0a1 (WIP)
Release 2.4.0a2 (WIP)
--------------------------

Breaking Changes:
Expand Down
2 changes: 1 addition & 1 deletion stable_baselines3/version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
2.4.0a1
2.4.0a2
7 changes: 3 additions & 4 deletions tests/test_save_load.py
Original file line number Diff line number Diff line change
Expand Up @@ -804,9 +804,8 @@ def test_save_load_net_arch_none(tmp_path):
Test that the model is loaded correctly when net_arch is manually set to None.
See GH#1928
"""
policy_kwargs = dict(net_arch=None)
model = PPO("MlpPolicy", "CartPole-v1", policy_kwargs=policy_kwargs)
model.learn(100)
model.save(tmp_path / "ppo.zip")
PPO("MlpPolicy", "CartPole-v1", policy_kwargs=dict(net_arch=None)).save(tmp_path / "ppo.zip")
model = PPO.load(tmp_path / "ppo.zip")
# None has been replaced by the default net arch
assert model.policy.net_arch is not None
os.remove(tmp_path / "ppo.zip")

0 comments on commit 801d409

Please sign in to comment.