Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix RCFR test and example to work with Keras 3 #1265

Merged
merged 4 commits into from
Aug 20, 2024

Conversation

dmorrill10
Copy link
Contributor

Fixes #1207 by replacing lr with learning_rate and replacing calls to minimize, which is no longer present in tf.keras.optimizers.Adam. The test_rcfr_functions was flaky so I also increased the size of the model to get the test to pass.

With this patch, python open_spiel/python/algorithms/rcfr_test.py should now pass and python open_spiel/python/examples/rcfr_example.py runs without error.

Copy link

google-cla bot commented Aug 18, 2024

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

@lanctot
Copy link
Collaborator

lanctot commented Aug 19, 2024

Awesome, thanks!

Can you remove this comment:

# Broken in Python 3.12. Must port to Keras 3. https://github.com/google-deepmind/open_spiel/issues/1207.

and uncomment the next line, so that the rcfr_test is re-enabled and we can run it on Github Actions CI?

@lanctot
Copy link
Collaborator

lanctot commented Aug 19, 2024

CI test failing for an unrelated reason, will fix and update master first.

@lanctot
Copy link
Collaborator

lanctot commented Aug 19, 2024

CI test failing for an unrelated reason, will fix and update master first.

Fixed now. (by #1267, which was merged.)

So if you pull from master and re-enable the test we'll see if it passes on Github Actions.

@lanctot lanctot added imported This PR has been imported and awaiting internal review. Please avoid any more local changes, thanks! merged internally The code is now submitted to our internal repo and will be merged in the next github sync. labels Aug 20, 2024
@lanctot lanctot merged commit 5a1f76f into google-deepmind:master Aug 20, 2024
10 checks passed
@dmorrill10 dmorrill10 deleted the fix-rcfr-for-keras-3 branch August 20, 2024 19:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
imported This PR has been imported and awaiting internal review. Please avoid any more local changes, thanks! merged internally The code is now submitted to our internal repo and will be merged in the next github sync.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Problem with RCFR using Keras 3
2 participants