Skip to content

Commit

Permalink
Fix exception causes in abstract_meta_trainer.py
Browse files Browse the repository at this point in the history
  • Loading branch information
cool-RR authored Dec 8, 2022
1 parent 49d3036 commit 667aa25
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions open_spiel/python/algorithms/psro_v2/abstract_meta_trainer.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,11 +47,12 @@ def _process_string_or_callable(string_or_callable, dictionary):

try:
return dictionary[string_or_callable]
except KeyError:
except KeyError as e:
raise NotImplementedError("Input type / value not supported. Accepted types"
": string, callable. Acceptable string values : "
"{}. Input provided : {}".format(
list(dictionary.keys()), string_or_callable))
list(dictionary.keys()),
string_or_callable)) from e


def sample_episode(state, policies):
Expand Down

0 comments on commit 667aa25

Please sign in to comment.