Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .github/ISSUE_TEMPLATE/bug_report.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,8 @@ body:
* GPU models and configuration
* Python version
* PyTorch version
* Gym version
* Gymnasium version
* (if installed) OpenAI Gym version
* Versions of any other relevant libraries

You can use `sb3.get_system_info()` to print relevant packages info:
Expand Down
9 changes: 5 additions & 4 deletions .github/ISSUE_TEMPLATE/custom_env.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,9 @@ body:
Please use the [markdown code blocks](https://help.github.com/en/articles/creating-and-highlighting-code-blocks) for both code and stack traces.
value: |
```python
import gym
import gymnasium as gym
import numpy as np
from gym import spaces
from gymnasium import spaces

from stable_baselines3 import A2C
from stable_baselines3.common.env_checker import check_env
Expand All @@ -49,7 +49,7 @@ body:
self.observation_space = spaces.Box(low=-np.inf, high=np.inf, shape=(14,))
self.action_space = spaces.Box(low=-1, high=1, shape=(6,))

def reset(self, seed=None):
def reset(self, seed=None, options=None):
return self.observation_space.sample(), {}

def step(self, action):
Expand Down Expand Up @@ -84,7 +84,8 @@ body:
* GPU models and configuration
* Python version
* PyTorch version
* Gym version
* Gymnasium version
* (if installed) OpenAI Gym version
* Versions of any other relevant libraries

You can use `sb3.get_system_info()` to print relevant packages info:
Expand Down
3 changes: 2 additions & 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.0.0a4 (WIP)
Release 2.0.0a5 (WIP)
--------------------------

**Gymnasium support**
Expand Down Expand Up @@ -51,6 +51,7 @@ Others:
- Improve type annotation of wrappers
- Tests envs are now checked too
- Added render test for ``VecEnv``
- Update issue templates and env info saved with the model

Documentation:
^^^^^^^^^^^^^^
Expand Down
11 changes: 10 additions & 1 deletion stable_baselines3/common/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
from itertools import zip_longest
from typing import Dict, Iterable, List, Optional, Tuple, Union

import cloudpickle
import gymnasium as gym
import numpy as np
import torch as th
Expand Down Expand Up @@ -532,8 +533,16 @@ def get_system_info(print_info: bool = True) -> Tuple[Dict[str, str], str]:
"PyTorch": th.__version__,
"GPU Enabled": str(th.cuda.is_available()),
"Numpy": np.__version__,
"Gym": gym.__version__,
"Cloudpickle": cloudpickle.__version__,
"Gymnasium": gym.__version__,
}
try:
import gym as openai_gym # pytype: disable=import-error

env_info.update({"OpenAI Gym": openai_gym.__version__})
except ImportError:
pass

env_info_str = ""
for key, value in env_info.items():
env_info_str += f"- {key}: {value}\n"
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.0.0a4
2.0.0a5