MCPcopy Create free account
hub / github.com/WizardOfMenlo/stir / plot_table_values

Function plot_table_values

scripts/main.py:6–31  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

4from aurora import run_aurora_FRI, run_aurora_STIR
5
6def plot_table_values():
7 secparam = 128
8 hashsize = 256
9 pow = 22
10 log_degrees = [18, 20, 22, 24, 26, 28, 30]
11 fieldsizebits = 192
12 stopping_condition = 2**6
13 conj = 1
14 rate_bits = [1, 2, 3, 4]
15
16 result = []
17 for r_bits in rate_bits:
18 new_row = []
19 for log_degree in log_degrees:
20 ldt_params = LDTParameters(secparam=secparam, hashsize=hashsize, pow=pow, log_degree=log_degree, field_size_bits=fieldsizebits, rho_bits = r_bits, conj=conj)
21 sum_fri = run_aurora_FRI(ldt_params, fold=[2,8], stopping_condition=stopping_condition)
22 #fri.print()
23 sum_fri_size = round(sum_fri.argument_size() / 8192)
24 sum_stir = run_aurora_STIR(ldt_params, fold=[2,16], max_len_ratio=[2], stopping_condition=stopping_condition)
25 #sum_stir.print()
26 sum_stir_size = round(sum_stir.argument_size() / 8192)
27 ratio = round(sum_fri_size/sum_stir_size, 2)
28 new_row.append('$\\frac{{ {} }}{{ {} }} \\approx {} \\times $'.format(sum_fri_size, sum_stir_size, ratio))
29 result.append(new_row)
30
31 return '\\\\\n'.join([' & '.join(["$\\sfrac{{1}}{{{}}}$".format(2**rate)] + row) for rate,row in zip(rate_bits, result)])
32
33
34if __name__ == '__main__':

Callers 1

main.pyFile · 0.85

Calls 4

LDTParametersClass · 0.90
run_aurora_FRIFunction · 0.90
run_aurora_STIRFunction · 0.90
argument_sizeMethod · 0.45

Tested by

no test coverage detected