aboutsummaryrefslogtreecommitdiff
path: root/etc/ratios.py
blob: 3748936f0b443ac93e9db0b2fda99e31dd44d0f5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#!/usr/bin/python3

curves = {}

try:
    while True:
        line = input()
        curve, variant, time = line.split()
        if curve not in curves:
            curves[curve] = {}
        curves[curve][variant] = time
except EOFError:
    pass

for curve, variants in curves.items():
    if 'fiat_solinas64' in variants and 'gmpvar64' in variants:
        print(curve, float(variants['gmpvar64']) / float(variants['fiat_solinas64']))
    if 'fiat_solinas32' in variants and 'gmpvar32' in variants:
        print(curve, float(variants['gmpvar32']) / float(variants['fiat_solinas32']))