@@ -54,15 +54,6 @@ pz = by_name["pz"] | |||||
msqx_h = by_name["msqx_h"] | msqx_h = by_name["msqx_h"] | ||||
sqz_h = by_name["sqz_h"] | sqz_h = by_name["sqz_h"] | ||||
class Thing(object): | |||||
def __init__(self): | |||||
""" Constructor """ | |||||
return None | |||||
def hunt(self): | |||||
""" Pete is cool """ | |||||
pass | |||||
def conjugate(operator, unitary): | def conjugate(operator, unitary): | ||||
""" Returns transform * vop * transform^dagger and a phase in {+1, -1} """ | """ Returns transform * vop * transform^dagger and a phase in {+1, -1} """ | ||||
return measurement_table[operator, unitary] | return measurement_table[operator, unitary] | ||||
@@ -65,10 +65,10 @@ def test_stress(n=int(1e5)): | |||||
""" Testing that making a graph of ten thousand qubits takes less than half a second""" | """ Testing that making a graph of ten thousand qubits takes less than half a second""" | ||||
import time | import time | ||||
g = GraphState(list(range(n + 1)), vop="hadamard") | g = GraphState(list(range(n + 1)), vop="hadamard") | ||||
t = time.clock() | |||||
t = time.time() | |||||
for i in range(n): | for i in range(n): | ||||
g._add_edge(i, i + 1) | g._add_edge(i, i + 1) | ||||
assert time.clock() - t < .5 | |||||
assert time.time() - t < .5 | |||||
def test_cz(): | def test_cz(): | ||||