Skip to content

Commit

Permalink
Fix is_finite_mdp
Browse files Browse the repository at this point in the history
  • Loading branch information
eleurent committed Jan 31, 2023
1 parent b0803fb commit 35216ba
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion rl_agents/agents/dynamic_programming/value_iteration.py
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ def fixed_point_iteration(self, operator, initial):
def is_finite_mdp(env):
try:
finite_mdp = __import__("finite_mdp.envs.finite_mdp_env")
if isinstance(env, finite_mdp.envs.finite_mdp_env.FiniteMDPEnv):
if isinstance(env.unwrapped, finite_mdp.envs.finite_mdp_env.FiniteMDPEnv):
return True
except (ModuleNotFoundError, TypeError):
return False
Expand Down

0 comments on commit 35216ba

Please sign in to comment.