fix: fixed schedule, init_noise 0.5, AdaBoot cap 0.9 (keep vel head gradient)

This commit is contained in:
8x54zj-m
2026-07-01 16:56:07 +08:00
parent a3562fbab1
commit 2bd4c05e1b
2 changed files with 4 additions and 4 deletions

View File

@@ -222,8 +222,8 @@ class DreamWaQPPO(PPO):
cv = std_r / (mean_r + 1e-6) cv = std_r / (mean_r + 1e-6)
if not (0 <= cv < 1e6): # NaN 或 Inf → 保持当前 prob if not (0 <= cv < 1e6): # NaN 或 Inf → 保持当前 prob
return return
# CV → bootstrap 概率CV 高→不稳定→多用 GT映射系数 5.0 可调 # CV → bootstrap 概率CV 高→不稳定→多用 GT上限 0.9 保证 CENet vel head 有梯度
self.actor._adaboot_prob = max(0.0, min(1.0, cv * 5.0)) self.actor._adaboot_prob = max(0.0, min(0.9, cv * 5.0))
def _compute_surrogate_loss( def _compute_surrogate_loss(
self, actions_batch, actions_log_prob_batch, self, actions_batch, actions_log_prob_batch,

View File

@@ -126,7 +126,7 @@ class rslrl:
runner.algorithm.entropy_coef = 0.01 # 上游 Go1RoughCfgPPO runner.algorithm.entropy_coef = 0.01 # 上游 Go1RoughCfgPPO
runner.algorithm.desired_kl = 0.01 # 上游 0.01 (默认 0.008) runner.algorithm.desired_kl = 0.01 # 上游 0.01 (默认 0.008)
runner.algorithm.clip_param = 0.2 runner.algorithm.clip_param = 0.2
runner.algorithm.schedule = "adaptive" # 上游原值,前期 bug 已修 runner.algorithm.schedule = "fixed" # 4096 envs 采样够大,不需要 adaptive 加噪
runner.algorithm.gamma = 0.99 runner.algorithm.gamma = 0.99
runner.algorithm.lam = 0.95 runner.algorithm.lam = 0.95
runner.algorithm.max_grad_norm = 1.0 runner.algorithm.max_grad_norm = 1.0
@@ -136,7 +136,7 @@ class rslrl:
runner.actor.class_name = ( runner.actor.class_name = (
"motrix_rl.rslrl.torch.models.cenet_actor:CENetActorModel") "motrix_rl.rslrl.torch.models.cenet_actor:CENetActorModel")
runner.actor.hidden_dims = [512, 256, 128] runner.actor.hidden_dims = [512, 256, 128]
runner.actor.init_noise_std = 1.0 # 上游原值adaptive 会自行调节 runner.actor.init_noise_std = 0.5 # 与 fixed schedule 配合
# Critic标准 MLPModel输入 privileged_obs # Critic标准 MLPModel输入 privileged_obs
runner.critic.class_name = "MLPModel" runner.critic.class_name = "MLPModel"