pennylane
pennylane copied to clipboard
PennyLane is a cross-platform Python library for quantum computing, quantum machine learning, and quantum chemistry. Train a quantum computer the same way as a neural network.
### Before submitting Please complete the following checklist when submitting a PR: - [x] All new features must include a unit test. If you've fixed a bug or added code...
### Expected behavior Works without problems. ### Actual behavior Error. More info below. ### Additional information As you can see in the source code; tracing out qubits, the mixed device...
[sc-56106] **Context:** The new device interface allows devices to support a variety of device gradient methods, each with different requirements on the circuit. For example, backprop is considered `"best"` for...
### Before submitting Please complete the following checklist when submitting a PR: - [x] All new features must include a unit test. If you've fixed a bug or added code...
### Expected behavior In test/devices/qubit/test_measure.py TestSumOfTermsDifferentiability.expected(scale, coeffs, n_wires) with n_wires not even should give: ```phase = offset + scale * qml.math.asarray(range(n_wires), like=like) cosines = qml.math.cos(phase) sines = -qml.math.sin(phase) return coeffs[0]...
### Feature details I know that for now we don't have qudit devices, but we already have qubit and qutrit devices, but we can only use qubits interacting with qubits...
**Context:** It would be nice to have a function to calculate the expectation values of an operator $A$ given a state vector $\vert\psi\rangle$. This can be also used for computing...
**Context:** Measurement process constructor functions (`qml.sample`, `qml.probs`, etc) are inconsistent with respect to the order of the arguments given to them, which causes problems like potentially using observables as wires....
### Expected behavior This toy example should return [1,0] ```python import pennylane as qml dev = qml.device("default.qubit") @qml.qnode(dev) def circuit(): qml.measure(wires = "my wire") return qml.probs(wires = "my wire") circuit()...
**Context:** `defer_measurements` had some restrictions added to it due to the changes needed for the new features that have been added. This includes not supporting custom wire labels, and some...