cirq-core 1.6.0.dev20250417204649__py3-none-any.whl → 1.6.0.dev20250423233500__py3-none-any.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 cirq-core might be problematic. Click here for more details.
- cirq/_version.py +1 -1
- cirq/_version_test.py +1 -1
- cirq/ops/matrix_gates.py +3 -0
- cirq/protocols/circuit_diagram_info_protocol_test.py +7 -0
- {cirq_core-1.6.0.dev20250417204649.dist-info → cirq_core-1.6.0.dev20250423233500.dist-info}/METADATA +1 -1
- {cirq_core-1.6.0.dev20250417204649.dist-info → cirq_core-1.6.0.dev20250423233500.dist-info}/RECORD +9 -9
- {cirq_core-1.6.0.dev20250417204649.dist-info → cirq_core-1.6.0.dev20250423233500.dist-info}/WHEEL +1 -1
- {cirq_core-1.6.0.dev20250417204649.dist-info → cirq_core-1.6.0.dev20250423233500.dist-info}/licenses/LICENSE +0 -0
- {cirq_core-1.6.0.dev20250417204649.dist-info → cirq_core-1.6.0.dev20250423233500.dist-info}/top_level.txt +0 -0
cirq/_version.py
CHANGED
cirq/_version_test.py
CHANGED
cirq/ops/matrix_gates.py
CHANGED
|
@@ -187,6 +187,9 @@ class MatrixGate(raw_types.Gate):
|
|
|
187
187
|
self, args: 'cirq.CircuitDiagramInfoArgs'
|
|
188
188
|
) -> 'cirq.CircuitDiagramInfo':
|
|
189
189
|
n_qubits = len(self._qid_shape)
|
|
190
|
+
# No diagram for zero-qubit gates; let fallback handle it
|
|
191
|
+
if n_qubits == 0:
|
|
192
|
+
return NotImplemented
|
|
190
193
|
if self._name is not None:
|
|
191
194
|
symbols = (
|
|
192
195
|
[self._name] if n_qubits == 1 else [f'{self._name}[{i+1}]' for i in range(n_qubits)]
|
|
@@ -115,6 +115,13 @@ def test_circuit_diagram_info_pass_fail():
|
|
|
115
115
|
assert cirq.circuit_diagram_info(E()) == cirq.CircuitDiagramInfo(('X',))
|
|
116
116
|
|
|
117
117
|
|
|
118
|
+
def test_controlled_1x1_matrixgate_diagram_error():
|
|
119
|
+
q = cirq.LineQubit(0)
|
|
120
|
+
g = cirq.MatrixGate(np.array([[1j]])).controlled()
|
|
121
|
+
c = cirq.Circuit(g(q))
|
|
122
|
+
assert str(c) == "0: ───C[[0.+1.j]]───"
|
|
123
|
+
|
|
124
|
+
|
|
118
125
|
def test_circuit_diagram_info_args_eq():
|
|
119
126
|
eq = cirq.testing.EqualsTester()
|
|
120
127
|
eq.add_equality_group(cirq.CircuitDiagramInfoArgs.UNINFORMED_DEFAULT)
|
{cirq_core-1.6.0.dev20250417204649.dist-info → cirq_core-1.6.0.dev20250423233500.dist-info}/METADATA
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: cirq-core
|
|
3
|
-
Version: 1.6.0.
|
|
3
|
+
Version: 1.6.0.dev20250423233500
|
|
4
4
|
Summary: A framework for creating, editing, and invoking Noisy Intermediate Scale Quantum (NISQ) circuits.
|
|
5
5
|
Home-page: http://github.com/quantumlib/cirq
|
|
6
6
|
Author: The Cirq Developers
|
{cirq_core-1.6.0.dev20250417204649.dist-info → cirq_core-1.6.0.dev20250423233500.dist-info}/RECORD
RENAMED
|
@@ -4,8 +4,8 @@ cirq/_compat_test.py,sha256=0m3sYIyxRNv9jvAo6rzJ-cnbpny3KGnAByrbU7bApgQ,34720
|
|
|
4
4
|
cirq/_doc.py,sha256=yDyWUD_2JDS0gShfGRb-rdqRt9-WeL7DhkqX7np0Nko,2879
|
|
5
5
|
cirq/_import.py,sha256=cfocxtT1BJ4HkfZ-VO8YyIhPP-xfqHDkLrzz6eeO5U0,8421
|
|
6
6
|
cirq/_import_test.py,sha256=6K_v0riZJXOXUphHNkGA8MY-JcmGlezFaGmvrNhm3OQ,1015
|
|
7
|
-
cirq/_version.py,sha256=
|
|
8
|
-
cirq/_version_test.py,sha256=
|
|
7
|
+
cirq/_version.py,sha256=zTDhJcrU7VxbbMpoej2ZPpYN8Z5hGHW8WGiVjpcN4hU,1206
|
|
8
|
+
cirq/_version_test.py,sha256=6aahIvsCawS-lbYQpB5PvDe58BVBx2c6vj0MwIWhpTU,147
|
|
9
9
|
cirq/conftest.py,sha256=X7yLFL8GLhg2CjPw0hp5e_dGASfvHx1-QT03aUbhKJw,1168
|
|
10
10
|
cirq/json_resolver_cache.py,sha256=-4KqEEYb6aps-seafnFTHTp3SZc0D8mr4O-pCKIajn8,13653
|
|
11
11
|
cirq/py.typed,sha256=VFSlmh_lNwnaXzwY-ZuW-C2Ws5PkuDoVgBdNCs0jXJE,63
|
|
@@ -314,7 +314,7 @@ cirq/ops/kraus_channel.py,sha256=qX828mvPSFgEaG0I3Jhj04y5rD7dUjeEl2HYDn7_7j4,508
|
|
|
314
314
|
cirq/ops/kraus_channel_test.py,sha256=-E6ExIO3P0y2T74Gx-RMu0kLpy1RWP9wH6UGDI21oFU,4820
|
|
315
315
|
cirq/ops/linear_combinations.py,sha256=PE1o_mvpdnlg3o95iSn5ID18kuxwS2q3DGDuFnlNC90,39916
|
|
316
316
|
cirq/ops/linear_combinations_test.py,sha256=ip-wN8T8nUQviD3ql42eet7k_MQ6DVUfIK8aX-_ygOs,67217
|
|
317
|
-
cirq/ops/matrix_gates.py,sha256=
|
|
317
|
+
cirq/ops/matrix_gates.py,sha256=KbAo1jadyoNHuHCIOCswjB5J82x7nR_mZW0loT-JFmE,10347
|
|
318
318
|
cirq/ops/matrix_gates_test.py,sha256=m5rMwq_sqVvsmkc5opVr3Ikd1ERuULmSRNAvGZUg7ds,14224
|
|
319
319
|
cirq/ops/measure_util.py,sha256=ZaH1Lze4Yk3nYrojn7SILUeIN96p_khIoa25ixXLu6A,7390
|
|
320
320
|
cirq/ops/measure_util_test.py,sha256=Yzlced4nb4DHO-0cM_a-QZGO_3R8oqExkpIALN_pG4A,5307
|
|
@@ -391,7 +391,7 @@ cirq/protocols/apply_unitary_protocol_test.py,sha256=ajjHvcBBv5n8Qh_hMPZkdsOvy1x
|
|
|
391
391
|
cirq/protocols/approximate_equality_protocol.py,sha256=ZqnkoltD8vS1eQjV7Lw3RS49cdjZjGTF0LbdRUlBOCw,6257
|
|
392
392
|
cirq/protocols/approximate_equality_protocol_test.py,sha256=HRjM3PVRGgJNM1cqq7NQ3cMlsiYwL6zEm-MN4y7t1_M,9176
|
|
393
393
|
cirq/protocols/circuit_diagram_info_protocol.py,sha256=msCejCJx5QtvJHM-yro5gbyUfave7FNhqjr8bUw9BIg,16011
|
|
394
|
-
cirq/protocols/circuit_diagram_info_protocol_test.py,sha256=
|
|
394
|
+
cirq/protocols/circuit_diagram_info_protocol_test.py,sha256=2RGVwyseCcOZ3lNMjEavQcAIb_0JEt_KCsUpQRI5j5A,10633
|
|
395
395
|
cirq/protocols/commutes_protocol.py,sha256=n7EQYs2giG3_Kh0bVhOXYQD7we7vTwj8IklBqQdolgM,7394
|
|
396
396
|
cirq/protocols/commutes_protocol_test.py,sha256=h0Lky4jrs7Hxrh4MeHxmxNciuofKGGZ2eC-ceWP8wKU,5849
|
|
397
397
|
cirq/protocols/control_key_protocol.py,sha256=sq4CswLr5TDHPmviNMF1shlL14D6XXlPxt3P985Esy0,2614
|
|
@@ -1209,8 +1209,8 @@ cirq/work/sampler.py,sha256=sW0RhIelGABAKbqTM58shwyyCPgf86JIv9IGdJe__js,19186
|
|
|
1209
1209
|
cirq/work/sampler_test.py,sha256=mdk1J-WrvbPUYhY41VhWf9_te4DnXr_XMPcugWwc4-I,13281
|
|
1210
1210
|
cirq/work/zeros_sampler.py,sha256=8_Ne6dBkDANtTZuql7Eb0Qg_E_P3-_gu-ybFzxTbKAQ,2356
|
|
1211
1211
|
cirq/work/zeros_sampler_test.py,sha256=JIkpBBFPJe5Ba4142vzogyWyboG1Q1ZAm0UVGgOoZn8,3279
|
|
1212
|
-
cirq_core-1.6.0.
|
|
1213
|
-
cirq_core-1.6.0.
|
|
1214
|
-
cirq_core-1.6.0.
|
|
1215
|
-
cirq_core-1.6.0.
|
|
1216
|
-
cirq_core-1.6.0.
|
|
1212
|
+
cirq_core-1.6.0.dev20250423233500.dist-info/licenses/LICENSE,sha256=tAkwu8-AdEyGxGoSvJ2gVmQdcicWw3j1ZZueVV74M-E,11357
|
|
1213
|
+
cirq_core-1.6.0.dev20250423233500.dist-info/METADATA,sha256=6vEgQxrsn9FQGRkxNMkFuKngjTjns6R7ijv3274109U,4908
|
|
1214
|
+
cirq_core-1.6.0.dev20250423233500.dist-info/WHEEL,sha256=SmOxYU7pzNKBqASvQJ7DjX3XGUF92lrGhMb3R6_iiqI,91
|
|
1215
|
+
cirq_core-1.6.0.dev20250423233500.dist-info/top_level.txt,sha256=Sz9iOxHU0IEMLSFGwiwOCaN2e9K-jFbBbtpPN1hB73g,5
|
|
1216
|
+
cirq_core-1.6.0.dev20250423233500.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|