diff --git a/performance/generate_data_scaling_qbits.py b/performance/generate_data_scaling_qbits.py index db9537d..4e33942 100644 --- a/performance/generate_data_scaling_qbits.py +++ b/performance/generate_data_scaling_qbits.py @@ -2,12 +2,13 @@ from collections import deque import matplotlib.pyplot as plt import numpy as np import json +from random import shuffle from pyqcs import State, H, X, S, CZ, M, list_to_circuit from pyqcs.graph.state import GraphState from pyqcs.util.random_circuits import random_circuit -from measure_circuit import execution_statistics +from measure_circuit import execution_statistics, measure_all def S_with_extra_arg(act, i): return S(act) @@ -18,21 +19,35 @@ def test_scaling_qbits(state_factory , ngates_per_qbit , ncircuits , **kwargs): - results = deque() + trials = deque() - for qbits in range(nstart, nstop): + N = (nstop - nstart) + print() + for n, qbits in enumerate(range(nstart, nstop)): + print(f"generating test data... {int(n/N * 100)} %", end="\r", flush=True) measurement_circuit = list_to_circuit([M(i) for i in range(qbits)]) circuits = [random_circuit(qbits, ngates_per_qbit * qbits, X, H, S_with_extra_arg, CZ) | measurement_circuit for _ in range(ncircuits)] state = state_factory(qbits) + for circuit in circuits: + trials.append((qbits, circuit, state)) + print("generating test data... done ") - print("running test with", qbits, "qbits") - N, avg, std_dev = execution_statistics(circuits, state, scale=qbits, **kwargs) + print("randomizing tests...", end="", flush=True) + shuffle(trials) + print(" done") + + results = measure_all(trials, **kwargs) + N, avg, std_dev = execution_statistics(results, scale={i:i for i in range(nstart, nstop)}, **kwargs) + nqbits = [[i] for i in sorted(results.keys())] + N = [[i] for i in N] + avg = [[i] for i in avg] + std_dev = [[i] for i in std_dev] + + return np.hstack([nqbits, N, avg, std_dev]) - results.append([qbits, N, avg, std_dev]) - return np.array(results, dtype=np.double) if __name__ == "__main__": nstart = 4 diff --git a/performance/measure_circuit.py b/performance/measure_circuit.py index 1c4cf6f..6265c99 100644 --- a/performance/measure_circuit.py +++ b/performance/measure_circuit.py @@ -1,5 +1,5 @@ import timeit -from collections import deque +from collections import deque, defaultdict import numpy as np def measure_execution_time(circuit, state, repeat=100, **kwargs): @@ -14,17 +14,35 @@ def measure_execution_time(circuit, state, repeat=100, **kwargs): results.append(stop - start) return min(results) +def measure_all(input_circuits_and_states, **kwargs): + results = defaultdict(deque) -def execution_statistics(circuits, state, scale=1, **kwargs): - results = deque() + N = len(input_circuits_and_states) + for n, (key, circuit, state) in enumerate(input_circuits_and_states): + print(f"running tests... {int(n/N * 100)} %", end="\r", flush=True) + results[key].append(measure_execution_time(circuit, state, **kwargs)) + print("running tests... done ") + return results - for circuit in circuits: - results.append(measure_execution_time(circuit, state, **kwargs)) - results = np.array(results, dtype=np.double) - results /= scale - N = len(results) - avg = np.average(results) - std_dev = np.std(results) / np.sqrt(N) +def execution_statistics(results, scale=1, **kwargs): + Ns = deque() + avgs = deque() + std_devs = deque() + for k,v in sorted(results.items(), key=lambda x: x[0]): + result = np.array(v, dtype=np.double) + if(scale is not None): + result /= scale[k] + N = len(result) + avg = np.average(result) + std_dev = np.std(result) / np.sqrt(N) - return N, avg, std_dev + Ns.append(N) + avgs.append(avg) + std_devs.append(std_dev) + + Ns = np.array(Ns).astype(np.int64) + avgs = np.array(avgs).astype(np.double) + std_devs = np.array(std_devs).astype(np.double) + + return Ns, avgs, std_devs diff --git a/performance/qbit_scaling_graph.csv b/performance/qbit_scaling_graph.csv index f5f2636..2dcd90c 100644 --- a/performance/qbit_scaling_graph.csv +++ b/performance/qbit_scaling_graph.csv @@ -1,12 +1,12 @@ -4.000000000000000000e+00 5.000000000000000000e+01 3.428762500334414762e-04 1.776446001982484369e-07 -5.000000000000000000e+00 5.000000000000000000e+01 3.473852679890115382e-04 2.598062558925338788e-07 -6.000000000000000000e+00 5.000000000000000000e+01 3.548723967105616448e-04 4.534064590863222934e-07 -7.000000000000000000e+00 5.000000000000000000e+01 3.632114771296203210e-04 4.806098777964577126e-07 -8.000000000000000000e+00 5.000000000000000000e+01 3.750995150130620307e-04 6.476646505816643513e-07 -9.000000000000000000e+00 5.000000000000000000e+01 3.854635600065295441e-04 6.874179522109677230e-07 -1.000000000000000000e+01 5.000000000000000000e+01 4.000266940056462946e-04 9.651952693529160437e-07 -1.100000000000000000e+01 5.000000000000000000e+01 4.172046781803312411e-04 1.025532448628675197e-06 -1.200000000000000000e+01 5.000000000000000000e+01 4.337426433327587916e-04 1.244640351956993768e-06 -1.300000000000000000e+01 5.000000000000000000e+01 4.516327153956248893e-04 1.397547153489921964e-06 -1.400000000000000000e+01 5.000000000000000000e+01 4.746154742731180202e-04 1.438840206418780757e-06 -1.500000000000000000e+01 5.000000000000000000e+01 4.947947773422735644e-04 1.512200942654882813e-06 +4.000000000000000000e+00 5.000000000000000000e+01 3.429655850231938768e-04 3.964784429570424898e-07 +5.000000000000000000e+00 5.000000000000000000e+01 3.475331880617887111e-04 6.532202621031675207e-07 +6.000000000000000000e+00 5.000000000000000000e+01 3.569947167003799425e-04 6.858285888009526683e-07 +7.000000000000000000e+00 5.000000000000000000e+01 3.670373971337019710e-04 8.737464017398305182e-07 +8.000000000000000000e+00 5.000000000000000000e+01 3.798681950138416120e-04 8.880263000414631264e-07 +9.000000000000000000e+00 5.000000000000000000e+01 3.896756644503006329e-04 8.241847954707531607e-07 +1.000000000000000000e+01 5.000000000000000000e+01 4.098476440485683504e-04 1.154128418230815053e-06 +1.100000000000000000e+01 5.000000000000000000e+01 4.220041636488697039e-04 1.070578629651815833e-06 +1.200000000000000000e+01 5.000000000000000000e+01 4.430631950223565502e-04 1.530158225225066135e-06 +1.300000000000000000e+01 5.000000000000000000e+01 4.633520061347204356e-04 1.692271924113339457e-06 +1.400000000000000000e+01 5.000000000000000000e+01 4.852215242759225157e-04 1.838279848627781220e-06 +1.500000000000000000e+01 5.000000000000000000e+01 5.214459826529491832e-04 1.847875920612266566e-06 diff --git a/performance/qbit_scaling_naive.csv b/performance/qbit_scaling_naive.csv index a17a59d..0c78f48 100644 --- a/performance/qbit_scaling_naive.csv +++ b/performance/qbit_scaling_naive.csv @@ -1,12 +1,12 @@ -4.000000000000000000e+00 5.000000000000000000e+01 5.710626750078518074e-04 3.074619893383663595e-07 -5.000000000000000000e+00 5.000000000000000000e+01 5.794033039710484549e-04 3.361507724083728980e-07 -6.000000000000000000e+00 5.000000000000000000e+01 6.018405966581971038e-04 3.954121504518400730e-07 -7.000000000000000000e+00 5.000000000000000000e+01 6.379969228250306334e-04 6.377450051968341937e-07 -8.000000000000000000e+00 5.000000000000000000e+01 6.879805825064977181e-04 6.067862538259454889e-07 -9.000000000000000000e+00 5.000000000000000000e+01 7.696791600271049583e-04 9.098588337766861441e-07 -1.000000000000000000e+01 5.000000000000000000e+01 9.255668519908794934e-04 1.733826880461384478e-06 -1.100000000000000000e+01 5.000000000000000000e+01 1.239132149084153870e-03 2.677563717065448952e-06 -1.200000000000000000e+01 5.000000000000000000e+01 1.878185706658162856e-03 5.029636681267363894e-06 -1.300000000000000000e+01 5.000000000000000000e+01 3.150087018461468664e-03 1.075367375211387397e-05 -1.400000000000000000e+01 5.000000000000000000e+01 5.638398892837618269e-03 2.006797664581050196e-05 -1.500000000000000000e+01 5.000000000000000000e+01 1.048240925067996966e-02 3.469709270629929890e-05 +4.000000000000000000e+00 5.000000000000000000e+01 5.892368650893331028e-04 9.659514404922622761e-07 +5.000000000000000000e+00 5.000000000000000000e+01 6.003430280397878665e-04 1.065010131039797397e-06 +6.000000000000000000e+00 5.000000000000000000e+01 6.182032666644470377e-04 8.375309081009639130e-07 +7.000000000000000000e+00 5.000000000000000000e+01 6.621159000392905052e-04 1.116822172068341379e-06 +8.000000000000000000e+00 5.000000000000000000e+01 7.066036874857672999e-04 1.045121177378059615e-06 +9.000000000000000000e+00 5.000000000000000000e+01 7.926702222660727193e-04 1.521812902193708585e-06 +1.000000000000000000e+01 5.000000000000000000e+01 9.538586060516536600e-04 2.519431877046405846e-06 +1.100000000000000000e+01 5.000000000000000000e+01 1.276251990916948053e-03 3.274849717186824768e-06 +1.200000000000000000e+01 5.000000000000000000e+01 1.937763718330339988e-03 5.380974020943288937e-06 +1.300000000000000000e+01 5.000000000000000000e+01 3.305397004615559520e-03 1.094398743059485016e-05 +1.400000000000000000e+01 5.000000000000000000e+01 5.888714548590152226e-03 1.961078728083609431e-05 +1.500000000000000000e+01 5.000000000000000000e+01 1.090257817468470031e-02 3.954920246897699910e-05 diff --git a/performance/regimes/circuit_scaling_graph0.csv b/performance/regimes/circuit_scaling_graph0.csv index f16feae..e247678 100644 --- a/performance/regimes/circuit_scaling_graph0.csv +++ b/performance/regimes/circuit_scaling_graph0.csv @@ -1,48 +1,48 @@ -4.000000000000000000e+02 1.000000000000000000e+02 1.289155170052254124e-03 7.202131418617368309e-07 -4.500000000000000000e+02 1.000000000000000000e+02 1.474937650382344067e-03 6.507618949202226556e-07 -5.000000000000000000e+02 1.000000000000000000e+02 1.637342369904217681e-03 1.017686405690828357e-06 -5.500000000000000000e+02 1.000000000000000000e+02 1.817014810221735449e-03 1.392357973932926867e-06 -6.000000000000000000e+02 1.000000000000000000e+02 1.975182499954826042e-03 1.547137834315356507e-06 -6.500000000000000000e+02 1.000000000000000000e+02 2.164881780008727323e-03 2.775496195150247345e-06 -7.000000000000000000e+02 1.000000000000000000e+02 2.327898260009533121e-03 4.072387486484014841e-06 -7.500000000000000000e+02 1.000000000000000000e+02 2.512511619897850323e-03 5.706339831416697083e-06 -8.000000000000000000e+02 1.000000000000000000e+02 2.726206230108800619e-03 9.543953937061589143e-06 -8.500000000000000000e+02 1.000000000000000000e+02 2.957790580258006213e-03 1.840289901428224624e-05 -9.000000000000000000e+02 1.000000000000000000e+02 3.175472230032028078e-03 2.102542643895924097e-05 -9.500000000000000000e+02 1.000000000000000000e+02 3.499485609936528029e-03 3.387939745646464381e-05 -1.000000000000000000e+03 1.000000000000000000e+02 3.921820819996355879e-03 5.999657457282288624e-05 -1.050000000000000000e+03 1.000000000000000000e+02 4.411485180025920098e-03 9.100803502894595082e-05 -1.100000000000000000e+03 1.000000000000000000e+02 5.180023460052324974e-03 1.525074107072068729e-04 -1.150000000000000000e+03 1.000000000000000000e+02 5.836314029984350504e-03 1.980946198733034617e-04 -1.200000000000000000e+03 1.000000000000000000e+02 7.114772470049502036e-03 2.756185153672614969e-04 -1.250000000000000000e+03 1.000000000000000000e+02 8.218978049990255039e-03 2.705439779355670407e-04 -1.300000000000000000e+03 1.000000000000000000e+02 1.039048378996085438e-02 4.499383462236771565e-04 -1.350000000000000000e+03 1.000000000000000000e+02 1.374823788995854605e-02 6.836957261699217261e-04 -1.400000000000000000e+03 1.000000000000000000e+02 1.649776842976280120e-02 7.834957772245325011e-04 -1.450000000000000000e+03 1.000000000000000000e+02 1.973831228002382102e-02 9.739570295397147626e-04 -1.500000000000000000e+03 1.000000000000000000e+02 2.254402181992190904e-02 9.994626509483015616e-04 -1.550000000000000000e+03 1.000000000000000000e+02 2.905061726003623293e-02 1.141192389509603248e-03 -1.600000000000000000e+03 1.000000000000000000e+02 3.101395440990017960e-02 1.195408495138927055e-03 -1.650000000000000000e+03 1.000000000000000000e+02 4.304727038019336843e-02 1.704638252906546039e-03 -1.700000000000000000e+03 1.000000000000000000e+02 4.943991763982921728e-02 1.753819244790834949e-03 -1.750000000000000000e+03 1.000000000000000000e+02 5.811022215031698412e-02 2.241762785359560813e-03 -1.800000000000000000e+03 1.000000000000000000e+02 6.494125373999849737e-02 2.161706767725532670e-03 -1.850000000000000000e+03 1.000000000000000000e+02 8.044317284980934124e-02 2.563997167420072748e-03 -1.900000000000000000e+03 1.000000000000000000e+02 8.750321559993608223e-02 2.508198734765620420e-03 -1.950000000000000000e+03 1.000000000000000000e+02 1.049924457396627930e-01 3.034147184227525655e-03 -2.000000000000000000e+03 1.000000000000000000e+02 1.144572633299321684e-01 3.121908377511624453e-03 -2.050000000000000000e+03 1.000000000000000000e+02 1.296125941900027057e-01 4.059118521444473986e-03 -2.100000000000000000e+03 1.000000000000000000e+02 1.476271881001957886e-01 4.304095742736498142e-03 -2.150000000000000000e+03 1.000000000000000000e+02 1.590199630600545866e-01 3.983178368817353807e-03 -2.200000000000000000e+03 1.000000000000000000e+02 1.833297056598166830e-01 4.598387080141362951e-03 -2.250000000000000000e+03 1.000000000000000000e+02 2.006969170501179123e-01 4.587501810029061960e-03 -2.300000000000000000e+03 1.000000000000000000e+02 2.230433375898428494e-01 5.403659038058868450e-03 -2.350000000000000000e+03 1.000000000000000000e+02 2.411579741999230475e-01 4.915125254286232051e-03 -2.400000000000000000e+03 1.000000000000000000e+02 2.637051667999912863e-01 5.022663004515379517e-03 -2.450000000000000000e+03 1.000000000000000000e+02 2.790455744599603105e-01 5.646323379520021279e-03 -2.500000000000000000e+03 1.000000000000000000e+02 3.102046102101667091e-01 5.547092587792283591e-03 -2.550000000000000000e+03 1.000000000000000000e+02 3.244321750599192256e-01 6.308998227478966776e-03 -2.600000000000000000e+03 1.000000000000000000e+02 3.525740050802778636e-01 6.164209930004714219e-03 -2.650000000000000000e+03 1.000000000000000000e+02 3.710189696798261161e-01 5.591592560980950324e-03 -2.700000000000000000e+03 1.000000000000000000e+02 3.997344696499930961e-01 6.195574865025787678e-03 -2.750000000000000000e+03 1.000000000000000000e+02 4.219868193101137810e-01 7.326848772509097010e-03 +4.000000000000000000e+02 1.000000000000000000e+02 1.878297269940958384e-03 1.469699604704835522e-06 +4.500000000000000000e+02 1.000000000000000000e+02 2.055278760053624865e-03 1.715237596259608518e-06 +5.000000000000000000e+02 1.000000000000000000e+02 2.220861629939463629e-03 1.945376780331531752e-06 +5.500000000000000000e+02 1.000000000000000000e+02 2.415533940038585691e-03 3.703603558244418543e-06 +6.000000000000000000e+02 1.000000000000000000e+02 2.588112829980673216e-03 3.987060218289845164e-06 +6.500000000000000000e+02 1.000000000000000000e+02 2.761849560047267057e-03 3.981340552536311654e-06 +7.000000000000000000e+02 1.000000000000000000e+02 2.950303999969037302e-03 5.917667108000479223e-06 +7.500000000000000000e+02 1.000000000000000000e+02 3.159523300018918148e-03 1.023882160212621164e-05 +8.000000000000000000e+02 1.000000000000000000e+02 3.359561679935723234e-03 1.224085947659805602e-05 +8.500000000000000000e+02 1.000000000000000000e+02 3.626898989969049372e-03 2.129400040479119394e-05 +9.000000000000000000e+02 1.000000000000000000e+02 3.841637020050256771e-03 2.434921819346224365e-05 +9.500000000000000000e+02 1.000000000000000000e+02 4.171545780045562458e-03 3.666930452842941443e-05 +1.000000000000000000e+03 1.000000000000000000e+02 4.603988039816613378e-03 6.082264928340738172e-05 +1.050000000000000000e+03 1.000000000000000000e+02 5.112743269783095491e-03 9.611161984726047567e-05 +1.100000000000000000e+03 1.000000000000000000e+02 5.897319330142636144e-03 1.576824434319171338e-04 +1.150000000000000000e+03 1.000000000000000000e+02 6.631839999936346014e-03 2.091483361039986474e-04 +1.200000000000000000e+03 1.000000000000000000e+02 7.897017169780156179e-03 2.801692486183573810e-04 +1.250000000000000000e+03 1.000000000000000000e+02 9.044396739882358191e-03 2.748119728933274457e-04 +1.300000000000000000e+03 1.000000000000000000e+02 1.131971647970203727e-02 4.650817747928799204e-04 +1.350000000000000000e+03 1.000000000000000000e+02 1.478023339011997478e-02 7.016754168579358852e-04 +1.400000000000000000e+03 1.000000000000000000e+02 1.734726401005900684e-02 7.951340541898133021e-04 +1.450000000000000000e+03 1.000000000000000000e+02 2.102190037010586918e-02 1.002624218122781909e-03 +1.500000000000000000e+03 1.000000000000000000e+02 2.402437226992333238e-02 1.037823513475687100e-03 +1.550000000000000000e+03 1.000000000000000000e+02 3.051912467017246083e-02 1.168558928642808798e-03 +1.600000000000000000e+03 1.000000000000000000e+02 3.283033068997610882e-02 1.249844785100136550e-03 +1.650000000000000000e+03 1.000000000000000000e+02 4.531796266983292160e-02 1.759917786033934287e-03 +1.700000000000000000e+03 1.000000000000000000e+02 5.165379479996772688e-02 1.799192348621859701e-03 +1.750000000000000000e+03 1.000000000000000000e+02 6.068050979989493554e-02 2.315898416538343142e-03 +1.800000000000000000e+03 1.000000000000000000e+02 6.786087045005842477e-02 2.260252367511322510e-03 +1.850000000000000000e+03 1.000000000000000000e+02 8.373902886007272839e-02 2.654447861473096301e-03 +1.900000000000000000e+03 1.000000000000000000e+02 9.122002596010134190e-02 2.613980352536835351e-03 +1.950000000000000000e+03 1.000000000000000000e+02 1.087346132399034104e-01 3.130771289811267507e-03 +2.000000000000000000e+03 1.000000000000000000e+02 1.181711647100382873e-01 3.234989605282795420e-03 +2.050000000000000000e+03 1.000000000000000000e+02 1.346470424801373134e-01 4.163674923361087264e-03 +2.100000000000000000e+03 1.000000000000000000e+02 1.546626253095746417e-01 4.494893701434156223e-03 +2.150000000000000000e+03 1.000000000000000000e+02 1.646854265300135012e-01 4.091584128325677014e-03 +2.200000000000000000e+03 1.000000000000000000e+02 1.900906667797608030e-01 4.732069261775800027e-03 +2.250000000000000000e+03 1.000000000000000000e+02 2.079606859297200572e-01 4.779788452055614388e-03 +2.300000000000000000e+03 1.000000000000000000e+02 2.315051704902725827e-01 5.636123702875270834e-03 +2.350000000000000000e+03 1.000000000000000000e+02 2.495618172797549050e-01 5.018548718196205044e-03 +2.400000000000000000e+03 1.000000000000000000e+02 2.720929994599646240e-01 5.121098331551519889e-03 +2.450000000000000000e+03 1.000000000000000000e+02 2.855364293801903597e-01 5.864504716311486239e-03 +2.500000000000000000e+03 1.000000000000000000e+02 3.189779279900540332e-01 5.760209798368623457e-03 +2.550000000000000000e+03 1.000000000000000000e+02 3.334914251402005814e-01 6.504656122683366223e-03 +2.600000000000000000e+03 1.000000000000000000e+02 3.574019711399887278e-01 6.211228761635085791e-03 +2.650000000000000000e+03 1.000000000000000000e+02 3.789796420900893303e-01 5.768871972682301959e-03 +2.700000000000000000e+03 1.000000000000000000e+02 4.099927911701161110e-01 6.379357717969649441e-03 +2.750000000000000000e+03 1.000000000000000000e+02 4.301786762999472713e-01 7.305549794887298935e-03 diff --git a/performance/regimes/circuit_scaling_graph0_measurements.csv b/performance/regimes/circuit_scaling_graph0_measurements.csv index 76b44e5..89077d7 100644 --- a/performance/regimes/circuit_scaling_graph0_measurements.csv +++ b/performance/regimes/circuit_scaling_graph0_measurements.csv @@ -1,48 +1,48 @@ -4.000000000000000000e+02 1.000000000000000000e+02 2.117918260155420094e-03 3.153929725139841468e-06 -4.500000000000000000e+02 1.000000000000000000e+02 2.346024190155730944e-03 3.362990295162646715e-06 -5.000000000000000000e+02 1.000000000000000000e+02 2.554845300001034030e-03 3.581450405402606531e-06 -5.500000000000000000e+02 1.000000000000000000e+02 2.755300190037814935e-03 3.558214256658488625e-06 -6.000000000000000000e+02 1.000000000000000000e+02 2.960934869952325157e-03 3.959981947840157623e-06 -6.500000000000000000e+02 1.000000000000000000e+02 3.157156460074474983e-03 3.956824396002855291e-06 -7.000000000000000000e+02 1.000000000000000000e+02 3.362684480234747701e-03 4.426553673930159151e-06 -7.500000000000000000e+02 1.000000000000000000e+02 3.602162559982389350e-03 6.287618836461985200e-06 -8.000000000000000000e+02 1.000000000000000000e+02 3.816641149933275388e-03 9.646541114940194447e-06 -8.500000000000000000e+02 1.000000000000000000e+02 3.981523249676683675e-03 5.250427200157442401e-06 -9.000000000000000000e+02 1.000000000000000000e+02 4.179903030162677481e-03 5.319321223461990038e-06 -9.500000000000000000e+02 1.000000000000000000e+02 4.356580820021918078e-03 6.284821131859652095e-06 -1.000000000000000000e+03 1.000000000000000000e+02 4.711663189737009573e-03 1.231819345495698570e-05 -1.050000000000000000e+03 1.000000000000000000e+02 4.857799199708096732e-03 8.874848062487446492e-06 -1.100000000000000000e+03 1.000000000000000000e+02 4.974037230131216764e-03 6.366628858558013898e-06 -1.150000000000000000e+03 1.000000000000000000e+02 5.208487169729778335e-03 8.036823052208671699e-06 -1.200000000000000000e+03 1.000000000000000000e+02 5.383094930220977230e-03 7.497184461412523090e-06 -1.250000000000000000e+03 1.000000000000000000e+02 5.652444379811640864e-03 9.274081982277203320e-06 -1.300000000000000000e+03 1.000000000000000000e+02 5.872684239839145483e-03 9.638609582184605492e-06 -1.350000000000000000e+03 1.000000000000000000e+02 6.050893879946670113e-03 9.780414371687124272e-06 -1.400000000000000000e+03 1.000000000000000000e+02 6.247377139879972327e-03 9.724735155208639442e-06 -1.450000000000000000e+03 1.000000000000000000e+02 6.451234790074522434e-03 1.082915990781066553e-05 -1.500000000000000000e+03 1.000000000000000000e+02 6.670109619990398885e-03 9.168574200655848491e-06 -1.550000000000000000e+03 1.000000000000000000e+02 6.873652330141339674e-03 1.079997095775438653e-05 -1.600000000000000000e+03 1.000000000000000000e+02 7.188739420198544776e-03 1.312986107347982468e-05 -1.650000000000000000e+03 1.000000000000000000e+02 7.283002080002915976e-03 1.266031320496887163e-05 -1.700000000000000000e+03 1.000000000000000000e+02 7.541257100165239813e-03 1.159094713342241029e-05 -1.750000000000000000e+03 1.000000000000000000e+02 7.682937919671530697e-03 2.067212238636168003e-05 -1.800000000000000000e+03 1.000000000000000000e+02 7.742412990337470616e-03 5.816864883254473196e-06 -1.850000000000000000e+03 1.000000000000000000e+02 7.963731280251523312e-03 6.003166636211987850e-06 -1.900000000000000000e+03 1.000000000000000000e+02 8.163955960189922881e-03 6.289383647331144092e-06 -1.950000000000000000e+03 1.000000000000000000e+02 8.412310690400772242e-03 8.995413027555754644e-06 -2.000000000000000000e+03 1.000000000000000000e+02 8.601222660072380816e-03 8.186873659617921307e-06 -2.050000000000000000e+03 1.000000000000000000e+02 8.780245329689932363e-03 7.802414228339774120e-06 -2.100000000000000000e+03 1.000000000000000000e+02 8.989237779969698819e-03 7.320316653066754860e-06 -2.150000000000000000e+03 1.000000000000000000e+02 9.208176750325947416e-03 7.550151315447256100e-06 -2.200000000000000000e+03 1.000000000000000000e+02 9.425421779815224346e-03 9.981486676534551917e-06 -2.250000000000000000e+03 1.000000000000000000e+02 9.572394580027321007e-03 7.868029399680496439e-06 -2.300000000000000000e+03 1.000000000000000000e+02 9.757609719817992092e-03 8.125707507819872197e-06 -2.350000000000000000e+03 1.000000000000000000e+02 1.021417905947600950e-02 3.487049650853384140e-05 -2.400000000000000000e+03 1.000000000000000000e+02 1.060097622001194423e-02 1.877532492915650009e-05 -2.450000000000000000e+03 1.000000000000000000e+02 1.079123301045911004e-02 2.014799933723568657e-05 -2.500000000000000000e+03 1.000000000000000000e+02 1.105411120006465422e-02 1.952338021259126874e-05 -2.550000000000000000e+03 1.000000000000000000e+02 1.117226990965718841e-02 3.770167097653058649e-05 -2.600000000000000000e+03 1.000000000000000000e+02 1.104897773024276879e-02 8.462449225289284428e-06 -2.650000000000000000e+03 1.000000000000000000e+02 1.129705063976871315e-02 2.055146171078313860e-05 -2.700000000000000000e+03 1.000000000000000000e+02 1.143899963994044790e-02 9.937337737698893357e-06 -2.750000000000000000e+03 1.000000000000000000e+02 1.167129078996367690e-02 1.026892196615593232e-05 +4.000000000000000000e+02 1.000000000000000000e+02 2.114092410047305713e-03 4.433758417156305577e-06 +4.500000000000000000e+02 1.000000000000000000e+02 2.321048889825760853e-03 5.937571629155414468e-06 +5.000000000000000000e+02 1.000000000000000000e+02 2.511581300313992134e-03 4.447960012009385777e-06 +5.500000000000000000e+02 1.000000000000000000e+02 2.724882900038210279e-03 6.196974287714982763e-06 +6.000000000000000000e+02 1.000000000000000000e+02 2.917018520020064724e-03 5.609842050456831044e-06 +6.500000000000000000e+02 1.000000000000000000e+02 3.135351710152463073e-03 9.856120499095659976e-06 +7.000000000000000000e+02 1.000000000000000000e+02 3.312228960094216763e-03 6.830942010328380095e-06 +7.500000000000000000e+02 1.000000000000000000e+02 3.535587249934906296e-03 9.922670751610315380e-06 +8.000000000000000000e+02 1.000000000000000000e+02 3.725935840120655432e-03 9.939666182181001021e-06 +8.500000000000000000e+02 1.000000000000000000e+02 3.915570470016973420e-03 8.830747316204233313e-06 +9.000000000000000000e+02 1.000000000000000000e+02 4.111115369923936357e-03 9.840090728994847248e-06 +9.500000000000000000e+02 1.000000000000000000e+02 4.313633020028646153e-03 1.174190209479161364e-05 +1.000000000000000000e+03 1.000000000000000000e+02 4.532612949915347002e-03 1.397328601941653513e-05 +1.050000000000000000e+03 1.000000000000000000e+02 4.772288749809377312e-03 1.473147176858344940e-05 +1.100000000000000000e+03 1.000000000000000000e+02 4.950029140018159281e-03 1.740931807395725410e-05 +1.150000000000000000e+03 1.000000000000000000e+02 5.134839440070208989e-03 1.658339546245857026e-05 +1.200000000000000000e+03 1.000000000000000000e+02 5.357455130142625525e-03 2.036837859523746489e-05 +1.250000000000000000e+03 1.000000000000000000e+02 5.557238789951952744e-03 1.999078689673521443e-05 +1.300000000000000000e+03 1.000000000000000000e+02 5.800642800168133960e-03 2.178452322898261873e-05 +1.350000000000000000e+03 1.000000000000000000e+02 5.965943629962566948e-03 2.188401653780024220e-05 +1.400000000000000000e+03 1.000000000000000000e+02 6.180649969865044044e-03 2.263914359763381218e-05 +1.450000000000000000e+03 1.000000000000000000e+02 6.380249199755780656e-03 2.253331492292668753e-05 +1.500000000000000000e+03 1.000000000000000000e+02 6.632488910145184664e-03 2.800651887947579603e-05 +1.550000000000000000e+03 1.000000000000000000e+02 6.819113240053411955e-03 2.773461475396672550e-05 +1.600000000000000000e+03 1.000000000000000000e+02 7.024011089924897533e-03 3.142666284772606199e-05 +1.650000000000000000e+03 1.000000000000000000e+02 7.245542220080097157e-03 3.463820090187460685e-05 +1.700000000000000000e+03 1.000000000000000000e+02 7.467572930072492558e-03 3.534486764359121610e-05 +1.750000000000000000e+03 1.000000000000000000e+02 7.691007259927573961e-03 3.707757820075371219e-05 +1.800000000000000000e+03 1.000000000000000000e+02 7.849026300063996486e-03 3.582263899526258357e-05 +1.850000000000000000e+03 1.000000000000000000e+02 8.080780739910552180e-03 3.797984821604072337e-05 +1.900000000000000000e+03 1.000000000000000000e+02 8.213192739749502341e-03 3.638401541187267455e-05 +1.950000000000000000e+03 1.000000000000000000e+02 8.449280099957831927e-03 3.841893425816953562e-05 +2.000000000000000000e+03 1.000000000000000000e+02 8.746005679786322123e-03 4.666744247983073543e-05 +2.050000000000000000e+03 1.000000000000000000e+02 8.907570820083492505e-03 4.364195941090845030e-05 +2.100000000000000000e+03 1.000000000000000000e+02 9.140049100133183779e-03 4.601074683094616760e-05 +2.150000000000000000e+03 1.000000000000000000e+02 9.259806350055441865e-03 4.263974364299367629e-05 +2.200000000000000000e+03 1.000000000000000000e+02 9.565907919823075575e-03 5.112760725978646252e-05 +2.250000000000000000e+03 1.000000000000000000e+02 9.780952510263887442e-03 4.980828635291945945e-05 +2.300000000000000000e+03 1.000000000000000000e+02 9.989693050119968082e-03 5.130164461741158917e-05 +2.350000000000000000e+03 1.000000000000000000e+02 1.022960261994739981e-02 5.056835530189594460e-05 +2.400000000000000000e+03 1.000000000000000000e+02 1.037718595998740091e-02 5.737783855788618426e-05 +2.450000000000000000e+03 1.000000000000000000e+02 1.062653940985910581e-02 5.516611435060939192e-05 +2.500000000000000000e+03 1.000000000000000000e+02 1.073097524968034087e-02 5.577957680925535715e-05 +2.550000000000000000e+03 1.000000000000000000e+02 1.114612379024038091e-02 5.969627461068192388e-05 +2.600000000000000000e+03 1.000000000000000000e+02 1.117621255994890803e-02 5.962882899535489848e-05 +2.650000000000000000e+03 1.000000000000000000e+02 1.144374358984350665e-02 5.972570355840602118e-05 +2.700000000000000000e+03 1.000000000000000000e+02 1.155998561989690643e-02 5.750955173201592396e-05 +2.750000000000000000e+03 1.000000000000000000e+02 1.188066325026738979e-02 6.706001428035498655e-05 diff --git a/performance/regimes/circuit_scaling_graph1.csv b/performance/regimes/circuit_scaling_graph1.csv index 3368601..075f801 100644 --- a/performance/regimes/circuit_scaling_graph1.csv +++ b/performance/regimes/circuit_scaling_graph1.csv @@ -1,48 +1,48 @@ -4.000000000000000000e+02 1.000000000000000000e+02 1.331747569893195664e-03 4.185028666557203014e-06 -4.500000000000000000e+02 1.000000000000000000e+02 1.545028069958789352e-03 1.189037919847383599e-05 -5.000000000000000000e+02 1.000000000000000000e+02 1.757285709863936002e-03 1.110939895258291230e-05 -5.500000000000000000e+02 1.000000000000000000e+02 2.096770630341780045e-03 2.589822101502824788e-05 -6.000000000000000000e+02 1.000000000000000000e+02 2.472492380220501097e-03 4.946409213805396754e-05 -6.500000000000000000e+02 1.000000000000000000e+02 2.871599199825141096e-03 5.895301883148381311e-05 -7.000000000000000000e+02 1.000000000000000000e+02 3.503966160278650880e-03 8.240138972572720751e-05 -7.500000000000000000e+02 1.000000000000000000e+02 4.568376979950699440e-03 1.495934361899450599e-04 -8.000000000000000000e+02 1.000000000000000000e+02 5.424915529911231854e-03 1.510876198374431437e-04 -8.500000000000000000e+02 1.000000000000000000e+02 6.268708960051299316e-03 1.839870342931388433e-04 -9.000000000000000000e+02 1.000000000000000000e+02 8.070838380081112734e-03 2.212187264708497805e-04 -9.500000000000000000e+02 1.000000000000000000e+02 9.734033729728253093e-03 2.849546543183301725e-04 -1.000000000000000000e+03 1.000000000000000000e+02 1.131779999996069749e-02 2.890997272312513652e-04 -1.050000000000000000e+03 1.000000000000000000e+02 1.309505432996957083e-02 3.225937973623692529e-04 -1.100000000000000000e+03 1.000000000000000000e+02 1.540500528997654391e-02 3.470055346230453805e-04 -1.150000000000000000e+03 1.000000000000000000e+02 1.676282516982609966e-02 4.273260418970669869e-04 -1.200000000000000000e+03 1.000000000000000000e+02 2.059109770019858926e-02 4.276492012703600226e-04 -1.250000000000000000e+03 1.000000000000000000e+02 2.274899540014303084e-02 4.778751810116567281e-04 -1.300000000000000000e+03 1.000000000000000000e+02 2.549480525023682317e-02 5.004283576430242726e-04 -1.350000000000000000e+03 1.000000000000000000e+02 2.861488545990141519e-02 5.772042114557329132e-04 -1.400000000000000000e+03 1.000000000000000000e+02 3.097237314006633796e-02 5.828879243888531467e-04 -1.450000000000000000e+03 1.000000000000000000e+02 3.408838622977782701e-02 6.034821385254118646e-04 -1.500000000000000000e+03 1.000000000000000000e+02 3.851205766022758326e-02 5.363328031794364122e-04 -1.550000000000000000e+03 1.000000000000000000e+02 4.122437128029560194e-02 6.372278620266914320e-04 -1.600000000000000000e+03 1.000000000000000000e+02 4.239497635018778937e-02 6.971184760190998319e-04 -1.650000000000000000e+03 1.000000000000000000e+02 4.668520652023289835e-02 6.516511772964784415e-04 -1.700000000000000000e+03 1.000000000000000000e+02 5.081689551014278300e-02 6.047152460041920873e-04 -1.750000000000000000e+03 1.000000000000000000e+02 5.271924327975284486e-02 8.048032796895918930e-04 -1.800000000000000000e+03 1.000000000000000000e+02 5.684540473008382888e-02 7.072337196381863183e-04 -1.850000000000000000e+03 1.000000000000000000e+02 5.978529672989679744e-02 7.833296551258801203e-04 -1.900000000000000000e+03 1.000000000000000000e+02 6.468316917995252380e-02 7.472594540173414183e-04 -1.950000000000000000e+03 1.000000000000000000e+02 7.021883793007872854e-02 6.818677900509464941e-04 -2.000000000000000000e+03 1.000000000000000000e+02 7.419108358000812975e-02 8.214627456306492544e-04 -2.050000000000000000e+03 1.000000000000000000e+02 7.741255534012453365e-02 8.070719858707328404e-04 -2.100000000000000000e+03 1.000000000000000000e+02 8.086882287996559338e-02 7.866241559073118908e-04 -2.150000000000000000e+03 1.000000000000000000e+02 8.348558423003851758e-02 8.231372280700862982e-04 -2.200000000000000000e+03 1.000000000000000000e+02 8.695838841988007273e-02 7.608563879288241221e-04 -2.250000000000000000e+03 1.000000000000000000e+02 9.287772310006403575e-02 9.267475463012196570e-04 -2.300000000000000000e+03 1.000000000000000000e+02 9.641536674978851140e-02 9.073162453149088199e-04 -2.350000000000000000e+03 1.000000000000000000e+02 1.009883459203047146e-01 9.053025832545474969e-04 -2.400000000000000000e+03 1.000000000000000000e+02 1.035630384599789955e-01 8.605099708966920061e-04 -2.450000000000000000e+03 1.000000000000000000e+02 1.056166958799076433e-01 9.042312036116488322e-04 -2.500000000000000000e+03 1.000000000000000000e+02 1.090246676897732026e-01 8.518223667746407327e-04 -2.550000000000000000e+03 1.000000000000000000e+02 1.125992783100082245e-01 9.260318460859097867e-04 -2.600000000000000000e+03 1.000000000000000000e+02 1.181163900302271974e-01 9.457865410662973440e-04 -2.650000000000000000e+03 1.000000000000000000e+02 1.178048554901397482e-01 9.032353305029247863e-04 -2.700000000000000000e+03 1.000000000000000000e+02 1.193943367699466795e-01 8.656900612182483667e-04 -2.750000000000000000e+03 1.000000000000000000e+02 1.246490166999865284e-01 1.003202861539929805e-03 +4.000000000000000000e+02 1.000000000000000000e+02 1.674102860051789347e-03 6.228299552356924658e-06 +4.500000000000000000e+02 1.000000000000000000e+02 1.903562340048665577e-03 1.316833211606872975e-05 +5.000000000000000000e+02 1.000000000000000000e+02 2.123120620053669041e-03 1.197622936239156575e-05 +5.500000000000000000e+02 1.000000000000000000e+02 2.480724299966823206e-03 2.750882032957220326e-05 +6.000000000000000000e+02 1.000000000000000000e+02 2.895569670145050744e-03 5.288688606734717474e-05 +6.500000000000000000e+02 1.000000000000000000e+02 3.315797200011729937e-03 6.324376155582976829e-05 +7.000000000000000000e+02 1.000000000000000000e+02 3.988737380132079471e-03 8.966749854463253178e-05 +7.500000000000000000e+02 1.000000000000000000e+02 5.103451869799755826e-03 1.584853305380074038e-04 +8.000000000000000000e+02 1.000000000000000000e+02 6.057379170051717387e-03 1.642264403316068798e-04 +8.500000000000000000e+02 1.000000000000000000e+02 6.927488980109046748e-03 1.944677459404338588e-04 +9.000000000000000000e+02 1.000000000000000000e+02 8.814388450155093147e-03 2.330794777089288878e-04 +9.500000000000000000e+02 1.000000000000000000e+02 1.064539701990725035e-02 3.041454790179711994e-04 +1.000000000000000000e+03 1.000000000000000000e+02 1.240550483009428794e-02 3.095759025769566721e-04 +1.050000000000000000e+03 1.000000000000000000e+02 1.434945806995529052e-02 3.462888056603818758e-04 +1.100000000000000000e+03 1.000000000000000000e+02 1.677911746977770249e-02 3.749990243690372164e-04 +1.150000000000000000e+03 1.000000000000000000e+02 1.831551297967962469e-02 4.604813699809882270e-04 +1.200000000000000000e+03 1.000000000000000000e+02 2.237008690015500345e-02 4.574082591796148041e-04 +1.250000000000000000e+03 1.000000000000000000e+02 2.469113503011612781e-02 5.159501949634852890e-04 +1.300000000000000000e+03 1.000000000000000000e+02 2.771557212010520785e-02 5.422901593142985836e-04 +1.350000000000000000e+03 1.000000000000000000e+02 3.089818914999341304e-02 6.274980749590892710e-04 +1.400000000000000000e+03 1.000000000000000000e+02 3.351067304993193829e-02 6.258951037710455863e-04 +1.450000000000000000e+03 1.000000000000000000e+02 3.672902733014780235e-02 6.463995733058402766e-04 +1.500000000000000000e+03 1.000000000000000000e+02 4.152314034017763611e-02 5.716930792484469599e-04 +1.550000000000000000e+03 1.000000000000000000e+02 4.438926930015441030e-02 6.721290882549972113e-04 +1.600000000000000000e+03 1.000000000000000000e+02 4.552266089023760537e-02 7.453956208500090320e-04 +1.650000000000000000e+03 1.000000000000000000e+02 5.021009291991504475e-02 6.862840120510182822e-04 +1.700000000000000000e+03 1.000000000000000000e+02 5.453786087025946222e-02 6.546641481410810049e-04 +1.750000000000000000e+03 1.000000000000000000e+02 5.628588498999306799e-02 8.462562766021738741e-04 +1.800000000000000000e+03 1.000000000000000000e+02 6.095474819019727764e-02 7.517515934752839373e-04 +1.850000000000000000e+03 1.000000000000000000e+02 6.366028950997133784e-02 8.152459203989234496e-04 +1.900000000000000000e+03 1.000000000000000000e+02 6.785009805011213424e-02 7.698881522351951924e-04 +1.950000000000000000e+03 1.000000000000000000e+02 7.188723056995513505e-02 6.833998803979537658e-04 +2.000000000000000000e+03 1.000000000000000000e+02 7.566429144997527390e-02 8.365863514799617290e-04 +2.050000000000000000e+03 1.000000000000000000e+02 7.861056976002146757e-02 8.193592148539533947e-04 +2.100000000000000000e+03 1.000000000000000000e+02 8.247058204007771953e-02 8.197200493282149258e-04 +2.150000000000000000e+03 1.000000000000000000e+02 8.493876021024333867e-02 8.342453122990786934e-04 +2.200000000000000000e+03 1.000000000000000000e+02 8.813758615971892252e-02 7.911501815949151164e-04 +2.250000000000000000e+03 1.000000000000000000e+02 9.468871829980343713e-02 9.350049573202011063e-04 +2.300000000000000000e+03 1.000000000000000000e+02 9.786318559981736775e-02 9.314812240165508146e-04 +2.350000000000000000e+03 1.000000000000000000e+02 1.018545777700273908e-01 9.261618059141366391e-04 +2.400000000000000000e+03 1.000000000000000000e+02 1.051895230298396239e-01 8.616776153947947308e-04 +2.450000000000000000e+03 1.000000000000000000e+02 1.070327199899838849e-01 9.274632293436604977e-04 +2.500000000000000000e+03 1.000000000000000000e+02 1.112921274800100918e-01 8.472622784928632040e-04 +2.550000000000000000e+03 1.000000000000000000e+02 1.145994285400956936e-01 9.315154484987448174e-04 +2.600000000000000000e+03 1.000000000000000000e+02 1.193636358499861605e-01 9.910600547399727421e-04 +2.650000000000000000e+03 1.000000000000000000e+02 1.218935546997090558e-01 8.861179673363818541e-04 +2.700000000000000000e+03 1.000000000000000000e+02 1.261190436399556303e-01 9.270747298007727191e-04 +2.750000000000000000e+03 1.000000000000000000e+02 1.291786062698520310e-01 9.713837766685412545e-04 diff --git a/performance/regimes/circuit_scaling_graph1_measurements.csv b/performance/regimes/circuit_scaling_graph1_measurements.csv index 6d0c71b..9534fff 100644 --- a/performance/regimes/circuit_scaling_graph1_measurements.csv +++ b/performance/regimes/circuit_scaling_graph1_measurements.csv @@ -1,48 +1,48 @@ -4.000000000000000000e+02 1.000000000000000000e+02 1.855520929748308767e-03 1.713134491388978309e-06 -4.500000000000000000e+02 1.000000000000000000e+02 2.054871710352017440e-03 2.190088685886722304e-06 -5.000000000000000000e+02 1.000000000000000000e+02 2.246458490408258495e-03 2.160730405732677556e-06 -5.500000000000000000e+02 1.000000000000000000e+02 2.458994149783393524e-03 2.632555491360094470e-06 -6.000000000000000000e+02 1.000000000000000000e+02 2.651202810593531606e-03 2.129537731470889621e-06 -6.500000000000000000e+02 1.000000000000000000e+02 2.848435070191044239e-03 2.101762964151014804e-06 -7.000000000000000000e+02 1.000000000000000000e+02 3.045234929813886871e-03 2.196795878570572359e-06 -7.500000000000000000e+02 1.000000000000000000e+02 3.264530430024024064e-03 3.813739568843195435e-06 -8.000000000000000000e+02 1.000000000000000000e+02 3.448390289340750106e-03 2.506359178657043656e-06 -8.500000000000000000e+02 1.000000000000000000e+02 3.642879379913211042e-03 2.717216465339945572e-06 -9.000000000000000000e+02 1.000000000000000000e+02 3.840055859691346961e-03 3.372217748148944484e-06 -9.500000000000000000e+02 1.000000000000000000e+02 4.042165709906839384e-03 3.061728505191626180e-06 -1.000000000000000000e+03 1.000000000000000000e+02 4.258553239924367691e-03 3.180552461228480271e-06 -1.050000000000000000e+03 1.000000000000000000e+02 4.435837380369776241e-03 3.141057651670607941e-06 -1.100000000000000000e+03 1.000000000000000000e+02 4.647524749525473037e-03 3.577954400671338468e-06 -1.150000000000000000e+03 1.000000000000000000e+02 4.838921920163556829e-03 3.755994502604949956e-06 -1.200000000000000000e+03 1.000000000000000000e+02 5.015973980407579733e-03 3.416063646669190170e-06 -1.250000000000000000e+03 1.000000000000000000e+02 5.232391719837323728e-03 3.990654739077853341e-06 -1.300000000000000000e+03 1.000000000000000000e+02 5.426057579607004508e-03 3.905549309310580046e-06 -1.350000000000000000e+03 1.000000000000000000e+02 5.629395610012580091e-03 4.224554521711868355e-06 -1.400000000000000000e+03 1.000000000000000000e+02 5.827894089889013897e-03 4.100545851548671890e-06 -1.450000000000000000e+03 1.000000000000000000e+02 6.030842360341921032e-03 4.707298305108542942e-06 -1.500000000000000000e+03 1.000000000000000000e+02 6.213281070158700216e-03 3.889082708959310676e-06 -1.550000000000000000e+03 1.000000000000000000e+02 6.416867010266287530e-03 4.638102688188746169e-06 -1.600000000000000000e+03 1.000000000000000000e+02 6.624721089683589630e-03 4.509133312932078743e-06 -1.650000000000000000e+03 1.000000000000000000e+02 6.814689020393416632e-03 4.793786070736816416e-06 -1.700000000000000000e+03 1.000000000000000000e+02 7.037005909878644473e-03 5.124697637943799726e-06 -1.750000000000000000e+03 1.000000000000000000e+02 7.210767660362762607e-03 4.760780065895519881e-06 -1.800000000000000000e+03 1.000000000000000000e+02 7.432531049926183013e-03 5.234147437018776624e-06 -1.850000000000000000e+03 1.000000000000000000e+02 7.624391329954960383e-03 5.747345457474983097e-06 -1.900000000000000000e+03 1.000000000000000000e+02 7.847124330291990399e-03 6.140559741944434632e-06 -1.950000000000000000e+03 1.000000000000000000e+02 8.027807329854112425e-03 5.872308452137434737e-06 -2.000000000000000000e+03 1.000000000000000000e+02 8.234741139749529940e-03 5.484516606744467484e-06 -2.050000000000000000e+03 1.000000000000000000e+02 8.420041370336549258e-03 6.201006014692581159e-06 -2.100000000000000000e+03 1.000000000000000000e+02 8.642610429960768600e-03 5.556879864096533714e-06 -2.150000000000000000e+03 1.000000000000000000e+02 8.832601509420784022e-03 5.994991064019156469e-06 -2.200000000000000000e+03 1.000000000000000000e+02 9.073848030093359038e-03 7.861155277991771910e-06 -2.250000000000000000e+03 1.000000000000000000e+02 9.231382489961106191e-03 5.648926815135226905e-06 -2.300000000000000000e+03 1.000000000000000000e+02 9.434006350056733589e-03 6.503462248911149879e-06 -2.350000000000000000e+03 1.000000000000000000e+02 9.700876819915721025e-03 1.584549838007378060e-05 -2.400000000000000000e+03 1.000000000000000000e+02 9.922618439886718433e-03 8.657328357419615412e-06 -2.450000000000000000e+03 1.000000000000000000e+02 1.014477934950264171e-02 1.167775864563632931e-05 -2.500000000000000000e+03 1.000000000000000000e+02 1.032955904047412263e-02 9.075708383822331569e-06 -2.550000000000000000e+03 1.000000000000000000e+02 1.053916535020107438e-02 9.864027143291052185e-06 -2.600000000000000000e+03 1.000000000000000000e+02 1.068992346969025592e-02 9.836075290728506446e-06 -2.650000000000000000e+03 1.000000000000000000e+02 1.094912902008218260e-02 9.012869001425469971e-06 -2.700000000000000000e+03 1.000000000000000000e+02 1.112891669981763698e-02 8.170382605883808633e-06 -2.750000000000000000e+03 1.000000000000000000e+02 1.133965294000518001e-02 8.807898200629759062e-06 +4.000000000000000000e+02 1.000000000000000000e+02 1.835213840167853076e-03 1.654947914003680341e-06 +4.500000000000000000e+02 1.000000000000000000e+02 2.028433730010874726e-03 2.073783279640639355e-06 +5.000000000000000000e+02 1.000000000000000000e+02 2.218099229830841276e-03 1.976833413920745400e-06 +5.500000000000000000e+02 1.000000000000000000e+02 2.425619929963431735e-03 1.999231091115152094e-06 +6.000000000000000000e+02 1.000000000000000000e+02 2.619029390261857701e-03 2.123180092364623173e-06 +6.500000000000000000e+02 1.000000000000000000e+02 2.810280509947915561e-03 2.604110830106028074e-06 +7.000000000000000000e+02 1.000000000000000000e+02 3.004202880292723352e-03 2.290159355182151633e-06 +7.500000000000000000e+02 1.000000000000000000e+02 3.204109490288828757e-03 2.401836261014467913e-06 +8.000000000000000000e+02 1.000000000000000000e+02 3.402122789921122482e-03 2.613577702092499025e-06 +8.500000000000000000e+02 1.000000000000000000e+02 3.599267799836525315e-03 2.760873850734378321e-06 +9.000000000000000000e+02 1.000000000000000000e+02 3.792393579897179560e-03 3.552906026928584379e-06 +9.500000000000000000e+02 1.000000000000000000e+02 3.983666429849108855e-03 3.432157696986986298e-06 +1.000000000000000000e+03 1.000000000000000000e+02 4.189837399717361716e-03 3.086862551918502448e-06 +1.050000000000000000e+03 1.000000000000000000e+02 4.370275900182605394e-03 3.099666612100548059e-06 +1.100000000000000000e+03 1.000000000000000000e+02 4.568666459781525226e-03 3.082617759197979633e-06 +1.150000000000000000e+03 1.000000000000000000e+02 4.768872990207455483e-03 2.842545899522316566e-06 +1.200000000000000000e+03 1.000000000000000000e+02 4.967560990044148431e-03 3.357707473554368195e-06 +1.250000000000000000e+03 1.000000000000000000e+02 5.167138569922826753e-03 3.403662596095571541e-06 +1.300000000000000000e+03 1.000000000000000000e+02 5.357951160076482137e-03 3.668284912720865696e-06 +1.350000000000000000e+03 1.000000000000000000e+02 5.556991380035469948e-03 3.333100383138736077e-06 +1.400000000000000000e+03 1.000000000000000000e+02 5.744708620004530635e-03 4.047155267053082305e-06 +1.450000000000000000e+03 1.000000000000000000e+02 5.968025329893862294e-03 4.095125006656815022e-06 +1.500000000000000000e+03 1.000000000000000000e+02 6.151023449783679306e-03 3.407747082563892605e-06 +1.550000000000000000e+03 1.000000000000000000e+02 6.356123279838357329e-03 4.334850576434356020e-06 +1.600000000000000000e+03 1.000000000000000000e+02 6.551939030287030376e-03 7.048852016318317495e-06 +1.650000000000000000e+03 1.000000000000000000e+02 6.731890990122338207e-03 4.100646159561067437e-06 +1.700000000000000000e+03 1.000000000000000000e+02 6.941937389819940671e-03 4.995649399597023781e-06 +1.750000000000000000e+03 1.000000000000000000e+02 7.130723769987526266e-03 4.372119755620564940e-06 +1.800000000000000000e+03 1.000000000000000000e+02 7.331140879796293856e-03 4.733622553888157934e-06 +1.850000000000000000e+03 1.000000000000000000e+02 7.533132550015579632e-03 5.116139233385662931e-06 +1.900000000000000000e+03 1.000000000000000000e+02 7.722383079999417879e-03 5.538888471347748345e-06 +1.950000000000000000e+03 1.000000000000000000e+02 7.929849700158229237e-03 4.972503192539554874e-06 +2.000000000000000000e+03 1.000000000000000000e+02 8.121096709764970278e-03 5.661030371967715493e-06 +2.050000000000000000e+03 1.000000000000000000e+02 8.322382019941869033e-03 5.382250019427536677e-06 +2.100000000000000000e+03 1.000000000000000000e+02 8.517122190096416273e-03 5.625107381070845126e-06 +2.150000000000000000e+03 1.000000000000000000e+02 8.716500719856412616e-03 6.102662149448616443e-06 +2.200000000000000000e+03 1.000000000000000000e+02 8.933952380248228950e-03 6.092750330423816700e-06 +2.250000000000000000e+03 1.000000000000000000e+02 9.122699559629837002e-03 6.809876512233571178e-06 +2.300000000000000000e+03 1.000000000000000000e+02 9.308247290100553351e-03 5.584932520477454584e-06 +2.350000000000000000e+03 1.000000000000000000e+02 9.520456349891901968e-03 5.308699344716883628e-06 +2.400000000000000000e+03 1.000000000000000000e+02 9.719488490081857127e-03 5.651934146065065715e-06 +2.450000000000000000e+03 1.000000000000000000e+02 9.917835799969907870e-03 6.118419019078714142e-06 +2.500000000000000000e+03 1.000000000000000000e+02 1.013053042981482653e-02 9.850550105507370965e-06 +2.550000000000000000e+03 1.000000000000000000e+02 1.031325545991421642e-02 7.359933188585473559e-06 +2.600000000000000000e+03 1.000000000000000000e+02 1.051238634987385068e-02 5.962180914305465779e-06 +2.650000000000000000e+03 1.000000000000000000e+02 1.074106708972976700e-02 7.587020510527051451e-06 +2.700000000000000000e+03 1.000000000000000000e+02 1.094498464983189451e-02 1.086042797471184508e-05 +2.750000000000000000e+03 1.000000000000000000e+02 1.112320873024145833e-02 9.348830436389878298e-06 diff --git a/performance/regimes/generate_data_scaling_circuits.py b/performance/regimes/generate_data_scaling_circuits.py index daf6ff1..e82c392 100644 --- a/performance/regimes/generate_data_scaling_circuits.py +++ b/performance/regimes/generate_data_scaling_circuits.py @@ -2,12 +2,13 @@ from collections import deque import matplotlib.pyplot as plt import numpy as np import json +from random import shuffle from pyqcs import State, H, X, S, CZ, M, list_to_circuit from pyqcs.graph.state import GraphState from pyqcs.util.random_circuits import random_circuit -from measure_circuit import execution_statistics +from measure_circuit import execution_statistics, measure_all def S_with_extra_arg(act, i): return S(act) @@ -19,20 +20,33 @@ def test_scaling_circuits(state_factory , nqbits , ncircuits , **kwargs): - results = deque() + trials = deque() - for ngates in range(nstart, nstop, step): + N = (nstop - nstart) / step + print() + for n, ngates in enumerate(range(nstart, nstop, step)): + print(f"generating test data... {int(n/N * 100)} %", end="\r", flush=True) measurement_circuit = list_to_circuit([M(i) for i in range(nqbits)]) circuits = [random_circuit(nqbits, ngates, X, H, S_with_extra_arg, CZ) + | measurement_circuit for _ in range(ncircuits)] state = state_factory(nqbits) + for circuit in circuits: + trials.append((ngates, circuit, state)) + print("generating test data... done ") - print("running test with", ngates, "gates on", nqbits, "qbits") + print("randomizing tests...", end="", flush=True) + shuffle(trials) + print(" done") - N, avg, std_dev = execution_statistics(circuits, state, scale=1, **kwargs) - results.append([ngates, N, avg, std_dev]) + results = measure_all(trials, **kwargs) + N, avg, std_dev = execution_statistics(results, scale=1, **kwargs) + ngates = [[i] for i in sorted(results.keys())] + N = [[i] for i in N] + avg = [[i] for i in avg] + std_dev = [[i] for i in std_dev] - return np.array(results, dtype=np.double) + return np.hstack([ngates, N, avg, std_dev]) if __name__ == "__main__": diff --git a/performance/regimes/generate_data_scaling_circuits_measurements.py b/performance/regimes/generate_data_scaling_circuits_measurements.py index e011c46..0dafb24 100644 --- a/performance/regimes/generate_data_scaling_circuits_measurements.py +++ b/performance/regimes/generate_data_scaling_circuits_measurements.py @@ -2,12 +2,13 @@ from collections import deque import matplotlib.pyplot as plt import numpy as np import json +from random import shuffle from pyqcs import State, H, X, S, CZ, M, list_to_circuit from pyqcs.graph.state import GraphState from pyqcs.util.random_circuits import random_circuit -from measure_circuit import execution_statistics +from measure_circuit import execution_statistics, measure_all def S_with_extra_arg(act, i): return S(act) @@ -19,21 +20,33 @@ def test_scaling_circuits(state_factory , nqbits , ncircuits , **kwargs): - results = deque() + trials = deque() - for ngates in range(nstart, nstop, step): + N = (nstop - nstart) / step + print() + for n, ngates in enumerate(range(nstart, nstop, step)): + print(f"generating test data... {int(n/N * 100)} %", end="\r", flush=True) measurement_circuit = list_to_circuit([M(i) for i in range(nqbits)]) circuits = [random_circuit(nqbits, ngates, M, H, S_with_extra_arg, CZ) | measurement_circuit for _ in range(ncircuits)] state = state_factory(nqbits) + for circuit in circuits: + trials.append((ngates, circuit, state)) + print("generating test data... done ") - print("running test with", ngates, "gates on", nqbits, "qbits") + print("randomizing tests...", end="", flush=True) + shuffle(trials) + print(" done") - N, avg, std_dev = execution_statistics(circuits, state, scale=1, **kwargs) - results.append([ngates, N, avg, std_dev]) + results = measure_all(trials, **kwargs) + N, avg, std_dev = execution_statistics(results, scale=1, **kwargs) + ngates = [[i] for i in sorted(results.keys())] + N = [[i] for i in N] + avg = [[i] for i in avg] + std_dev = [[i] for i in std_dev] - return np.array(results, dtype=np.double) + return np.hstack([ngates, N, avg, std_dev]) if __name__ == "__main__": diff --git a/performance/regimes/measure_circuit.py b/performance/regimes/measure_circuit.py index 1c4cf6f..dbd9ebd 100644 --- a/performance/regimes/measure_circuit.py +++ b/performance/regimes/measure_circuit.py @@ -1,5 +1,5 @@ import timeit -from collections import deque +from collections import deque, defaultdict import numpy as np def measure_execution_time(circuit, state, repeat=100, **kwargs): @@ -14,17 +14,35 @@ def measure_execution_time(circuit, state, repeat=100, **kwargs): results.append(stop - start) return min(results) +def measure_all(input_circuits_and_states, **kwargs): + results = defaultdict(deque) -def execution_statistics(circuits, state, scale=1, **kwargs): - results = deque() + N = len(input_circuits_and_states) + for n, (key, circuit, state) in enumerate(input_circuits_and_states): + print(f"running tests... {int(n/N * 100)} %", end="\r", flush=True) + results[key].append(measure_execution_time(circuit, state, **kwargs)) + print("running tests... done ") + return results - for circuit in circuits: - results.append(measure_execution_time(circuit, state, **kwargs)) - results = np.array(results, dtype=np.double) - results /= scale - N = len(results) - avg = np.average(results) - std_dev = np.std(results) / np.sqrt(N) +def execution_statistics(results, scale=None, **kwargs): + Ns = deque() + avgs = deque() + std_devs = deque() + for k,v in sorted(results.items(), key=lambda x: x[0]): + result = np.array(v, dtype=np.double) + if(scale is not None): + result /= scale[k] + N = len(result) + avg = np.average(result) + std_dev = np.std(result) / np.sqrt(N) - return N, avg, std_dev + Ns.append(N) + avgs.append(avg) + std_devs.append(std_dev) + + Ns = np.array(Ns).astype(np.int64) + avgs = np.array(avgs).astype(np.double) + std_devs = np.array(std_devs).astype(np.double) + + return Ns, avgs, std_devs diff --git a/performance/regimes/scaling_circuits_50qbit_linear.png b/performance/regimes/scaling_circuits_50qbit_linear.png index cccf06c..c2ac4a1 100644 Binary files a/performance/regimes/scaling_circuits_50qbit_linear.png and b/performance/regimes/scaling_circuits_50qbit_linear.png differ diff --git a/performance/regimes/scaling_circuits_linear.png b/performance/regimes/scaling_circuits_linear.png index b5f0657..0125a48 100644 Binary files a/performance/regimes/scaling_circuits_linear.png and b/performance/regimes/scaling_circuits_linear.png differ diff --git a/performance/regimes/scaling_circuits_measurements_linear.png b/performance/regimes/scaling_circuits_measurements_linear.png index 3eed6f7..9771d15 100644 Binary files a/performance/regimes/scaling_circuits_measurements_linear.png and b/performance/regimes/scaling_circuits_measurements_linear.png differ diff --git a/performance/scaling_qbits_linear.png b/performance/scaling_qbits_linear.png index 13838f9..a617536 100644 Binary files a/performance/scaling_qbits_linear.png and b/performance/scaling_qbits_linear.png differ diff --git a/performance/scaling_qbits_log.png b/performance/scaling_qbits_log.png index 98be6ae..4ed9092 100644 Binary files a/performance/scaling_qbits_log.png and b/performance/scaling_qbits_log.png differ