hyphi_gym.envs.PointMaze
#
Package Contents#
Classes#
Gridworld Maze Environment based on hyphi Grid. |
|
Base class for Continous Control in Board Games |
|
Base class for Continous Control in Board Games |
- class hyphi_gym.envs.PointMaze.Maze(size, random=[], prefix='', **kwargs)#
Bases:
hyphi_gym.common.board.Board
Gridworld Maze Environment based on hyphi Grid. :param size: (≤15, guarantee solvability within 100 steps (worst for 15: 96)) :param random: optional list of features to be stochastic supporting layout, agent-, and target-placement
- _generate()#
Generate random mazes of self.size using Kruskal’s algorithm. Generated mazes are forced to difer the static configurations above.
- class hyphi_gym.envs.PointMaze.Point(grid=False, render_mode=None, frame_skip=1)#
Bases:
hyphi_gym.common.simulation.Simulation
Base class for Continous Control in Board Games Use for 3D simulation of continuous board envs and rendering of grids
- property default_cam_config#
- property agent: tuple[hyphi_gym.common.board.np.ndarray, hyphi_gym.common.board.np.ndarray]#
Get noisy initial agent position and velocity
- step_scale = 10#
- base_xml#
- metadata#
- state_vector() hyphi_gym.common.board.np.ndarray #
Return the position and velocity joint states of the model
- execute(action: hyphi_gym.common.board.np.ndarray) tuple[dict, dict] #
Executes the action, returns the new state, info, and distance between the agent and target
- reset(**kwargs)#
Reset the environment simulation and randomize if needed
- setup_world(layout=None)#
Helper function to generate a simulation from a board-based layout
- load_world()#
Helper function to load a generated world from self.model_path falling back to self.base_xml
- _toggle_target(active: hyphi_gym.common.board.Optional[bool] = None)#
Toggles activity of the target site, can be forced using active
- update_world(action: int, position: hyphi_gym.common.board.Union[hyphi_gym.common.board.np.ndarray, tuple], cell: str)#
- reset_world()#
Reset simulation and reposition agent and target to respective i_pos
- _update(key: str, oldpos, newpos)#
- class hyphi_gym.envs.PointMaze.PointMaze(render_mode=None, **kwargs)#
Bases:
hyphi_gym.common.point.Point
,hyphi_gym.common.maze.Maze
Base class for Continous Control in Board Games Use for 3D simulation of continuous board envs and rendering of grids