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

[BUG] Various demos raising jax deprecation warnings #1180

Open
albi3ro opened this issue Aug 6, 2024 · 0 comments
Open

[BUG] Various demos raising jax deprecation warnings #1180

albi3ro opened this issue Aug 6, 2024 · 0 comments

Comments

@albi3ro
Copy link
Contributor

albi3ro commented Aug 6, 2024

Various demos are raising jax deprecation warnings. While they continue to run for now, these demos will fail in the future when jax completes their deprecation cycles. We need to head off these deprecation warnings and fix them.

The demos that raise deprecations include, but are not limited to:

https://pennylane.ai/qml/demos/tutorial_implicit_diff_susceptibility/#implicit-differentiation-of-ground-states-in-pennylane

https://pennylane.ai/qml/demos/tutorial_jax_transformations/

Which both warn:

/home/runner/work/qml/qml/demonstrations/tutorial_implicit_diff_susceptibility.py:266: DeprecationWarning: Accessing jax.config via the jax.config submodule is deprecated.
  from jax.config import config

And:

https://pennylane.ai/qml/demos/tutorial_optimal_control/

which warns

/home/runner/work/qml/qml/demonstrations/tutorial_optimal_control.py:506: DeprecationWarning: hstack requires ndarray or scalar arguments, got <class 'list'> at position 0. In a future JAX release this will be an error.
  params = [jnp.hstack([[0.1 * (-1) ** i for i in range(P)], time]) for time in times]

These are just the demos I manually checked. Other demos may also be raising deprecation warnings uncaught.

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

No branches or pull requests

1 participant