Skip to content

fix: warn when Hutchinson estimator uses fixed PRNGKey(0) - #1738

Open
wahid18-maqs wants to merge 3 commits into
google-deepmind:mainfrom
wahid18-maqs:fix/hutchinson-prngkey-warning
Open

fix: warn when Hutchinson estimator uses fixed PRNGKey(0)#1738
wahid18-maqs wants to merge 3 commits into
google-deepmind:mainfrom
wahid18-maqs:fix/hutchinson-prngkey-warning

Conversation

@wahid18-maqs

Copy link
Copy Markdown

Summary

This PR adds a warning when hutchinson_estimator_diag_hessian is initialized without a random_seed.

Changes

  • Emit a warning when random_seed=None.
  • Clarify that the default PRNGKey(0) produces identical random vectors across runs.
  • Encourage users to provide a unique random_seed for independent experiments.

This change preserves the existing behavior while making the deterministic default explicit to users.

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.

1 participant