diff --git a/docs/conf.py b/docs/conf.py index e6163812..9c0a1420 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -23,7 +23,7 @@ author = "Quentin Gallouédec" # The full version, including alpha/beta/rc tags -release = "v3.0.2" +release = "v3.0.3" # -- General configuration --------------------------------------------------- diff --git a/panda_gym/envs/core.py b/panda_gym/envs/core.py index 16911571..d7462b1c 100644 --- a/panda_gym/envs/core.py +++ b/panda_gym/envs/core.py @@ -208,6 +208,7 @@ class RobotTaskEnv(gym.Env): def __init__(self, robot: PyBulletRobot, task: Task) -> None: assert robot.sim == task.sim, "The robot and the task must belong to the same simulation." self.sim = robot.sim + self.metadata["render_fps"] = 1 / self.sim.dt self.robot = robot self.task = task observation, _ = self.reset() # required for init; seed can be changed later diff --git a/panda_gym/pybullet.py b/panda_gym/pybullet.py index b4e869b3..0145f4c8 100644 --- a/panda_gym/pybullet.py +++ b/panda_gym/pybullet.py @@ -139,10 +139,12 @@ def render( if self.render_mode == "rgb_array": if self.connection_mode == p.DIRECT: warnings.warn( - "The use of the render method is not recommended when the environment " - "has not been created with render_mode='human'. The rendering will probably be weird. " - "Prefer making the environment with option `render_mode='rgb_array'. For example: " - "`env = gym.make('PandaReach-v3', render_mode='rgb_array')`.", + "You have set 'render_mode' to be 'rgb_array'. This is correct if you want to render the " + "environment without an OpenGL engine. However, this option does not support transparency " + "or background rendering and may result in lower quality rendering. To improve the rendering " + "quality, we recommend that you use render_mode='human' instead. The render() method will " + "return a more qualitative rendering of the environment. " + "For example: env = gym.make('PandaReach-v3', render_mode='human').", UserWarning, ) view_matrix = self.physics_client.computeViewMatrixFromYawPitchRoll( diff --git a/panda_gym/version.txt b/panda_gym/version.txt index d9c62ed9..282895a8 100644 --- a/panda_gym/version.txt +++ b/panda_gym/version.txt @@ -1 +1 @@ -3.0.2 \ No newline at end of file +3.0.3 \ No newline at end of file