pennylane-qrack 0.10.2__py3-none-macosx_15_0_arm64.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of pennylane-qrack might be problematic. Click here for more details.
- pennylane_qrack/CMakeCache.txt +394 -0
- pennylane_qrack/Makefile +230 -0
- pennylane_qrack/QrackDeviceConfig.toml +155 -0
- pennylane_qrack/__init__.py +16 -0
- pennylane_qrack/_version.py +19 -0
- pennylane_qrack/cmake_install.cmake +74 -0
- pennylane_qrack/libqrack_device.dylib +0 -0
- pennylane_qrack/qrack_device.cpp +858 -0
- pennylane_qrack/qrack_device.py +711 -0
- pennylane_qrack-0.10.2.dist-info/LICENSE +201 -0
- pennylane_qrack-0.10.2.dist-info/METADATA +142 -0
- pennylane_qrack-0.10.2.dist-info/RECORD +15 -0
- pennylane_qrack-0.10.2.dist-info/WHEEL +5 -0
- pennylane_qrack-0.10.2.dist-info/entry_points.txt +2 -0
- pennylane_qrack-0.10.2.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,155 @@
|
|
|
1
|
+
# Which version of the specification format is being used.
|
|
2
|
+
schema = 2
|
|
3
|
+
|
|
4
|
+
# The union of all gate types listed in this section must match what
|
|
5
|
+
# the device considers "supported" through PennyLane's device API.
|
|
6
|
+
# The gate definition has the following format:
|
|
7
|
+
#
|
|
8
|
+
# GATE = { properties = [ PROPS ], condition = [ COND ] }
|
|
9
|
+
#
|
|
10
|
+
# Where:
|
|
11
|
+
#
|
|
12
|
+
# PROPS: zero or more comma-separated quoted strings:
|
|
13
|
+
# "controllable", "invertible", "differentiable"
|
|
14
|
+
# COND: quoted string, on of:
|
|
15
|
+
# "analytic", "finiteshots"
|
|
16
|
+
#
|
|
17
|
+
[operators.gates.native]
|
|
18
|
+
|
|
19
|
+
PauliX = { properties = [ "controllable", "invertible"] }
|
|
20
|
+
PauliY = { properties = [ "controllable", "invertible"] }
|
|
21
|
+
PauliZ = { properties = [ "controllable", "invertible"] }
|
|
22
|
+
SX = { properties = [ "controllable", "invertible"] }
|
|
23
|
+
MultiRZ = { properties = [ "controllable", "invertible" ] }
|
|
24
|
+
Hadamard = { properties = [ "controllable", "invertible"] }
|
|
25
|
+
S = { properties = [ "controllable", "invertible" ] }
|
|
26
|
+
T = { properties = [ "controllable", "invertible" ] }
|
|
27
|
+
CNOT = { properties = [ "controllable", "invertible" ] }
|
|
28
|
+
SWAP = { properties = [ "controllable", "invertible" ] }
|
|
29
|
+
CSWAP = { properties = [ "controllable", "invertible" ] }
|
|
30
|
+
ISWAP = { properties = [ "controllable", "invertible"] }
|
|
31
|
+
PSWAP = { properties = [ "controllable", "invertible"] }
|
|
32
|
+
Toffoli = { properties = [ "controllable", "invertible" ] }
|
|
33
|
+
CY = { properties = [ "controllable", "invertible" ] }
|
|
34
|
+
CZ = { properties = [ "controllable", "invertible" ] }
|
|
35
|
+
PhaseShift = { properties = [ "controllable", "invertible" ] }
|
|
36
|
+
ControlledPhaseShift = { properties = [ "controllable", "invertible" ] }
|
|
37
|
+
CPhase = { properties = [ "controllable", "invertible" ] }
|
|
38
|
+
RX = { properties = [ "controllable", "invertible" ] }
|
|
39
|
+
RY = { properties = [ "controllable", "invertible" ] }
|
|
40
|
+
RZ = { properties = [ "controllable", "invertible" ] }
|
|
41
|
+
Rot = { properties = [ "controllable", "invertible" ] }
|
|
42
|
+
CRX = { properties = [ "controllable", "invertible" ] }
|
|
43
|
+
CRY = { properties = [ "controllable", "invertible" ] }
|
|
44
|
+
CRZ = { properties = [ "controllable", "invertible" ] }
|
|
45
|
+
CRot = { properties = [ "controllable", "invertible" ] }
|
|
46
|
+
U3 = { properties = [ "controllable", "invertible" ] }
|
|
47
|
+
MultiControlledX = { properties = [ "controllable", "invertible" ] }
|
|
48
|
+
Identity = { properties = [ "controllable", "invertible" ] }
|
|
49
|
+
|
|
50
|
+
# Operators that should be decomposed according to the algorithm used
|
|
51
|
+
# by PennyLane's device API.
|
|
52
|
+
# Optional, since gates not listed in this list will typically be decomposed by
|
|
53
|
+
# default, but can be useful to express a deviation from this device's regular
|
|
54
|
+
# strategy in PennyLane.
|
|
55
|
+
# [operators.gates.decomp]
|
|
56
|
+
|
|
57
|
+
# QubitUnitary = {}
|
|
58
|
+
# SISWAP = {}
|
|
59
|
+
# SQISW = {}
|
|
60
|
+
# BasisState = {}
|
|
61
|
+
# QubitStateVector = {}
|
|
62
|
+
# StatePrep = {}
|
|
63
|
+
# ControlledQubitUnitary = {}
|
|
64
|
+
# DiagonalQubitUnitary = {}
|
|
65
|
+
# SingleExcitation = {}
|
|
66
|
+
# SingleExcitationPlus = {}
|
|
67
|
+
# SingleExcitationMinus = {}
|
|
68
|
+
# DoubleExcitation = {}
|
|
69
|
+
# DoubleExcitationPlus = {}
|
|
70
|
+
# DoubleExcitationMinus = {}
|
|
71
|
+
# QubitCarry = {}
|
|
72
|
+
# QubitSum = {}
|
|
73
|
+
# OrbitalRotation = {}
|
|
74
|
+
# ECR = {}
|
|
75
|
+
# IsingXX = {}
|
|
76
|
+
# IsingYY = {}
|
|
77
|
+
# IsingZZ = {}
|
|
78
|
+
# IsingXY = {}
|
|
79
|
+
# U2 = {}
|
|
80
|
+
# U1 = {}
|
|
81
|
+
# QFT = {}
|
|
82
|
+
|
|
83
|
+
# Gates which should be translated to QubitUnitary
|
|
84
|
+
# [operators.gates.matrix]
|
|
85
|
+
|
|
86
|
+
# Observables supported by the device
|
|
87
|
+
[operators.observables]
|
|
88
|
+
|
|
89
|
+
PauliX = {}
|
|
90
|
+
PauliY = {}
|
|
91
|
+
PauliZ = {}
|
|
92
|
+
Identity = {}
|
|
93
|
+
Prod = {}
|
|
94
|
+
# Hadamard = {}
|
|
95
|
+
# Hermitian = {}
|
|
96
|
+
# Projector = {}
|
|
97
|
+
# SparseHamiltonian = {}
|
|
98
|
+
# Hamiltonian = {}
|
|
99
|
+
# Sum = {}
|
|
100
|
+
# SProd = {}
|
|
101
|
+
# Exp = {}
|
|
102
|
+
|
|
103
|
+
[measurement_processes]
|
|
104
|
+
|
|
105
|
+
Expval = { condition = [ "analytic" ] }
|
|
106
|
+
Var = { condition = [ "analytic" ] }
|
|
107
|
+
Probs = { condition = [ "analytic" ] }
|
|
108
|
+
State = { condition = [ "analytic" ] }
|
|
109
|
+
Sample = { condition = [ "finiteshots" ] }
|
|
110
|
+
Counts = { condition = [ "finiteshots" ] }
|
|
111
|
+
|
|
112
|
+
[compilation]
|
|
113
|
+
|
|
114
|
+
# If the device is compatible with qjit
|
|
115
|
+
qjit_compatible = true
|
|
116
|
+
# If the device requires run time generation of the quantum circuit.
|
|
117
|
+
runtime_code_generation = false
|
|
118
|
+
# If the device supports mid circuit measurements natively
|
|
119
|
+
mid_circuit_measurement = true
|
|
120
|
+
# This field is currently unchecked but it is reserved for the purpose of
|
|
121
|
+
# determining if the device supports dynamic qubit allocation/deallocation.
|
|
122
|
+
dynamic_qubit_management = true
|
|
123
|
+
|
|
124
|
+
[options]
|
|
125
|
+
# Options is an optional field.
|
|
126
|
+
# These options represent runtime parameters that can be passed to the device
|
|
127
|
+
# upon the device initialization.
|
|
128
|
+
# The option key will be the key in a dictionary.
|
|
129
|
+
# The string corresponds to a field queried in the `qml.Device` instance.
|
|
130
|
+
|
|
131
|
+
# Use "hybrid" stabilizer optimization? (Default is "true"; non-Clifford circuits will fall back to near-Clifford or universal simulation)
|
|
132
|
+
is_hybrid_stabilizer = "isStabilizerHybrid"
|
|
133
|
+
# Use "tensor network" optimization? (Default is "true"; prevents dynamic qubit de-allocation; might function sub-optimally with "hybrid" stabilizer enabled)
|
|
134
|
+
is_tensor_network = "isTensorNetwork"
|
|
135
|
+
# Use Schmidt decomposition optimizations? (Default is "true")
|
|
136
|
+
is_schmidt_decomposed = "isSchmidtDecompose"
|
|
137
|
+
# Distribute Schmidt-decomposed qubit subsystems to multiple GPUs or accelerators, if available? (Default is "true"; mismatched device capacities might hurt overall performance)
|
|
138
|
+
is_schmidt_decomposition_parallel = "isSchmidtDecomposeMulti"
|
|
139
|
+
# Use "quantum binary decision diagram" ("QBDD") methods? (Default is "false"; note that QBDD is CPU-only)
|
|
140
|
+
is_qbdd = "isBinaryDecisionTree"
|
|
141
|
+
# Use GPU acceleration? (Default is "true")
|
|
142
|
+
is_gpu = "isOpenCL"
|
|
143
|
+
# Allocate GPU buffer from general host heap? (Default is "false"; "true" might improve performance or reliability in certain cases, like if using an Intel HD as accelerator)
|
|
144
|
+
is_host_pointer = "isHostPointer"
|
|
145
|
+
# Noise parameter. (Default is "0"; depolarizing noise intensity can also be controlled by "QRACK_GATE_DEPOLARIZATION" environment variable)
|
|
146
|
+
noise = "noise"
|
|
147
|
+
|
|
148
|
+
# In the above example, a dictionary will be constructed at run time.
|
|
149
|
+
# The dictionary will contain the string key "option_key" and its value
|
|
150
|
+
# will be the value in `qml.Device` `option_field`.
|
|
151
|
+
# The value can be any Python type, but will be converted to a string.
|
|
152
|
+
# During the initialization of your `class QuantumDevice`, the dictionary
|
|
153
|
+
# will be sent to the constructor of your implementation of `class QuantumDevice`.
|
|
154
|
+
# The dictionary will be a JSON string like the following:
|
|
155
|
+
# { 'option_key': option_field }
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
# Copyright 2022 Xanadu Quantum Technologies Inc.
|
|
2
|
+
|
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
4
|
+
# you may not use this file except in compliance with the License.
|
|
5
|
+
# You may obtain a copy of the License at
|
|
6
|
+
|
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
|
8
|
+
|
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
12
|
+
# See the License for the specific language governing permissions and
|
|
13
|
+
# limitations under the License.
|
|
14
|
+
|
|
15
|
+
"""PennyLane-Qrack plugin (no public API)"""
|
|
16
|
+
from ._version import __version__
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# Copyright 2022 Xanadu Quantum Technologies Inc.
|
|
2
|
+
|
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
4
|
+
# you may not use this file except in compliance with the License.
|
|
5
|
+
# You may obtain a copy of the License at
|
|
6
|
+
|
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
|
8
|
+
|
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
12
|
+
# See the License for the specific language governing permissions and
|
|
13
|
+
# limitations under the License.
|
|
14
|
+
|
|
15
|
+
"""Version information.
|
|
16
|
+
Version number (major.minor.patch[-label])
|
|
17
|
+
"""
|
|
18
|
+
|
|
19
|
+
__version__ = "0.10.2"
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
# Install script for directory: /Users/runner/work/pennylane-qrack/pennylane-qrack
|
|
2
|
+
|
|
3
|
+
# Set the install prefix
|
|
4
|
+
if(NOT DEFINED CMAKE_INSTALL_PREFIX)
|
|
5
|
+
set(CMAKE_INSTALL_PREFIX "/usr/local")
|
|
6
|
+
endif()
|
|
7
|
+
string(REGEX REPLACE "/$" "" CMAKE_INSTALL_PREFIX "${CMAKE_INSTALL_PREFIX}")
|
|
8
|
+
|
|
9
|
+
# Set the install configuration name.
|
|
10
|
+
if(NOT DEFINED CMAKE_INSTALL_CONFIG_NAME)
|
|
11
|
+
if(BUILD_TYPE)
|
|
12
|
+
string(REGEX REPLACE "^[^A-Za-z0-9_]+" ""
|
|
13
|
+
CMAKE_INSTALL_CONFIG_NAME "${BUILD_TYPE}")
|
|
14
|
+
else()
|
|
15
|
+
set(CMAKE_INSTALL_CONFIG_NAME "")
|
|
16
|
+
endif()
|
|
17
|
+
message(STATUS "Install configuration: \"${CMAKE_INSTALL_CONFIG_NAME}\"")
|
|
18
|
+
endif()
|
|
19
|
+
|
|
20
|
+
# Set the component getting installed.
|
|
21
|
+
if(NOT CMAKE_INSTALL_COMPONENT)
|
|
22
|
+
if(COMPONENT)
|
|
23
|
+
message(STATUS "Install component: \"${COMPONENT}\"")
|
|
24
|
+
set(CMAKE_INSTALL_COMPONENT "${COMPONENT}")
|
|
25
|
+
else()
|
|
26
|
+
set(CMAKE_INSTALL_COMPONENT)
|
|
27
|
+
endif()
|
|
28
|
+
endif()
|
|
29
|
+
|
|
30
|
+
# Is this installation the result of a crosscompile?
|
|
31
|
+
if(NOT DEFINED CMAKE_CROSSCOMPILING)
|
|
32
|
+
set(CMAKE_CROSSCOMPILING "FALSE")
|
|
33
|
+
endif()
|
|
34
|
+
|
|
35
|
+
# Set path to fallback-tool for dependency-resolution.
|
|
36
|
+
if(NOT DEFINED CMAKE_OBJDUMP)
|
|
37
|
+
set(CMAKE_OBJDUMP "/Applications/Xcode_16.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/objdump")
|
|
38
|
+
endif()
|
|
39
|
+
|
|
40
|
+
if(CMAKE_INSTALL_COMPONENT STREQUAL "Unspecified" OR NOT CMAKE_INSTALL_COMPONENT)
|
|
41
|
+
file(INSTALL DESTINATION "${CMAKE_INSTALL_PREFIX}/pennylane_qrack" TYPE SHARED_LIBRARY FILES "/Users/runner/work/pennylane-qrack/pennylane-qrack/pennylane_qrack/libqrack_device.dylib")
|
|
42
|
+
if(EXISTS "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/pennylane_qrack/libqrack_device.dylib" AND
|
|
43
|
+
NOT IS_SYMLINK "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/pennylane_qrack/libqrack_device.dylib")
|
|
44
|
+
execute_process(COMMAND /usr/bin/install_name_tool
|
|
45
|
+
-delete_rpath "/Users/runner/work/pennylane-qrack/pennylane-qrack/catalyst/runtime/include"
|
|
46
|
+
-delete_rpath "/Users/runner/work/pennylane-qrack/pennylane-qrack/qrack/build"
|
|
47
|
+
"$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/pennylane_qrack/libqrack_device.dylib")
|
|
48
|
+
if(CMAKE_INSTALL_DO_STRIP)
|
|
49
|
+
execute_process(COMMAND "/Applications/Xcode_16.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/strip" -x "$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/pennylane_qrack/libqrack_device.dylib")
|
|
50
|
+
endif()
|
|
51
|
+
endif()
|
|
52
|
+
endif()
|
|
53
|
+
|
|
54
|
+
if(CMAKE_INSTALL_COMPONENT STREQUAL "Unspecified" OR NOT CMAKE_INSTALL_COMPONENT)
|
|
55
|
+
endif()
|
|
56
|
+
|
|
57
|
+
if(CMAKE_INSTALL_COMPONENT)
|
|
58
|
+
if(CMAKE_INSTALL_COMPONENT MATCHES "^[a-zA-Z0-9_.+-]+$")
|
|
59
|
+
set(CMAKE_INSTALL_MANIFEST "install_manifest_${CMAKE_INSTALL_COMPONENT}.txt")
|
|
60
|
+
else()
|
|
61
|
+
string(MD5 CMAKE_INST_COMP_HASH "${CMAKE_INSTALL_COMPONENT}")
|
|
62
|
+
set(CMAKE_INSTALL_MANIFEST "install_manifest_${CMAKE_INST_COMP_HASH}.txt")
|
|
63
|
+
unset(CMAKE_INST_COMP_HASH)
|
|
64
|
+
endif()
|
|
65
|
+
else()
|
|
66
|
+
set(CMAKE_INSTALL_MANIFEST "install_manifest.txt")
|
|
67
|
+
endif()
|
|
68
|
+
|
|
69
|
+
if(NOT CMAKE_INSTALL_LOCAL_ONLY)
|
|
70
|
+
string(REPLACE ";" "\n" CMAKE_INSTALL_MANIFEST_CONTENT
|
|
71
|
+
"${CMAKE_INSTALL_MANIFEST_FILES}")
|
|
72
|
+
file(WRITE "/Users/runner/work/pennylane-qrack/pennylane-qrack/pennylane_qrack/${CMAKE_INSTALL_MANIFEST}"
|
|
73
|
+
"${CMAKE_INSTALL_MANIFEST_CONTENT}")
|
|
74
|
+
endif()
|
|
Binary file
|