Datasets:
Formats:
csv
Languages:
English
Size:
1K - 10K
Tags:
arxiv-artifact
reproducibility
research-artifact
computer-science
computer-logic
formal-methods
License:
| from pcmt.bitset import resolve_engine | |
| from pcmt.logic import formula_by_id, make_certificate | |
| from pcmt.schema import Window | |
| def test_speech_speaker_consistency_finds_counterexample(): | |
| windows = [ | |
| Window("v", 0, 0, 1, audio_atoms=("speech",), visual_atoms=(), subtitle_ocr_atoms=()), | |
| Window("v", 1, 1, 2, audio_atoms=("ambient",), visual_atoms=(), subtitle_ocr_atoms=()), | |
| ] | |
| formula = formula_by_id("speech_speaker_consistency") | |
| evaluation = formula.evaluate(windows, resolve_engine("cpu")) | |
| assert not evaluation.verdict | |
| assert evaluation.counterexample_window == (0, 1) | |
| cert = make_certificate(windows, evaluation, resolve_engine("cpu")) | |
| assert len(cert["certificate_hash"]) == 64 | |
| def test_audio_visual_event_consistency_passes_nearby_event(): | |
| windows = [ | |
| Window("v", 0, 0, 1, audio_atoms=("chop_sound",), visual_atoms=(), subtitle_ocr_atoms=()), | |
| Window("v", 1, 1, 2, audio_atoms=(), visual_atoms=("chopping",), subtitle_ocr_atoms=()), | |
| ] | |
| formula = formula_by_id("audio_visual_event_consistency") | |
| evaluation = formula.evaluate(windows, resolve_engine("cpu")) | |
| assert evaluation.verdict | |