Forgot to port gym_Reacher over
This commit is contained in:
parent
7f58093c5e
commit
a76967a498
@ -1,45 +1,16 @@
|
|||||||
from copy import deepcopy
|
from copy import deepcopy
|
||||||
|
|
||||||
from gymnasium import register
|
from ..envs.registry import register, upgrade
|
||||||
|
|
||||||
from . import mujoco
|
from . import mujoco
|
||||||
from .deprecated_needs_gym_robotics import robotics
|
from .deprecated_needs_gym_robotics import robotics
|
||||||
|
|
||||||
ALL_GYM_MOVEMENT_PRIMITIVE_ENVIRONMENTS = {"DMP": [], "ProMP": [], "ProDMP": []}
|
upgrade(
|
||||||
|
id='Reacher-v2',
|
||||||
DEFAULT_BB_DICT_ProMP = {
|
mp_wrapper=mujoco.reacher_v2.MPWrapper,
|
||||||
"name": 'EnvName',
|
add_mp_types=['ProMP'],
|
||||||
"wrappers": [],
|
|
||||||
"trajectory_generator_kwargs": {
|
|
||||||
'trajectory_generator_type': 'promp'
|
|
||||||
},
|
|
||||||
"phase_generator_kwargs": {
|
|
||||||
'phase_generator_type': 'linear'
|
|
||||||
},
|
|
||||||
"controller_kwargs": {
|
|
||||||
'controller_type': 'motor',
|
|
||||||
"p_gains": 1.0,
|
|
||||||
"d_gains": 0.1,
|
|
||||||
},
|
|
||||||
"basis_generator_kwargs": {
|
|
||||||
'basis_generator_type': 'zero_rbf',
|
|
||||||
'num_basis': 5,
|
|
||||||
'num_basis_zero_start': 1
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
kwargs_dict_reacher_promp = deepcopy(DEFAULT_BB_DICT_ProMP)
|
|
||||||
kwargs_dict_reacher_promp['controller_kwargs']['p_gains'] = 0.6
|
|
||||||
kwargs_dict_reacher_promp['controller_kwargs']['d_gains'] = 0.075
|
|
||||||
kwargs_dict_reacher_promp['basis_generator_kwargs']['num_basis'] = 6
|
|
||||||
kwargs_dict_reacher_promp['name'] = "Reacher-v2"
|
|
||||||
kwargs_dict_reacher_promp['wrappers'].append(mujoco.reacher_v2.MPWrapper)
|
|
||||||
register(
|
|
||||||
id='ReacherProMP-v2',
|
|
||||||
entry_point='fancy_gym.utils.make_env_helpers:make_bb_env_helper',
|
|
||||||
kwargs=kwargs_dict_reacher_promp
|
|
||||||
)
|
)
|
||||||
ALL_GYM_MOVEMENT_PRIMITIVE_ENVIRONMENTS["ProMP"].append("ReacherProMP-v2")
|
|
||||||
"""
|
"""
|
||||||
The Fetch environments are not supported by gym anymore. A new repository (gym_robotics) is supporting the environments.
|
The Fetch environments are not supported by gym anymore. A new repository (gym_robotics) is supporting the environments.
|
||||||
However, the usage and so on needs to be checked
|
However, the usage and so on needs to be checked
|
||||||
|
Loading…
Reference in New Issue
Block a user