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

Update pennylane requirement from ~=0.36.0 to ~=0.37.0 #2445

Closed
wants to merge 1 commit into from

Conversation

dependabot[bot]
Copy link
Contributor

@dependabot dependabot bot commented on behalf of github Jul 9, 2024

Updates the requirements on pennylane to permit the latest version.

Release notes

Sourced from pennylane's releases.

Release 0.37.0

  • A new default.tensor device is now available for performing tensor network and matrix product state simulations of quantum circuits using the quimb backend. [(#5699)](PennyLaneAI/pennylane#5699) [(#5744)](PennyLaneAI/pennylane#5744) [(#5786)](PennyLaneAI/pennylane#5786) [(#5795)](PennyLaneAI/pennylane#5795)

    Either method can be selected when instantiating the default.tensor device by setting the method keyword argument to "tn" (tensor network) or "mps" (matrix product state).

    There are several templates in PennyLane that are tensor-network focused, which are excellent candidates for the "tn" method for default.tensor. The following example shows how a circuit comprising gates in a tree tensor network architecture can be efficiently simulated using method="tn".

    import pennylane as qml
    n_wires = 16
    dev = qml.device("default.tensor", method="tn")
    def block(weights, wires):
    qml.CNOT(wires=[wires[0], wires[1]])
    qml.RY(weights[0], wires=wires[0])
    qml.RY(weights[1], wires=wires[1])
    n_block_wires = 2
    n_params_block = 2
    n_blocks = qml.TTN.get_n_blocks(range(n_wires), n_block_wires)
    template_weights = [[0.1, -0.3]] * n_blocks
    @​qml.qnode(dev)
    def circuit(template_weights):
    for i in range(n_wires):
    qml.Hadamard(i)
    qml.TTN(range(n_wires), n_block_wires, block, n_params_block, template_weights)
    return qml.expval(qml.Z(n_wires - 1))

    >>> circuit(template_weights)
    0.3839174759751649

    For matrix product state simulations (method="mps"), we can make the execution be approximate by setting max_bond_dim (see the device's documentation for more details). The maximum bond dimension has implications for the speed of the simulation and lets us control the degree of the approximation, as shown in the following example. First, set up the circuit:

    import numpy as np
    n_layers = 10
    n_wires = 10
    initial_shape, weights_shape = qml.SimplifiedTwoDesign.shape(n_layers, n_wires)
    np.random.seed(1967)

... (truncated)

Commits

You can trigger a rebase of this PR by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

Note
Automatic rebases have been disabled on this pull request as it has been open for over 30 days.

Updates the requirements on [pennylane](https://github.com/PennyLaneAI/pennylane) to permit the latest version.
- [Release notes](https://github.com/PennyLaneAI/pennylane/releases)
- [Commits](PennyLaneAI/pennylane@v0.36.0...v0.37.0)

---
updated-dependencies:
- dependency-name: pennylane
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
@dependabot dependabot bot added the infrastructure For issues related to building, packaging, and continuous integration. label Jul 9, 2024
Copy link
Contributor Author

dependabot bot commented on behalf of github Sep 4, 2024

Superseded by #2492.

@dependabot dependabot bot closed this Sep 4, 2024
@dependabot dependabot bot deleted the dependabot/pip/pennylane-approx-eq-0.37.0 branch September 4, 2024 05:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
infrastructure For issues related to building, packaging, and continuous integration.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

0 participants