pyqrack-cuda 1.52.1__tar.gz → 1.52.3__tar.gz
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.
- {pyqrack_cuda-1.52.1/pyqrack_cuda.egg-info → pyqrack_cuda-1.52.3}/PKG-INFO +1 -1
- {pyqrack_cuda-1.52.1 → pyqrack_cuda-1.52.3}/pyqrack/qrack_ace_backend.py +21 -5
- {pyqrack_cuda-1.52.1 → pyqrack_cuda-1.52.3/pyqrack_cuda.egg-info}/PKG-INFO +1 -1
- {pyqrack_cuda-1.52.1 → pyqrack_cuda-1.52.3}/setup.py +1 -1
- {pyqrack_cuda-1.52.1 → pyqrack_cuda-1.52.3}/LICENSE +0 -0
- {pyqrack_cuda-1.52.1 → pyqrack_cuda-1.52.3}/MANIFEST.in +0 -0
- {pyqrack_cuda-1.52.1 → pyqrack_cuda-1.52.3}/Makefile +0 -0
- {pyqrack_cuda-1.52.1 → pyqrack_cuda-1.52.3}/README.md +0 -0
- {pyqrack_cuda-1.52.1 → pyqrack_cuda-1.52.3}/pyproject.toml +0 -0
- {pyqrack_cuda-1.52.1 → pyqrack_cuda-1.52.3}/pyqrack/__init__.py +0 -0
- {pyqrack_cuda-1.52.1 → pyqrack_cuda-1.52.3}/pyqrack/neuron_activation_fn.py +0 -0
- {pyqrack_cuda-1.52.1 → pyqrack_cuda-1.52.3}/pyqrack/pauli.py +0 -0
- {pyqrack_cuda-1.52.1 → pyqrack_cuda-1.52.3}/pyqrack/qrack_circuit.py +0 -0
- {pyqrack_cuda-1.52.1 → pyqrack_cuda-1.52.3}/pyqrack/qrack_neuron.py +0 -0
- {pyqrack_cuda-1.52.1 → pyqrack_cuda-1.52.3}/pyqrack/qrack_neuron_torch_layer.py +0 -0
- {pyqrack_cuda-1.52.1 → pyqrack_cuda-1.52.3}/pyqrack/qrack_simulator.py +0 -0
- {pyqrack_cuda-1.52.1 → pyqrack_cuda-1.52.3}/pyqrack/qrack_stabilizer.py +0 -0
- {pyqrack_cuda-1.52.1 → pyqrack_cuda-1.52.3}/pyqrack/qrack_system/__init__.py +0 -0
- {pyqrack_cuda-1.52.1 → pyqrack_cuda-1.52.3}/pyqrack/qrack_system/qrack_system.py +0 -0
- {pyqrack_cuda-1.52.1 → pyqrack_cuda-1.52.3}/pyqrack/quimb_circuit_type.py +0 -0
- {pyqrack_cuda-1.52.1 → pyqrack_cuda-1.52.3}/pyqrack/stats/__init__.py +0 -0
- {pyqrack_cuda-1.52.1 → pyqrack_cuda-1.52.3}/pyqrack/stats/load_quantized_data.py +0 -0
- {pyqrack_cuda-1.52.1 → pyqrack_cuda-1.52.3}/pyqrack/stats/quantize_by_range.py +0 -0
- {pyqrack_cuda-1.52.1 → pyqrack_cuda-1.52.3}/pyqrack_cuda.egg-info/SOURCES.txt +0 -0
- {pyqrack_cuda-1.52.1 → pyqrack_cuda-1.52.3}/pyqrack_cuda.egg-info/dependency_links.txt +0 -0
- {pyqrack_cuda-1.52.1 → pyqrack_cuda-1.52.3}/pyqrack_cuda.egg-info/not-zip-safe +0 -0
- {pyqrack_cuda-1.52.1 → pyqrack_cuda-1.52.3}/pyqrack_cuda.egg-info/requires.txt +0 -0
- {pyqrack_cuda-1.52.1 → pyqrack_cuda-1.52.3}/pyqrack_cuda.egg-info/top_level.txt +0 -0
- {pyqrack_cuda-1.52.1 → pyqrack_cuda-1.52.3}/setup.cfg +0 -0
@@ -240,7 +240,7 @@ class QrackAceBackend:
|
|
240
240
|
b2 = hq[2]
|
241
241
|
self.sim[b2[0]].mcx([b2[1]], hq[1][1])
|
242
242
|
|
243
|
-
def _correct(self, lq):
|
243
|
+
def _correct(self, lq, phase=False):
|
244
244
|
if self._is_col_long_range[lq % self.row_length]:
|
245
245
|
return
|
246
246
|
# We can't use true syndrome-based error correction,
|
@@ -251,6 +251,11 @@ class QrackAceBackend:
|
|
251
251
|
single_bit = 0
|
252
252
|
other_bits = []
|
253
253
|
hq = self._unpack(lq)
|
254
|
+
|
255
|
+
if phase:
|
256
|
+
for b in hq:
|
257
|
+
self.sim[b[0]].h(b[1])
|
258
|
+
|
254
259
|
if hq[0][0] == hq[1][0]:
|
255
260
|
single_bit = 2
|
256
261
|
other_bits = [0, 1]
|
@@ -346,6 +351,10 @@ class QrackAceBackend:
|
|
346
351
|
# Force the syndrome non-pathological.
|
347
352
|
self.sim[ancilla_sim].force_m(ancilla, False)
|
348
353
|
|
354
|
+
if phase:
|
355
|
+
for b in hq:
|
356
|
+
self.sim[b[0]].h(b[1])
|
357
|
+
|
349
358
|
def u(self, lq, th, ph, lm):
|
350
359
|
hq = self._unpack(lq)
|
351
360
|
if len(hq) < 2:
|
@@ -574,11 +583,15 @@ class QrackAceBackend:
|
|
574
583
|
self._encode_decode_half(lq1, hq1, False)
|
575
584
|
elif lq1_col == lq2_col:
|
576
585
|
# Both are in the same boundary column.
|
577
|
-
self._encode_decode(lq1, hq1)
|
578
|
-
self._encode_decode(lq2, hq2)
|
579
586
|
b = hq1[0]
|
580
587
|
gate, shadow = self._get_gate(pauli, anti, b[0])
|
581
588
|
gate([b[1]], hq2[0][1])
|
589
|
+
if (lq1_row & 1) == (lq2_row & 1):
|
590
|
+
b = hq1[1]
|
591
|
+
gate, shadow = self._get_gate(pauli, anti, b[0])
|
592
|
+
gate([b[1]], hq2[1][1])
|
593
|
+
else:
|
594
|
+
shadow(hq1[1], hq2[1])
|
582
595
|
b = hq1[2]
|
583
596
|
gate, shadow = self._get_gate(pauli, anti, b[0])
|
584
597
|
gate([b[1]], hq2[2][1])
|
@@ -603,8 +616,11 @@ class QrackAceBackend:
|
|
603
616
|
self._encode_decode(lq2, hq2)
|
604
617
|
self._encode_decode(lq1, hq1)
|
605
618
|
|
606
|
-
self._correct(lq1)
|
607
|
-
|
619
|
+
self._correct(lq1, True)
|
620
|
+
if pauli != Pauli.PauliZ:
|
621
|
+
self._correct(lq2, False)
|
622
|
+
if pauli != Pauli.PauliX:
|
623
|
+
self._correct(lq2, True)
|
608
624
|
|
609
625
|
def cx(self, lq1, lq2):
|
610
626
|
self._cpauli(lq1, lq2, False, Pauli.PauliX)
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|