Skip to content
Discussion options

You must be logged in to vote

Hi,
I noticed that given how the update function is implemented, all robots reaching level 9 are in the long term reassigned uniformly across levels

torch.randint_like(self.terrain_levels[env_ids], self.max_terrain_level),

It is easy to prove mathematically that the long term expectation is exactly 6, under the mild assumption that the transition probability across levels is the same.

If you want all robots to stay in level 9 once they reach it, simply replace the torch.where block in the function with a simple clip:

-        self.terrain_levels[env_ids] = torch.where(
-            self.te…

Replies: 3 comments 2 replies

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
1 reply
@pmorerio
Comment options

Answer selected by H-Hisamichi
Comment options

You must be logged in to vote
1 reply
@H-Hisamichi
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants
Converted from issue

This discussion was converted from issue #4714 on March 05, 2026 20:27.