Skip to content

Commit 454e0d2

Browse files
support all modules up-to-date
1 parent 0d46889 commit 454e0d2

File tree

5 files changed

+241
-10
lines changed

5 files changed

+241
-10
lines changed

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,12 @@
22

33
## Unreleased
44

5+
### Fixed
6+
7+
- Fix support for qiskit>1
8+
9+
- tf>=2.16.2 fix the complex input issue for keras
10+
511
## 1.0.0
612

713
### Added

requirements/requirements-2411.txt

Lines changed: 225 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,225 @@
1+
absl-py==2.1.0
2+
alabaster==1.0.0
3+
annotated-types==0.7.0
4+
anyio==4.6.2.post1
5+
astroid==3.3.5
6+
asttokens==3.0.0
7+
astunparse==1.6.3
8+
attrs==24.2.0
9+
babel==2.16.0
10+
beautifulsoup4==4.12.3
11+
black==24.10.0
12+
bleach==6.2.0
13+
cachetools==5.5.0
14+
certifi==2024.8.30
15+
cffi==1.17.1
16+
charset-normalizer==3.4.0
17+
chex==0.1.87
18+
cirq==1.4.1
19+
cirq-aqt==1.4.1
20+
cirq-core==1.4.1
21+
cirq-google==1.4.1
22+
cirq-ionq==1.4.1
23+
cirq-pasqal==1.4.1
24+
cirq-rigetti==1.4.1
25+
cirq-web==1.4.1
26+
click==8.1.7
27+
contourpy==1.3.1
28+
coverage==7.6.8
29+
cryptography==44.0.0
30+
cycler==0.12.1
31+
Cython==3.0.11
32+
decorator==5.1.1
33+
defusedxml==0.7.1
34+
Deprecated==1.2.15
35+
deprecation==2.1.0
36+
dill==0.3.9
37+
docutils==0.21.2
38+
duet==0.2.9
39+
etils==1.11.0
40+
exceptiongroup==1.2.2
41+
execnet==2.1.1
42+
executing==2.1.0
43+
fastjsonschema==2.21.0
44+
filelock==3.16.1
45+
flatbuffers==24.3.25
46+
fonttools==4.55.0
47+
fsspec==2024.10.0
48+
furo==2024.8.6
49+
gast==0.6.0
50+
google-api-core==2.23.0
51+
google-auth==2.36.0
52+
google-pasta==0.2.0
53+
googleapis-common-protos==1.66.0
54+
graphviz==0.20.3
55+
grpc-interceptor==0.15.4
56+
grpcio==1.68.0
57+
grpcio-status==1.62.3
58+
h11==0.14.0
59+
h5py==3.12.1
60+
httpcore==1.0.7
61+
httpx==0.28.0
62+
ibm-cloud-sdk-core==3.22.0
63+
ibm-platform-services==0.59.0
64+
idna==3.10
65+
imagesize==1.4.1
66+
iniconfig==2.0.0
67+
ipython==8.30.0
68+
isort==5.13.2
69+
jax==0.4.35
70+
jaxlib==0.4.35
71+
jedi==0.19.2
72+
Jinja2==3.1.4
73+
jsonschema==4.23.0
74+
jsonschema-specifications==2024.10.1
75+
jupyter_client==8.6.3
76+
jupyter_core==5.7.2
77+
jupyterlab_pygments==0.3.0
78+
keras==3.7.0
79+
kiwisolver==1.4.7
80+
libclang==18.1.1
81+
Markdown==3.7
82+
markdown-it-py==3.0.0
83+
MarkupSafe==3.0.2
84+
matplotlib==3.9.2
85+
matplotlib-inline==0.1.7
86+
mccabe==0.7.0
87+
mdit-py-plugins==0.4.2
88+
mdurl==0.1.2
89+
mistune==3.0.2
90+
mitiq==0.41.0
91+
ml-dtypes==0.4.1
92+
mpmath==1.3.0
93+
msgpack==1.1.0
94+
mthree==2.7.0
95+
# 2.8 gives buffer unmatch float vs double
96+
mypy==1.13.0
97+
mypy-extensions==1.0.0
98+
myst-parser==4.0.0
99+
namex==0.0.8
100+
nbclient==0.10.1
101+
nbconvert==7.16.4
102+
nbformat==5.10.4
103+
nbsphinx==0.9.5
104+
networkx==3.4.2
105+
numpy==1.26.4
106+
openfermion==1.6.1
107+
opt_einsum==3.4.0
108+
optax==0.2.4
109+
optree==0.13.1
110+
orjson==3.10.12
111+
packaging==23.2
112+
pandas==2.2.3
113+
pandocfilters==1.5.1
114+
parso==0.8.4
115+
pathspec==0.12.1
116+
pbr==6.1.0
117+
pexpect==4.9.0
118+
pillow==11.0.0
119+
platformdirs==4.3.6
120+
pluggy==1.5.0
121+
ply==3.11
122+
prompt_toolkit==3.0.48
123+
proto-plus==1.25.0
124+
protobuf==4.25.5
125+
psutil==6.1.0
126+
ptyprocess==0.7.0
127+
PubChemPy==1.0.4
128+
pure_eval==0.2.3
129+
py-cpuinfo==9.0.0
130+
pyasn1==0.6.1
131+
pyasn1_modules==0.4.1
132+
pycparser==2.22
133+
pydantic==2.10.2
134+
pydantic_core==2.27.1
135+
Pygments==2.18.0
136+
PyJWT==2.10.1
137+
pylatexenc==2.10
138+
pylint==3.3.1
139+
pyparsing==3.2.0
140+
pyquil==4.14.3
141+
pyspnego==0.11.2
142+
pytest==7.4.4
143+
# < 8.0 due to lazy-fixture
144+
# https://github.com/dev-petrov/pytest-lazy-fixtures for the future
145+
pytest-benchmark==5.0.1
146+
pytest-cov==6.0.0
147+
pytest-lazy-fixture==0.6.3
148+
pytest-xdist==3.6.1
149+
python-dateutil==2.9.0.post0
150+
python-rapidjson==1.20
151+
pytz==2024.2
152+
PyYAML==6.0.2
153+
pyzmq==26.2.0
154+
qcs-api-client-common==0.10.0
155+
qcs-sdk-python==0.21.4
156+
qiskit==1.2.4
157+
# qiskit 1.3 global_phase in DAG attribute error
158+
qiskit-aer==0.15.1
159+
qiskit-algorithms==0.3.1
160+
qiskit-ibm-runtime==0.33.2
161+
qiskit-nature==0.7.2
162+
quil==0.13.2
163+
referencing==0.35.1
164+
requests==2.32.3
165+
requests_ntlm==1.3.0
166+
rich==13.9.4
167+
rpcq==3.11.0
168+
rpds-py==0.21.0
169+
rsa==4.9
170+
ruamel.yaml==0.18.6
171+
ruamel.yaml.clib==0.2.12
172+
rustworkx==0.15.1
173+
scipy==1.14.1
174+
six==1.16.0
175+
sniffio==1.3.1
176+
snowballstemmer==2.2.0
177+
sortedcontainers==2.4.0
178+
soupsieve==2.6
179+
Sphinx==8.1.3
180+
sphinx-basic-ng==1.0.0b2
181+
sphinx-copybutton==0.5.2
182+
sphinx_design==0.6.1
183+
sphinxcontrib-applehelp==2.0.0
184+
sphinxcontrib-devhelp==2.0.0
185+
sphinxcontrib-htmlhelp==2.1.0
186+
sphinxcontrib-jsmath==1.0.1
187+
sphinxcontrib-qthelp==2.0.0
188+
sphinxcontrib-serializinghtml==2.0.0
189+
stack-data==0.6.3
190+
stevedore==5.4.0
191+
symengine==0.13.0
192+
sympy==1.13.1
193+
tabulate==0.9.0
194+
tensorboard==2.18.0
195+
tensorboard-data-server==0.7.2
196+
tensorflow==2.18.0
197+
tensorflow-io-gcs-filesystem==0.37.1
198+
tensornetwork-ng==0.5.0
199+
termcolor==2.5.0
200+
tinycss2==1.4.0
201+
tokenize_rt==6.1.0
202+
tomli==2.2.1
203+
tomlkit==0.13.2
204+
toolz==1.0.0
205+
torch==2.5.1
206+
tornado==6.4.2
207+
tqdm==4.67.1
208+
traitlets==5.14.3
209+
types-Deprecated==1.2.15.20241117
210+
types-docutils==0.21.0.20241128
211+
types-protobuf==5.28.3.20241030
212+
types-pytz==2024.2.0.20241003
213+
types-requests==2.32.0.20241016
214+
types-setuptools==75.6.0.20241126
215+
types-toml==0.10.8.20240310
216+
types-typed-ast==1.5.8.7
217+
types-urllib3==1.26.25.14
218+
typing_extensions==4.12.2
219+
tzdata==2024.2
220+
urllib3==2.2.3
221+
wcwidth==0.2.13
222+
webencodings==0.5.1
223+
websocket-client==1.8.0
224+
Werkzeug==3.1.3
225+
wrapt==1.17.0

setup.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,11 @@
1919
include_package_data=True,
2020
install_requires=["numpy", "scipy", "tensornetwork-ng", "networkx"],
2121
extras_require={
22-
"tensorflow": ["tensorflow<2.16"],
22+
"tensorflow": ["tensorflow"],
2323
"jax": ["jax", "jaxlib"],
2424
"torch": ["torch"],
25-
"qiskit": ["qiskit<1.0"],
26-
"cloud": ["qiskit<1.0", "mthree"],
25+
"qiskit": ["qiskit"],
26+
"cloud": ["qiskit", "mthree<2.8"],
2727
},
2828
classifiers=[
2929
"Programming Language :: Python :: 3",

tensorcircuit/applications/van.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -250,19 +250,19 @@ def build(self, input_shape: Union[List[tf.TensorShape], tf.TensorShape]) -> Non
250250
# Build the conv2d layer to initialize kernel variables
251251
self.conv.build(input_shape)
252252
# Use the initialized kernel to create the mask
253-
kernel_shape = self.conv.kernel.get_shape()
254-
self.kernel = self.add_weight("kernel", self.conv.kernel.shape)
255-
self.bias = self.add_weight("bias", self.conv.bias.shape)
256-
253+
kernel_shape = self.conv.kernel.shape
254+
self.kernel = self.add_weight(shape=self.conv.kernel.shape)
255+
self.bias = self.add_weight(shape=self.conv.bias.shape)
257256
self.mask = np.zeros(shape=kernel_shape)
258257
self.mask[: kernel_shape[0] // 2, ...] = 1.0
259258
self.mask[kernel_shape[0] // 2, : kernel_shape[1] // 2, ...] = 1.0
260259
if self.mask_type == "B":
261260
self.mask[kernel_shape[0] // 2, kernel_shape[1] // 2, ...] = 1.0
262261

263262
def call(self, inputs: tf.Tensor) -> tf.Tensor:
264-
self.conv.kernel = self.kernel * self.mask
265-
self.conv.bias = self.bias
263+
# self.conv.kernel = self.kernel * self.mask
264+
# self.conv.bias = self.bias
265+
self.conv.set_weights([self.kernel * self.mask, self.bias])
266266
return self.conv(inputs)
267267

268268

tensorcircuit/translation.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@
4747
def get_qiskit_qasm(qc: Any) -> str:
4848

4949
try:
50-
qasm_str = qc.qasm(**kws) # type: ignore
50+
qasm_str = qc.qasm() # type: ignore
5151
except AttributeError: # qiskit 1.0
5252
from qiskit.qasm2 import dumps
5353

0 commit comments

Comments
 (0)