Files
Gymnasium/gym/envs/robotics/fetch/push.py
Matthias Plappert c8f8149544 Remove joints from table to avoid that Fetch can slide it to cheat (#962)
* Remove joints from table to avoid that Fetch can slide it to cheat

* Bump Gym version

* Bump version

* Do not bump Hand
2018-04-05 16:55:52 +02:00

19 lines
751 B
Python

from gym import utils
from gym.envs.robotics import fetch_env
class FetchPushEnv(fetch_env.FetchEnv, utils.EzPickle):
def __init__(self, reward_type='sparse'):
initial_qpos = {
'robot0:slide0': 0.405,
'robot0:slide1': 0.48,
'robot0:slide2': 0.0,
'object0:joint': [1.25, 0.53, 0.4, 1., 0., 0., 0.],
}
fetch_env.FetchEnv.__init__(
self, 'fetch/push.xml', has_object=True, block_gripper=True, n_substeps=20,
gripper_extra_height=0.0, target_in_the_air=False, target_offset=0.0,
obj_range=0.15, target_range=0.15, distance_threshold=0.05,
initial_qpos=initial_qpos, reward_type=reward_type)
utils.EzPickle.__init__(self)