We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
qml.TShift
Raising a TShift operator to the power of 2 should return something.
TShift
The current implementation of pow on the TShift operator is given by
pow
def pow(self, z): return super().pow(z % 3)
which calls the pow method on the Operator class, given by
Operator
if z == 0: return [] if z == 1: if QueuingManager.recording(): return [qml.apply(self)] return [copy.copy(self)] raise PowUndefinedError
So, attempting to raise a TShift to the power of 2 results in a PowUndefinedError.
2
PowUndefinedError
No response
Name: PennyLane Version: 0.39.0.dev25 Summary: 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. Home-page: https://github.com/PennyLaneAI/pennylane Author: Author-email: License: Apache License 2.0 Location: /home/william.maxwell/venvs/pl-py3.10/lib/python3.10/site-packages Editable project location: /home/william.maxwell/pennylane/pennylane Requires: appdirs, autograd, autoray, cachetools, networkx, numpy, packaging, pennylane-lightning, requests, rustworkx, scipy, toml, typing-extensions Required-by: amazon-braket-pennylane-plugin, PennyLane-Catalyst, PennyLane_Lightning, PennyLane_Lightning_Kokkos Platform info: Linux-6.8.0-45-generic-x86_64-with-glibc2.35 Python version: 3.10.12 Numpy version: 1.26.4 Scipy version: 1.12.0 Installed devices: - lightning.qubit (PennyLane_Lightning-0.39.0.dev24) - default.clifford (PennyLane-0.39.0.dev25) - default.gaussian (PennyLane-0.39.0.dev25) - default.mixed (PennyLane-0.39.0.dev25) - default.qubit (PennyLane-0.39.0.dev25) - default.qutrit (PennyLane-0.39.0.dev25) - default.qutrit.mixed (PennyLane-0.39.0.dev25) - default.tensor (PennyLane-0.39.0.dev25) - null.qubit (PennyLane-0.39.0.dev25) - reference.qubit (PennyLane-0.39.0.dev25) - lightning.kokkos (PennyLane_Lightning_Kokkos-0.39.0.dev24) - nvidia.custatevec (PennyLane-Catalyst-0.9.0.dev12) - nvidia.cutensornet (PennyLane-Catalyst-0.9.0.dev12) - oqc.cloud (PennyLane-Catalyst-0.9.0.dev12) - softwareq.qpp (PennyLane-Catalyst-0.9.0.dev12) - braket.aws.ahs (amazon-braket-pennylane-plugin-1.30.1) - braket.aws.qubit (amazon-braket-pennylane-plugin-1.30.1) - braket.local.ahs (amazon-braket-pennylane-plugin-1.30.1) - braket.local.qubit (amazon-braket-pennylane-plugin-1.30.1)
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Expected behavior
Raising a
TShift
operator to the power of 2 should return something.Actual behavior
The current implementation of
pow
on theTShift
operator is given bywhich calls the
pow
method on theOperator
class, given bySo, attempting to raise a
TShift
to the power of2
results in aPowUndefinedError
.Additional information
No response
Source code
No response
Tracebacks
No response
System information
Name: PennyLane Version: 0.39.0.dev25 Summary: 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. Home-page: https://github.com/PennyLaneAI/pennylane Author: Author-email: License: Apache License 2.0 Location: /home/william.maxwell/venvs/pl-py3.10/lib/python3.10/site-packages Editable project location: /home/william.maxwell/pennylane/pennylane Requires: appdirs, autograd, autoray, cachetools, networkx, numpy, packaging, pennylane-lightning, requests, rustworkx, scipy, toml, typing-extensions Required-by: amazon-braket-pennylane-plugin, PennyLane-Catalyst, PennyLane_Lightning, PennyLane_Lightning_Kokkos Platform info: Linux-6.8.0-45-generic-x86_64-with-glibc2.35 Python version: 3.10.12 Numpy version: 1.26.4 Scipy version: 1.12.0 Installed devices: - lightning.qubit (PennyLane_Lightning-0.39.0.dev24) - default.clifford (PennyLane-0.39.0.dev25) - default.gaussian (PennyLane-0.39.0.dev25) - default.mixed (PennyLane-0.39.0.dev25) - default.qubit (PennyLane-0.39.0.dev25) - default.qutrit (PennyLane-0.39.0.dev25) - default.qutrit.mixed (PennyLane-0.39.0.dev25) - default.tensor (PennyLane-0.39.0.dev25) - null.qubit (PennyLane-0.39.0.dev25) - reference.qubit (PennyLane-0.39.0.dev25) - lightning.kokkos (PennyLane_Lightning_Kokkos-0.39.0.dev24) - nvidia.custatevec (PennyLane-Catalyst-0.9.0.dev12) - nvidia.cutensornet (PennyLane-Catalyst-0.9.0.dev12) - oqc.cloud (PennyLane-Catalyst-0.9.0.dev12) - softwareq.qpp (PennyLane-Catalyst-0.9.0.dev12) - braket.aws.ahs (amazon-braket-pennylane-plugin-1.30.1) - braket.aws.qubit (amazon-braket-pennylane-plugin-1.30.1) - braket.local.ahs (amazon-braket-pennylane-plugin-1.30.1) - braket.local.qubit (amazon-braket-pennylane-plugin-1.30.1)
Existing GitHub issues
The text was updated successfully, but these errors were encountered: