Skip to content

Commit

Permalink
fix: termination condition (#266)
Browse files Browse the repository at this point in the history
  • Loading branch information
WiemKhlifi authored Nov 25, 2024
1 parent e959bf3 commit 1ec8808
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion jumanji/wrappers.py
Original file line number Diff line number Diff line change
Expand Up @@ -617,7 +617,7 @@ def step(
) -> Tuple[State, Observation, chex.Array, chex.Array, chex.Array, Optional[Any]]:
"""Step function of a Jumanji environment to be jitted."""
state, timestep = self._env.step(state, action)
term = timestep.discount.astype(bool)
term = ~timestep.discount.astype(bool)
trunc = timestep.last().astype(bool)
return state, timestep.observation, timestep.reward, term, trunc, timestep.extras

Expand Down

0 comments on commit 1ec8808

Please sign in to comment.