PennyLaneAI / qml

Introductions to key concepts in quantum programming, as well as tutorials and implementations from cutting-edge quantum computing research.
https://pennylane.ai/qml
Apache License 2.0
527 stars 185 forks source link

Update tutorial_How_to_optimize_QML_model_using_JAX_and_Optax.py #1052

Closed KetpuntoG closed 6 months ago

KetpuntoG commented 6 months ago

Solving issue #1045

As indicated in the issue, the optimizer being used within the update_step_jit function is not the one defined in the optimization_jit function. I tried to pass opt but it gave problems so I simply defined the optimizer outside.

In the case where jit is not being applied, I was able to pass the optimizer, so I updated those functions. Tagging @josh146 in case there is a better solution in this case

github-actions[bot] commented 6 months ago

👋 Hey, looks like you've updated some demos!

🐘 Don't forget to update the dateOfLastModification in the associated metadata files so your changes show up on pennylane.ai.

Please hide this comment once the field(s) are updated. Thanks!

github-actions[bot] commented 6 months ago

Thank you for opening this pull request.

You can find the built site at this link.

Deployment Info:

Note: It may take several minutes for updates to this pull request to be reflected on the deployed site.