소스 검색

In the new gym api, reset takes two extra arguments. This removes some warnings.

saleml 2 년 전
부모
커밋
22b50565dd
1개의 변경된 파일2개의 추가작업 그리고 1개의 파일을 삭제
  1. 2 1
      gym_minigrid/minigrid.py

+ 2 - 1
gym_minigrid/minigrid.py

@@ -728,7 +728,8 @@ class MiniGridEnv(gym.Env):
         # Initialize the state
         self.reset()
 
-    def reset(self):
+    def reset(self, *, seed=None, return_info=False, options=None):
+        super().reset(seed=seed)
         # Current position and direction of the agent
         self.agent_pos = None
         self.agent_dir = None