Objects/Documentation
comparaison13.py
I provide the material for check AT.G27.
Download ↓"""Inspect the paired B benchmark and its published certificates. Use garanties12.py for full replay."""
from hashlib import sha256
from pathlib import Path
import json
HERE=Path(__file__).resolve().parent
def run():
rows=json.loads((HERE/'mesures-incremental13.json').read_bytes())
out=[]
for row,name in zip(rows,('certificat-libre-B.json','certificat-incremental13.json')):
raw=(HERE/name).read_bytes(); cert=json.loads(raw)['B']
n=len(cert['paths']); events=row['events']
assert n==row['final_paths']==row['readers']['sat']['answer']['paths']==row['readers']['special']['answer']['paths']
assert [e[1] for e in events]==list(range(2,n+1)) and len(cert['refutations'])==n-1
assert sorted(events)==events and row['paths_at_60']==max([1]+[k for s,k in events if s<=60])
out.append(dict(mode=row['mode'],at_60=row['paths_at_60'],final=n,