v0.1.4; Add terrain IS_HARD option

This commit is contained in:
wty-yy
2026-01-05 22:10:09 +08:00
parent 319853d0f3
commit ddd7119050
3 changed files with 16 additions and 4 deletions

View File

@@ -1,3 +1,6 @@
# 20260105
## v0.1.4
1. `legged_gym/utils/terrain.py`加入地形难度选择默认`IS_HARD=True`
# 20260104
## v0.1.3
1. 修改moe-cts的torch script输出为`action, (weights, latent)`形式, cts输出为`action, (None, latent)`

View File

@@ -90,9 +90,18 @@ class Terrain:
length=self.width_per_env_pixels,
vertical_scale=self.cfg.vertical_scale,
horizontal_scale=self.cfg.horizontal_scale)
slope = 0.1 + difficulty * 0.52
step_height = 0.05 + 0.23 * difficulty
discrete_obstacles_height = 0.05 + difficulty * 0.25
IS_HARD = True
if IS_HARD:
# hard
slope = 0.1 + difficulty * 0.52 # max: 29.6 degrees
step_height = 0.05 + 0.23 * difficulty # max: 0.257 m
discrete_obstacles_height = 0.05 + difficulty * 0.25 # max: 0.275 m
else:
# default (easy)
slope = difficulty * 0.4 # max: 19.8 degrees
step_height = 0.05 + 0.18 * difficulty # max: 0.212 m
discrete_obstacles_height = 0.05 + difficulty * 0.2 # max: 0.23 m
stepping_stones_size = 1.5 * (1.05 - difficulty)
stone_distance = 0.05 if difficulty==0 else 0.1
gap_size = 1. * difficulty

View File

@@ -2,7 +2,7 @@ from setuptools import find_packages
from distutils.core import setup
setup(name='go2_rl_gym',
version='1.0.0',
version='0.1.4',
author='Wu Tianyang',
license="MIT",
packages=find_packages(),