You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently, trying to do so throws an error __init__ must be called when overriding __init__ (pybind/pybind11#2152), presumably because Policy has no constructor defined in policy.h. It looks like Game had the same issue, so a "trampoline class" was defined in open_spiel/python/pybind11/python_games.h. Would a similar solution should work for Policy?
The text was updated successfully, but these errors were encountered:
It would be nice if we could subclass pyspiel.Policy, and then pass those policies to pyspiel functions which expect pyspiel.Policys.
So something like this:
Currently, trying to do so throws an error
__init__ must be called when overriding __init__
(pybind/pybind11#2152), presumably becausePolicy
has no constructor defined inpolicy.h
. It looks likeGame
had the same issue, so a "trampoline class" was defined inopen_spiel/python/pybind11/python_games.h
. Would a similar solution should work forPolicy
?The text was updated successfully, but these errors were encountered: