v1.1.3; fix friction calc err (x0.4)
This commit is contained in:
8
CMD.md
8
CMD.md
@@ -38,7 +38,7 @@ python robogauge/scripts/run.py \
|
|||||||
--multi \
|
--multi \
|
||||||
--num-processes 5 \
|
--num-processes 5 \
|
||||||
--seeds 0 1 2 \
|
--seeds 0 1 2 \
|
||||||
--frictions 0.5 1.0 1.5 2.0 2.5 \
|
--frictions 0.2 0.4 0.6 0.8 1.0 \
|
||||||
--compress-logs \
|
--compress-logs \
|
||||||
--headless
|
--headless
|
||||||
|
|
||||||
@@ -49,7 +49,7 @@ python robogauge/scripts/run.py \
|
|||||||
--multi \
|
--multi \
|
||||||
--num-processes 5 \
|
--num-processes 5 \
|
||||||
--seeds 0 1 2 \
|
--seeds 0 1 2 \
|
||||||
--frictions 2.0 \
|
--frictions 0.8 \
|
||||||
--level 10 \
|
--level 10 \
|
||||||
--spawn-type level_eval \
|
--spawn-type level_eval \
|
||||||
--goals max_velocity diagonal_velocity\
|
--goals max_velocity diagonal_velocity\
|
||||||
@@ -68,7 +68,7 @@ python robogauge/scripts/run.py \
|
|||||||
--search-max-level \
|
--search-max-level \
|
||||||
--seeds 0 1 2 \
|
--seeds 0 1 2 \
|
||||||
--search-seeds 0 1 2 3 4 \
|
--search-seeds 0 1 2 3 4 \
|
||||||
--frictions 1.0 \
|
--frictions 0.4 \
|
||||||
--compress-logs \
|
--compress-logs \
|
||||||
--headless
|
--headless
|
||||||
```
|
```
|
||||||
@@ -85,7 +85,7 @@ python robogauge/scripts/run.py \
|
|||||||
--num-processes 50 \
|
--num-processes 50 \
|
||||||
--seeds 0 1 2 \
|
--seeds 0 1 2 \
|
||||||
--search-seeds 0 1 2 3 4 \
|
--search-seeds 0 1 2 3 4 \
|
||||||
--frictions 0.5 0.75 1.0 1.25 1.5 1.75 2.0 2.25 2.5 \
|
--frictions 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 \
|
||||||
--compress-logs \
|
--compress-logs \
|
||||||
--headless
|
--headless
|
||||||
```
|
```
|
||||||
|
|||||||
@@ -114,7 +114,7 @@ All evaluations are run with configured domain randomization (DR). Below are com
|
|||||||
| - | - | - |
|
| - | - | - |
|
||||||
| Random action execution delay | `action delay` | `<= RL control interval` |
|
| Random action execution delay | `action delay` | `<= RL control interval` |
|
||||||
| Base payload mass | `base mass` | `-1, 0, 1, 2, 3 kg` |
|
| Base payload mass | `base mass` | `-1, 0, 1, 2, 3 kg` |
|
||||||
| Ground friction | `friction` | `0.4, 0.7, 1.0, 1.3, 1.6` |
|
| Ground friction | `friction` | `0.2 ~ 1.0 (step 0.1)` |
|
||||||
|
|
||||||
#### Terrains
|
#### Terrains
|
||||||
|
|
||||||
|
|||||||
@@ -100,7 +100,7 @@ while True:
|
|||||||
| - | - | - |
|
| - | - | - |
|
||||||
| 电机动作执行随机延迟 | `action delay` | `<= RL控制间隔` |
|
| 电机动作执行随机延迟 | `action delay` | `<= RL控制间隔` |
|
||||||
| base负重 | `base mass` | `-1, 0, 1, 2, 3 kg` |
|
| base负重 | `base mass` | `-1, 0, 1, 2, 3 kg` |
|
||||||
| 地面摩擦力 | `friction` | `0.4, 0.7, 1.0, 1.3, 1.6` |
|
| 地面摩擦力 | `friction` | `0.2 ~ 1.0 (step 0.1)` |
|
||||||
|
|
||||||
#### 地形
|
#### 地形
|
||||||
1. 支持legged_gym中的部分地形, 包括: `wave, slope, stairs up, stairs down, obstacles, flat`, 除`flat`地形外其他地形可进行难度系数提升
|
1. 支持legged_gym中的部分地形, 包括: `wave, slope, stairs up, stairs down, obstacles, flat`, 除`flat`地形外其他地形可进行难度系数提升
|
||||||
|
|||||||
@@ -1,4 +1,7 @@
|
|||||||
# UPDATE
|
# UPDATE
|
||||||
|
## 20260210
|
||||||
|
### v1.1.3
|
||||||
|
1. 修复摩擦计算问题,之前的所有stress的摩擦*0.4后才是真实摩擦系数,所以之前用的摩擦范围是0.2~1.0,步长0.1
|
||||||
## 20260204
|
## 20260204
|
||||||
### v1.1.2
|
### v1.1.2
|
||||||
1. 加入手柄JoystickGoal功能
|
1. 加入手柄JoystickGoal功能
|
||||||
|
|||||||
@@ -18,6 +18,6 @@
|
|||||||
|
|
||||||
<worldbody>
|
<worldbody>
|
||||||
<light pos="0 0 1.5" dir="0 0 -1" directional="true"/>
|
<light pos="0 0 1.5" dir="0 0 -1" directional="true"/>
|
||||||
<geom name="floor" size="0 0 0.05" type="plane" material="groundplane" priority="1"/>
|
<geom name="floor" size="0 0 0.05" type="plane" material="groundplane"/>
|
||||||
</worldbody>
|
</worldbody>
|
||||||
</mujoco>
|
</mujoco>
|
||||||
@@ -42,7 +42,7 @@ default_args_list = [
|
|||||||
# '--num-processes', '30', # Set in CLI
|
# '--num-processes', '30', # Set in CLI
|
||||||
'--seeds', '0', '1', '2',
|
'--seeds', '0', '1', '2',
|
||||||
'--search-seeds', '0', '1', '2', '3', '4',
|
'--search-seeds', '0', '1', '2', '3', '4',
|
||||||
'--frictions', '0.5', '0.75', '1.0', '1.25', '1.5', '1.75', '2.0', '2.25', '2.5',
|
'--frictions', '0.2', '0.3', '0.4', '0.5', '0.6', '0.7', '0.8', '0.9', '1.0',
|
||||||
'--compress-logs',
|
'--compress-logs',
|
||||||
'--headless',
|
'--headless',
|
||||||
]
|
]
|
||||||
|
|||||||
@@ -36,7 +36,7 @@ class MujocoConfig(Config):
|
|||||||
|
|
||||||
# Setup by config file, ensure evaluation coverage
|
# Setup by config file, ensure evaluation coverage
|
||||||
base_mass = 0.0 # [kg], {-1, 0, 1, 2, 3}
|
base_mass = 0.0 # [kg], {-1, 0, 1, 2, 3}
|
||||||
friction = 1.0 # [N.s/m], {0.4, 0.7, 1.0, 1.3, 1.6}
|
friction = 0.0 # [N.s/m], {0.4, 0.7, 1.0, 1.3, 1.6}
|
||||||
|
|
||||||
class noise:
|
class noise:
|
||||||
# Uniform noise
|
# Uniform noise
|
||||||
|
|||||||
@@ -126,13 +126,13 @@ class MujocoSimulator:
|
|||||||
logger.info(f"Randomized base mass: {original_mass:.3f} -> {new_mass:.3f} kg")
|
logger.info(f"Randomized base mass: {original_mass:.3f} -> {new_mass:.3f} kg")
|
||||||
|
|
||||||
# Domain randomization: friction
|
# Domain randomization: friction
|
||||||
if self.cfg.domain_rand.friction != 1.0:
|
if self.cfg.domain_rand.friction != 0.0:
|
||||||
for i in range(self.mj_model.ngeom):
|
for i in range(self.mj_model.ngeom):
|
||||||
# Both change robot friction and terrain friction, usually robot friction < 1.0
|
# Both change robot friction and terrain friction
|
||||||
# Mujoco friction calculation takes the *max* between two contacting geoms
|
# If one of the two geoms has higher priority, the friction of that geom is used.
|
||||||
geom_friction = self.mj_model.geom_friction[i]
|
# If both geoms have the save priopirty, the maximum of the two friction is used.
|
||||||
geom_friction[0] *= self.cfg.domain_rand.friction
|
# (Go2 foot friction is 0.4 and priority is 1, terrain priority is 0 except floor)
|
||||||
self.mj_model.geom_friction[i] = geom_friction
|
self.mj_model.geom_friction[i][0] = self.cfg.domain_rand.friction
|
||||||
logger.info(f"Scaled geom friction by factor: {self.cfg.domain_rand.friction:.3f}")
|
logger.info(f"Scaled geom friction by factor: {self.cfg.domain_rand.friction:.3f}")
|
||||||
mujoco.mj_forward(self.mj_model, self.mj_data)
|
mujoco.mj_forward(self.mj_model, self.mj_data)
|
||||||
|
|
||||||
|
|||||||
2
setup.py
2
setup.py
@@ -2,7 +2,7 @@ from setuptools import setup, find_packages
|
|||||||
|
|
||||||
setup(
|
setup(
|
||||||
name="robogauge", # 包名
|
name="robogauge", # 包名
|
||||||
version="1.1.2", # 版本号
|
version="1.1.3", # 版本号
|
||||||
author="Wu Tianyang", # 你的名字
|
author="Wu Tianyang", # 你的名字
|
||||||
author_email="993660140@qq.com",
|
author_email="993660140@qq.com",
|
||||||
description="A generic robot RL model evaluation library based on MuJoCo",
|
description="A generic robot RL model evaluation library based on MuJoCo",
|
||||||
|
|||||||
Reference in New Issue
Block a user