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

Use jnp.nanmin and jnp.nanmax in jax.experimental.ode.optimal_step_size #14624

Closed
wants to merge 1 commit into from

Conversation

virajpandya
Copy link

This simple bug fix prevents jax.experimental.ode.odeint from getting stuck on NaN's if a trial adaptive stepsize led to a NaN for mean_error_ratio.

See the following discussions for more info:
#14612
patrick-kidger/diffrax#223

This bug fix prevents jax.experimental.ode.odeint from getting stuck on NaN's if a trial adaptive stepsize led to a NaN for mean_error_ratio.
@google-cla
Copy link

google-cla bot commented Feb 22, 2023

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.

Copy link
Collaborator

@jakevdp jakevdp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good! Is there a simple case you could add as a test in tests/ode_test.py?

@jakevdp jakevdp self-assigned this Feb 22, 2023
@jakevdp
Copy link
Collaborator

jakevdp commented Nov 3, 2023

I'm going to close this because it seems to have gone stale. If you'd like to continue with this contribution, feel free to re-open and add a test!

@jakevdp jakevdp closed this Nov 3, 2023
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