Skip to content

Fix metric test failures #414

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

Merged
merged 3 commits into from
Feb 12, 2022

Conversation

Craigacp
Copy link
Collaborator

The TF 2.7.1 upgrade seems to have broken the behaviour of tf.random.randomUniform and friends. This causes several metric tests which used random inputs to fail due to incorrect shapes being passed in. I've replaced them all with tf.random.statelessRandomUniform which works correctly.

I'm not sure what the real root cause is here, as the TF 2.7.1 release notes don't mention any RNG changes. TF 2.8 is moving away from those RNG ops though, so maybe a backported security fix was a little too broad.

This PR also actually bumps to protobuf 3.19.4 (which is identical to 3.19.2 in the Java side of things, but is the latest version), and removes -XX:MaxPermSize=256m from the test command line arguments. The perm gen was removed in Java 8, the option is removed in Java 17 and so supplying it causes the test JVM to error out on startup.

@karllessard karllessard merged commit 5210c7e into tensorflow:master Feb 12, 2022
Craigacp added a commit to Craigacp/tensorflow-java that referenced this pull request Mar 10, 2022
* Migrate metric tests from randomUniform to statelessRandomUniform

* pom updates.

* Spotless changes.
karllessard pushed a commit that referenced this pull request Mar 26, 2022
* Bumping version for point release.

* Fix NullPointerException issue. (#407)

* Bumping to TF 2.7.1, protobuf 3.19.4, error-prone 2.10.0 (#412)

* Fix metric test failures (#414)

* Migrate metric tests from randomUniform to statelessRandomUniform


Co-authored-by: Frank Liu <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants