Unused Exploration Bonus

This commit is contained in:
2026-08-03 22:58:27 +02:00
parent 9d2e001ea4
commit 766f2855da
+10
View File
@@ -78,6 +78,15 @@ class JackBotEnv(gym.Env):
self.target_height = 0.14 self.target_height = 0.14
self.collapse_height_fraction = 0.55 self.collapse_height_fraction = 0.55
self.tilt_failure_rad = 0.9 self.tilt_failure_rad = 0.9
# Small random exploration pulse to break local optima.
# The bonus is only granted on a rare step and only when the robot
# is still stable enough that a bold move is likely to remain safe.
self.exploration_bonus_prob = 0.03
self.exploration_bonus_interval = 120
self.exploration_bonus_scale = 0.08
self.exploration_bonus_active = False
self.start_positions = [[0.0, 0.0, 0.0]] self.start_positions = [[0.0, 0.0, 0.0]]
self.max_distance_from_start = [0.0] self.max_distance_from_start = [0.0]
self.max_survival_steps = 0 self.max_survival_steps = 0
@@ -157,6 +166,7 @@ class JackBotEnv(gym.Env):
self.last_action = np.zeros(self.action_space.shape[0], dtype=np.float32) self.last_action = np.zeros(self.action_space.shape[0], dtype=np.float32)
self.max_distance_from_start = [0.0] self.max_distance_from_start = [0.0]
self.max_survival_steps = 0 self.max_survival_steps = 0
self.exploration_bonus_active = False
if self._first_reset: if self._first_reset:
self.curriculum_phase = 0 self.curriculum_phase = 0