added extended google supremacy
This commit is contained in:
parent
c3601399ed
commit
2beb548cbe
22
02_cirq.py
22
02_cirq.py
@ -1,5 +1,6 @@
|
|||||||
import cirq
|
import cirq
|
||||||
|
|
||||||
|
def main():
|
||||||
# Pick a qubit.
|
# Pick a qubit.
|
||||||
qubit = cirq.GridQubit(0, 0)
|
qubit = cirq.GridQubit(0, 0)
|
||||||
|
|
||||||
@ -17,22 +18,5 @@ result = simulator.run(circuit, repetitions=20)
|
|||||||
print("Results:")
|
print("Results:")
|
||||||
print(result)
|
print(result)
|
||||||
|
|
||||||
|
if __name__ == "__main__":
|
||||||
# ----- Tutorial
|
main()
|
||||||
import cirq
|
|
||||||
import numpy as np
|
|
||||||
import matplotlib
|
|
||||||
|
|
||||||
# Print Google's 72-qbit Bristlecone
|
|
||||||
print(cirq.google.Bristlecone)
|
|
||||||
|
|
||||||
# Use named Qubits
|
|
||||||
a = cirq.NamedQubit("a")
|
|
||||||
b = cirq.NamedQubit("b")
|
|
||||||
c = cirq.NamedQubit("c")
|
|
||||||
ops = [cirq.H(a), cirq.H(b), cirq.CNOT(b, c), cirq.H(b)]
|
|
||||||
circuit = cirq.Circuit.from_ops(ops)
|
|
||||||
print(circuit)
|
|
||||||
|
|
||||||
for i, moment in enumerate(circuit):
|
|
||||||
print('Moment {}: {}'.format(i, moment))
|
|
Binary file not shown.
121788
papers/2019_suplementary_google_supremacy_paper.pdf
Normal file
121788
papers/2019_suplementary_google_supremacy_paper.pdf
Normal file
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue
Block a user