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

JAX internal functions must take a non-empty core.DebugInfo. #26480

Open
gnecula opened this issue Feb 12, 2025 · 0 comments
Open

JAX internal functions must take a non-empty core.DebugInfo. #26480

gnecula opened this issue Feb 12, 2025 · 0 comments
Assignees
Labels
better_errors Improve the error reporting

Comments

@gnecula
Copy link
Collaborator

gnecula commented Feb 12, 2025

Description

As part of improving JAX error messages we ensure that a core.DebugInfo object is passed to all calls to linear_util.wrap_init and to the core.Jaxpr constructor. We have made the necessary changes into the JAX core code base (e.g., #26078, #26313, #26348, and several other PRs).

There are still a number of other projects that invoke directly these functions (and other helper functions that now must take core.DebugInfo). Note that only JAX-internal functions take a core.DebugInfo; this change does not affect projects that use only public APIs.

For a limited time, a DeprecationWarning is printed if jax.extend.linear_util.wrap_init is used without debugging info.

To obtain a core.DebugInfo, one can call api_util.debug_info, or retrieve the debug_info fields of lu.WrappedFun or core.Jaxpr.

System info (python version, jaxlib version, accelerator, etc.)

N/A

@gnecula gnecula added the bug Something isn't working label Feb 12, 2025
@gnecula gnecula self-assigned this Feb 12, 2025
@gnecula gnecula added better_errors Improve the error reporting and removed bug Something isn't working labels Feb 12, 2025
copybara-service bot pushed a commit to jax-ml/oryx that referenced this issue Feb 12, 2025
Now all internal uses of lu.wrap_init and core.Jaxpr are with actual
debug info. This enables us to clean up the type declarations and
to remove the checks whether debug_info is present.

For usage outside of the JAX internals, we change
`jax.extend.linear_util.wrap_init` to be usable without debug_info,
for temporary backwards compatibility. We emit a deprecation
warning and fill-in some fake debugging info.

See jax-ml/jax#26480 for more details.

PiperOrigin-RevId: 725512692
copybara-service bot pushed a commit that referenced this issue Feb 12, 2025
Now all internal uses of lu.wrap_init and core.Jaxpr are with actual
debug info. This enables us to clean up the type declarations and
to remove the checks whether debug_info is present.

For usage outside of the JAX internals, we change
`jax.extend.linear_util.wrap_init` to be usable without debug_info,
for temporary backwards compatibility. We emit a deprecation
warning and fill-in some fake debugging info.

See #26480 for more details.

PiperOrigin-RevId: 725512692
copybara-service bot pushed a commit to jax-ml/oryx that referenced this issue Feb 12, 2025
See jax-ml/jax#26480.

PiperOrigin-RevId: 725953448
copybara-service bot pushed a commit that referenced this issue Feb 12, 2025
Now all internal uses of lu.wrap_init and core.Jaxpr are with actual
debug info. This enables us to clean up the type declarations and
to remove the checks whether debug_info is present.

For usage outside of the JAX internals, we change
`jax.extend.linear_util.wrap_init` to be usable without debug_info,
for temporary backwards compatibility. We emit a deprecation
warning and fill-in some fake debugging info.

See #26480 for more details.

PiperOrigin-RevId: 725512692
copybara-service bot pushed a commit to jax-ml/oryx that referenced this issue Feb 12, 2025
Now all internal uses of lu.wrap_init and core.Jaxpr are with actual
debug info. This enables us to clean up the type declarations and
to remove the checks whether debug_info is present.

For usage outside of the JAX internals, we change
`jax.extend.linear_util.wrap_init` to be usable without debug_info,
for temporary backwards compatibility. We emit a deprecation
warning and fill-in some fake debugging info.

See jax-ml/jax#26480 for more details.

PiperOrigin-RevId: 725512692
copybara-service bot pushed a commit that referenced this issue Feb 12, 2025
Now all internal uses of lu.wrap_init and core.Jaxpr are with actual
debug info. This enables us to clean up the type declarations and
to remove the checks whether debug_info is present.

For usage outside of the JAX internals, we change
`jax.extend.linear_util.wrap_init` to be usable without debug_info,
for temporary backwards compatibility. We emit a deprecation
warning and fill-in some fake debugging info.

See #26480 for more details.

PiperOrigin-RevId: 725512692
copybara-service bot pushed a commit to jax-ml/oryx that referenced this issue Feb 12, 2025
See jax-ml/jax#26480.

PiperOrigin-RevId: 725953448
copybara-service bot pushed a commit that referenced this issue Feb 12, 2025
See #26480.

PiperOrigin-RevId: 725953448
copybara-service bot pushed a commit to jax-ml/oryx that referenced this issue Feb 12, 2025
See jax-ml/jax#26480.

PiperOrigin-RevId: 725953448
copybara-service bot pushed a commit that referenced this issue Feb 12, 2025
See #26480.

PiperOrigin-RevId: 725953448
copybara-service bot pushed a commit to jax-ml/oryx that referenced this issue Feb 12, 2025
Now all internal uses of lu.wrap_init and core.Jaxpr are with actual
debug info. This enables us to clean up the type declarations and
to remove the checks whether debug_info is present.

For usage outside of the JAX internals, we change
`jax.extend.linear_util.wrap_init` to be usable without debug_info,
for temporary backwards compatibility. We emit a deprecation
warning and fill-in some fake debugging info.

See jax-ml/jax#26480 for more details.

PiperOrigin-RevId: 725512692
copybara-service bot pushed a commit that referenced this issue Feb 12, 2025
Now all internal uses of lu.wrap_init and core.Jaxpr are with actual
debug info. This enables us to clean up the type declarations and
to remove the checks whether debug_info is present.

For usage outside of the JAX internals, we change
`jax.extend.linear_util.wrap_init` to be usable without debug_info,
for temporary backwards compatibility. We emit a deprecation
warning and fill-in some fake debugging info.

See #26480 for more details.

PiperOrigin-RevId: 725512692
copybara-service bot pushed a commit to jax-ml/oryx that referenced this issue Feb 12, 2025
Now all internal uses of lu.wrap_init and core.Jaxpr are with actual
debug info. This enables us to clean up the type declarations and
to remove the checks whether debug_info is present.

For usage outside of the JAX internals, we change
`jax.extend.linear_util.wrap_init` to be usable without debug_info,
for temporary backwards compatibility. We emit a deprecation
warning and fill-in some fake debugging info.

See jax-ml/jax#26480 for more details.

PiperOrigin-RevId: 725512692
copybara-service bot pushed a commit that referenced this issue Feb 12, 2025
Now all internal uses of lu.wrap_init and core.Jaxpr are with actual
debug info. This enables us to clean up the type declarations and
to remove the checks whether debug_info is present.

For usage outside of the JAX internals, we change
`jax.extend.linear_util.wrap_init` to be usable without debug_info,
for temporary backwards compatibility. We emit a deprecation
warning and fill-in some fake debugging info.

See #26480 for more details.

PiperOrigin-RevId: 725512692
copybara-service bot pushed a commit to jax-ml/oryx that referenced this issue Feb 12, 2025
See jax-ml/jax#26480.

PiperOrigin-RevId: 725953448
copybara-service bot pushed a commit that referenced this issue Feb 12, 2025
See #26480.

PiperOrigin-RevId: 725953448
copybara-service bot pushed a commit to jax-ml/oryx that referenced this issue Feb 12, 2025
Now all internal uses of lu.wrap_init and core.Jaxpr are with actual
debug info. This enables us to clean up the type declarations and
to remove the checks whether debug_info is present.

For usage outside of the JAX internals, we change
`jax.extend.linear_util.wrap_init` to be usable without debug_info,
for temporary backwards compatibility. We emit a deprecation
warning and fill-in some fake debugging info.

See jax-ml/jax#26480 for more details.

PiperOrigin-RevId: 725512692
copybara-service bot pushed a commit that referenced this issue Feb 12, 2025
Now all internal uses of lu.wrap_init and core.Jaxpr are with actual
debug info. This enables us to clean up the type declarations and
to remove the checks whether debug_info is present.

For usage outside of the JAX internals, we change
`jax.extend.linear_util.wrap_init` to be usable without debug_info,
for temporary backwards compatibility. We emit a deprecation
warning and fill-in some fake debugging info.

See #26480 for more details.

PiperOrigin-RevId: 725512692
copybara-service bot pushed a commit to jax-ml/oryx that referenced this issue Feb 12, 2025
See jax-ml/jax#26480.

PiperOrigin-RevId: 725953448
copybara-service bot pushed a commit that referenced this issue Feb 12, 2025
See #26480.

PiperOrigin-RevId: 725953448
copybara-service bot pushed a commit to jax-ml/oryx that referenced this issue Feb 12, 2025
See jax-ml/jax#26480.

PiperOrigin-RevId: 725953448
copybara-service bot pushed a commit that referenced this issue Feb 12, 2025
See #26480.

PiperOrigin-RevId: 725953448
copybara-service bot pushed a commit to jax-ml/oryx that referenced this issue Feb 13, 2025
See jax-ml/jax#26480.

PiperOrigin-RevId: 725953448
copybara-service bot pushed a commit that referenced this issue Feb 13, 2025
See #26480.

PiperOrigin-RevId: 725953448
copybara-service bot pushed a commit to jax-ml/oryx that referenced this issue Feb 13, 2025
See jax-ml/jax#26480.

PiperOrigin-RevId: 725953448
copybara-service bot pushed a commit that referenced this issue Feb 13, 2025
See #26480.

PiperOrigin-RevId: 725953448
copybara-service bot pushed a commit to jax-ml/oryx that referenced this issue Feb 13, 2025
See jax-ml/jax#26480.

PiperOrigin-RevId: 725953448
copybara-service bot pushed a commit that referenced this issue Feb 13, 2025
See #26480.

PiperOrigin-RevId: 725953448
copybara-service bot pushed a commit to jax-ml/oryx that referenced this issue Feb 13, 2025
See jax-ml/jax#26480.

PiperOrigin-RevId: 725953448
copybara-service bot pushed a commit that referenced this issue Feb 13, 2025
See #26480.

PiperOrigin-RevId: 725953448
copybara-service bot pushed a commit to jax-ml/oryx that referenced this issue Feb 13, 2025
See jax-ml/jax#26480.

PiperOrigin-RevId: 725953448
copybara-service bot pushed a commit that referenced this issue Feb 13, 2025
See #26480.

PiperOrigin-RevId: 725953448
copybara-service bot pushed a commit to jax-ml/oryx that referenced this issue Feb 13, 2025
See jax-ml/jax#26480.

PiperOrigin-RevId: 725953448
copybara-service bot pushed a commit that referenced this issue Feb 13, 2025
See #26480.

PiperOrigin-RevId: 725953448
copybara-service bot pushed a commit that referenced this issue Feb 13, 2025
See #26480.

PiperOrigin-RevId: 726437113
copybara-service bot pushed a commit to jax-ml/oryx that referenced this issue Feb 13, 2025
See jax-ml/jax#26480.

PiperOrigin-RevId: 726437113
copybara-service bot pushed a commit that referenced this issue Feb 13, 2025
Now all internal uses of lu.wrap_init and core.Jaxpr are with actual
debug info. This enables us to clean up the type declarations and
to remove the checks whether debug_info is present.

For usage outside of the JAX internals, we change
`jax.extend.linear_util.wrap_init` to be usable without debug_info,
for temporary backwards compatibility. We emit a deprecation
warning and fill-in some fake debugging info.

See #26480 for more details.

PiperOrigin-RevId: 725512692
copybara-service bot pushed a commit that referenced this issue Feb 14, 2025
Now all internal uses of lu.wrap_init and core.Jaxpr are with actual
debug info. This enables us to clean up the type declarations and
to remove the checks whether debug_info is present.

For usage outside of the JAX internals, we change
`jax.extend.linear_util.wrap_init` to be usable without debug_info,
for temporary backwards compatibility. We emit a deprecation
warning and fill-in some fake debugging info.

See #26480 for more details.

PiperOrigin-RevId: 725512692
copybara-service bot pushed a commit that referenced this issue Feb 14, 2025
Now all internal uses of lu.wrap_init and core.Jaxpr are with actual
debug info. This enables us to clean up the type declarations and
to remove the checks whether debug_info is present.

For usage outside of the JAX internals, we change
`jax.extend.linear_util.wrap_init` to be usable without debug_info,
for temporary backwards compatibility. We emit a deprecation
warning and fill-in some fake debugging info.

See #26480 for more details.

PiperOrigin-RevId: 726770483
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
better_errors Improve the error reporting
Projects
None yet
Development

No branches or pull requests

1 participant