FA-78251 / Subtitle cue timing / Open access
Pop-on caption buffer timing: frame time conversion · case 01
Caption times snap to whole seconds.
ROOT CAUSE
Frames are converted to whole seconds before multiplying to milliseconds.
VERIFIED REPAIR
Convert with frame*1000//fps.
Unsuccessful approach: Rounding to the nearest millisecond disagrees with the flooring convention.
Case contract
Commands [frame,cmd] at integer fps (time = frame*1000//fps). TEXT:x appends x to the non-displayed memory; ENM erases non-displayed memory; EOC swaps displayed and non-displayed memories; EDM erases displayed memory. Whenever non-empty displayed text is replaced (EOC) or erased (EDM), emit [shown_since_ms, now_ms, text].
Why this case matters
Subtitle timing defects shift, hide or overlap captions that viewers depend on for comprehension and accessibility.
1 / The failure
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(events, fps):
shown=''
hidden=''
since=None
out=[]
for frame,cmd in events:
t=frame//fps*1000
if cmd.startswith('TEXT:'):
hidden+=cmd[5:]
elif cmd=='ENM':
hidden=''
elif cmd=='EOC':
if shown:
out.append([since,t,shown])
shown,hidden=hidden,shown
since=t
elif cmd=='EDM':
if shown: out.append([since,t,shown])
shown=''
return out
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[('regression: frame time conversion', [[[0, 'TEXT:A'], [10, 'EOC'], [20, 'TEXT:B'], [40, 'EOC'], [50, 'EOC']], 25], [[400, 1600, 'A'], [1600, 2000, 'B']]), ('regression variant: frame time conversion', [[[30, 'EDM'], [60, 'TEXT: there'], [67, 'EOC'], [112, 'EOC']], 24], [[2791, 4666, ' there']]), ('partial repair probe: frame time conversion', [[[0, 'TEXT:Bye'], [29, 'TEXT: there'], [44, 'TEXT: there'], [44, 'EOC'], [51, 'EOC']], 29], [[1517, 1758, 'Bye there there']]), ('partial repair variant: frame time conversion', [[[3, 'TEXT: there'], [32, 'EDM'], [62, 'TEXT: there'], [77, 'ENM'], [84, 'TEXT:Hi'], [114, 'EOC'], [121, 'EOC'], [121, 'TEXT: there']], 24], [[4750, 5041, 'Hi']]), ('boundary control', [[[0, 'TEXT:Hi'], [30, 'EOC'], [60, 'EDM']], 30], [[1000, 2000, 'Hi']]), ('boundary control', [[[0, 'EOC'], [5, 'EDM']], 30], []), ('normal control', [[[30, 'EOC'], [30, 'TEXT:Hi'], [37, 'ENM']], 24], []), ('normal control', [[[0, 'EOC'], [7, 'TEXT:Bye'], [52, 'EDM'], [59, 'TEXT:Bye'], [74, 'EOC']], 24], []), ('normal control', [[[30, 'TEXT: there'], [30, 'EOC'], [59, 'ENM']], 30], [])], [('regression: frame time conversion', [[[30, 'TEXT:Bye'], [37, 'EOC'], [52, 'EDM'], [52, 'ENM'], [67, 'EDM']], 30], [[1233, 1733, 'Bye']]), ('regression variant: frame time conversion', [[[3, 'EDM'], [48, 'EOC'], [93, 'TEXT:Bye'], [123, 'EOC'], [130, 'EDM']], 29], [[4241, 4482, 'Bye']]), ('partial repair probe: frame time conversion', [[[0, 'TEXT:Bye'], [7, 'EOC'], [14, 'EDM'], [43, 'ENM'], [88, 'EDM'], [95, 'EOC'], [95, 'EOC'], [125, 'TEXT:Bye']], 24], [[291, 583, 'Bye']]), ('partial repair variant: frame time conversion', [[[30, 'TEXT:Hi'], [31, 'TEXT:Bye'], [61, 'EOC'], [91, 'TEXT:Bye'], [92, 'TEXT: there'], [93, 'ENM'], [93, 'TEXT:Hi'], [122, 'EOC']], 24], [[2541, 5083, 'HiBye']]), ('boundary control', [[[0, 'EOC'], [5, 'EDM']], 30], []), ('boundary control', [[[0, 'TEXT:Hi'], [30, 'EOC'], [60, 'EDM']], 30], [[1000, 2000, 'Hi']]), ('normal control', [[[3, 'EDM'], [32, 'EOC']], 29], []), ('normal control', [[[0, 'ENM'], [0, 'EOC'], [30, 'TEXT:Hi']], 24], []), ('normal control', [[[0, 'TEXT:Bye'], [1, 'EDM'], [31, 'TEXT: there'], [61, 'ENM'], [68, 'EOC'], [98, 'EOC'], [113, 'TEXT:Bye']], 25], [])], [('regression: frame time conversion', [[[0, 'EOC'], [30, 'TEXT:Bye'], [31, 'EOC'], [46, 'EOC'], [91, 'TEXT:Hi'], [92, 'TEXT: there'], [99, 'EDM'], [129, 'ENM']], 30], [[1033, 1533, 'Bye']]), ('regression variant: frame time conversion', [[[3, 'TEXT:Hi'], [48, 'EOC'], [49, 'EOC'], [49, 'TEXT:Hi'], [94, 'TEXT:Bye'], [123, 'EOC'], [130, 'EDM']], 25], [[1920, 1960, 'Hi'], [4920, 5200, 'HiHiBye']]), ('partial repair probe: frame time conversion', [[[3, 'ENM'], [3, 'TEXT:Bye'], [10, 'EOC'], [10, 'EOC'], [55, 'TEXT:Bye'], [56, 'EOC']], 29], [[344, 344, 'Bye']]), ('partial repair variant: frame time conversion', [[[0, 'TEXT: there'], [1, 'EOC'], [31, 'EDM'], [38, 'EOC'], [45, 'TEXT: there'], [46, 'ENM'], [76, 'TEXT: there']], 29], [[34, 1068, ' there']]), ('boundary control', [[[0, 'TEXT:Hi'], [30, 'EOC'], [60, 'EDM']], 30], [[1000, 2000, 'Hi']]), ('boundary control', [[[0, 'EOC'], [5, 'EDM']], 30], []), ('normal control', [[[30, 'TEXT: there'], [31, 'EDM']], 24], []), ('normal control', [[[30, 'EOC'], [59, 'EOC'], [60, 'TEXT: there'], [89, 'TEXT: there'], [96, 'ENM'], [96, 'TEXT:Bye'], [96, 'TEXT:Bye'], [96, 'TEXT: there']], 30], []), ('normal control', [[[0, 'EOC'], [29, 'EOC'], [29, 'ENM'], [36, 'TEXT: there'], [37, 'TEXT: there'], [38, 'EOC']], 25], [])], [('regression: frame time conversion', [[[3, 'TEXT: there'], [32, 'TEXT: there'], [33, 'TEXT: there'], [48, 'EOC'], [78, 'EOC'], [123, 'TEXT: there']], 25], [[1920, 3120, ' there there there']]), ('regression variant: frame time conversion', [[[0, 'TEXT:Bye'], [29, 'TEXT: there'], [44, 'TEXT: there'], [44, 'EOC'], [51, 'EOC']], 29], [[1517, 1758, 'Bye there there']]), ('partial repair probe: frame time conversion', [[[30, 'TEXT:Bye'], [31, 'ENM'], [76, 'EOC'], [106, 'TEXT:Hi'], [107, 'EDM'], [137, 'EOC'], [166, 'EDM'], [167, 'TEXT: there']], 24], [[5708, 6916, 'Hi']]), ('partial repair variant: frame time conversion', [[[3, 'TEXT: there'], [4, 'EOC'], [11, 'EOC'], [12, 'TEXT:Hi'], [42, 'EOC'], [57, 'ENM']], 24], [[166, 458, ' there']]), ('boundary control', [[[0, 'EOC'], [5, 'EDM']], 30], []), ('boundary control', [[[0, 'TEXT:Hi'], [30, 'EOC'], [60, 'EDM']], 30], [[1000, 2000, 'Hi']]), ('normal control', [[[30, 'EDM'], [60, 'TEXT: there'], [90, 'TEXT:Bye']], 24], []), ('normal control', [[[0, 'EOC'], [7, 'TEXT:Bye'], [14, 'TEXT:Bye']], 25], []), ('normal control', [[[3, 'EDM'], [33, 'TEXT:Bye'], [63, 'TEXT:Hi'], [108, 'EOC'], [109, 'TEXT:Hi']], 30], [])], [('regression: frame time conversion', [[[30, 'TEXT:Bye'], [59, 'EOC'], [66, 'TEXT:Bye'], [111, 'EOC']], 24], [[2458, 4625, 'Bye']]), ('regression variant: frame time conversion', [[[0, 'TEXT:Bye'], [7, 'EOC'], [14, 'EDM'], [43, 'ENM'], [88, 'EDM'], [95, 'EOC'], [95, 'EOC'], [125, 'TEXT:Bye']], 24], [[291, 583, 'Bye']]), ('partial repair probe: frame time conversion', [[[30, 'TEXT: there'], [45, 'EOC'], [52, 'EOC'], [82, 'ENM'], [82, 'TEXT:Bye'], [127, 'EOC'], [127, 'EOC'], [156, 'TEXT:Hi']], 29], [[1551, 1793, ' there'], [4379, 4379, 'Bye']]), ('partial repair variant: frame time conversion', [[[3, 'TEXT:Hi'], [33, 'TEXT: there'], [48, 'TEXT: there'], [93, 'EOC'], [100, 'EOC']], 29], [[3206, 3448, 'Hi there there']]), ('boundary control', [[[0, 'TEXT:Hi'], [30, 'EOC'], [60, 'EDM']], 30], [[1000, 2000, 'Hi']]), ('boundary control', [[[0, 'EOC'], [5, 'EDM']], 30], []), ('normal control', [[[30, 'ENM'], [31, 'TEXT: there'], [60, 'EDM'], [89, 'ENM'], [96, 'EDM'], [111, 'EOC']], 30], []), ('normal control', [[[30, 'EOC'], [60, 'TEXT: there']], 29], []), ('normal control', [[[0, 'TEXT:Hi'], [45, 'ENM'], [60, 'EDM'], [89, 'TEXT:Hi'], [104, 'TEXT:Bye'], [119, 'EDM'], [126, 'TEXT: there']], 24], [])]]
for label, args, expected in fixtures[N-1]:
check(label, solve(*args), expected)
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
| Boundary fixture | Actual | Expected | Outcome |
|---|---|---|---|
| regression: frame time conversion | [[0, 1000, 'A'], [1000, 2000, 'B']] | [[400, 1600, 'A'], [1600, 2000, 'B']] | Failed |
| regression variant: frame time conversion | [[2000, 4000, ' there']] | [[2791, 4666, ' there']] | Failed |
| partial repair probe: frame time conversion | [[1000, 1000, 'Bye there there']] | [[1517, 1758, 'Bye there there']] | Failed |
| partial repair variant: frame time conversion | [[4000, 5000, 'Hi']] | [[4750, 5041, 'Hi']] | Failed |
| boundary control | [[1000, 2000, 'Hi']] | [[1000, 2000, 'Hi']] | Passed |
| boundary control | [] | [] | Passed |
| normal control | [] | [] | Passed |
| normal control | [] | [] | Passed |
| normal control | [] | [] | Passed |
SHA-256 / 5626dca6e3e0d96d280862c95c6f6178c0d32a61bcc8d009c451593e33852e38
2 / The unsuccessful fix
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(events, fps):
shown=''
hidden=''
since=None
out=[]
for frame,cmd in events:
t=round(frame*1000/fps)
if cmd.startswith('TEXT:'):
hidden+=cmd[5:]
elif cmd=='ENM':
hidden=''
elif cmd=='EOC':
if shown:
out.append([since,t,shown])
shown,hidden=hidden,shown
since=t
elif cmd=='EDM':
if shown: out.append([since,t,shown])
shown=''
return out
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[('regression: frame time conversion', [[[0, 'TEXT:A'], [10, 'EOC'], [20, 'TEXT:B'], [40, 'EOC'], [50, 'EOC']], 25], [[400, 1600, 'A'], [1600, 2000, 'B']]), ('regression variant: frame time conversion', [[[30, 'EDM'], [60, 'TEXT: there'], [67, 'EOC'], [112, 'EOC']], 24], [[2791, 4666, ' there']]), ('partial repair probe: frame time conversion', [[[0, 'TEXT:Bye'], [29, 'TEXT: there'], [44, 'TEXT: there'], [44, 'EOC'], [51, 'EOC']], 29], [[1517, 1758, 'Bye there there']]), ('partial repair variant: frame time conversion', [[[3, 'TEXT: there'], [32, 'EDM'], [62, 'TEXT: there'], [77, 'ENM'], [84, 'TEXT:Hi'], [114, 'EOC'], [121, 'EOC'], [121, 'TEXT: there']], 24], [[4750, 5041, 'Hi']]), ('boundary control', [[[0, 'TEXT:Hi'], [30, 'EOC'], [60, 'EDM']], 30], [[1000, 2000, 'Hi']]), ('boundary control', [[[0, 'EOC'], [5, 'EDM']], 30], []), ('normal control', [[[30, 'EOC'], [30, 'TEXT:Hi'], [37, 'ENM']], 24], []), ('normal control', [[[0, 'EOC'], [7, 'TEXT:Bye'], [52, 'EDM'], [59, 'TEXT:Bye'], [74, 'EOC']], 24], []), ('normal control', [[[30, 'TEXT: there'], [30, 'EOC'], [59, 'ENM']], 30], [])], [('regression: frame time conversion', [[[30, 'TEXT:Bye'], [37, 'EOC'], [52, 'EDM'], [52, 'ENM'], [67, 'EDM']], 30], [[1233, 1733, 'Bye']]), ('regression variant: frame time conversion', [[[3, 'EDM'], [48, 'EOC'], [93, 'TEXT:Bye'], [123, 'EOC'], [130, 'EDM']], 29], [[4241, 4482, 'Bye']]), ('partial repair probe: frame time conversion', [[[0, 'TEXT:Bye'], [7, 'EOC'], [14, 'EDM'], [43, 'ENM'], [88, 'EDM'], [95, 'EOC'], [95, 'EOC'], [125, 'TEXT:Bye']], 24], [[291, 583, 'Bye']]), ('partial repair variant: frame time conversion', [[[30, 'TEXT:Hi'], [31, 'TEXT:Bye'], [61, 'EOC'], [91, 'TEXT:Bye'], [92, 'TEXT: there'], [93, 'ENM'], [93, 'TEXT:Hi'], [122, 'EOC']], 24], [[2541, 5083, 'HiBye']]), ('boundary control', [[[0, 'EOC'], [5, 'EDM']], 30], []), ('boundary control', [[[0, 'TEXT:Hi'], [30, 'EOC'], [60, 'EDM']], 30], [[1000, 2000, 'Hi']]), ('normal control', [[[3, 'EDM'], [32, 'EOC']], 29], []), ('normal control', [[[0, 'ENM'], [0, 'EOC'], [30, 'TEXT:Hi']], 24], []), ('normal control', [[[0, 'TEXT:Bye'], [1, 'EDM'], [31, 'TEXT: there'], [61, 'ENM'], [68, 'EOC'], [98, 'EOC'], [113, 'TEXT:Bye']], 25], [])], [('regression: frame time conversion', [[[0, 'EOC'], [30, 'TEXT:Bye'], [31, 'EOC'], [46, 'EOC'], [91, 'TEXT:Hi'], [92, 'TEXT: there'], [99, 'EDM'], [129, 'ENM']], 30], [[1033, 1533, 'Bye']]), ('regression variant: frame time conversion', [[[3, 'TEXT:Hi'], [48, 'EOC'], [49, 'EOC'], [49, 'TEXT:Hi'], [94, 'TEXT:Bye'], [123, 'EOC'], [130, 'EDM']], 25], [[1920, 1960, 'Hi'], [4920, 5200, 'HiHiBye']]), ('partial repair probe: frame time conversion', [[[3, 'ENM'], [3, 'TEXT:Bye'], [10, 'EOC'], [10, 'EOC'], [55, 'TEXT:Bye'], [56, 'EOC']], 29], [[344, 344, 'Bye']]), ('partial repair variant: frame time conversion', [[[0, 'TEXT: there'], [1, 'EOC'], [31, 'EDM'], [38, 'EOC'], [45, 'TEXT: there'], [46, 'ENM'], [76, 'TEXT: there']], 29], [[34, 1068, ' there']]), ('boundary control', [[[0, 'TEXT:Hi'], [30, 'EOC'], [60, 'EDM']], 30], [[1000, 2000, 'Hi']]), ('boundary control', [[[0, 'EOC'], [5, 'EDM']], 30], []), ('normal control', [[[30, 'TEXT: there'], [31, 'EDM']], 24], []), ('normal control', [[[30, 'EOC'], [59, 'EOC'], [60, 'TEXT: there'], [89, 'TEXT: there'], [96, 'ENM'], [96, 'TEXT:Bye'], [96, 'TEXT:Bye'], [96, 'TEXT: there']], 30], []), ('normal control', [[[0, 'EOC'], [29, 'EOC'], [29, 'ENM'], [36, 'TEXT: there'], [37, 'TEXT: there'], [38, 'EOC']], 25], [])], [('regression: frame time conversion', [[[3, 'TEXT: there'], [32, 'TEXT: there'], [33, 'TEXT: there'], [48, 'EOC'], [78, 'EOC'], [123, 'TEXT: there']], 25], [[1920, 3120, ' there there there']]), ('regression variant: frame time conversion', [[[0, 'TEXT:Bye'], [29, 'TEXT: there'], [44, 'TEXT: there'], [44, 'EOC'], [51, 'EOC']], 29], [[1517, 1758, 'Bye there there']]), ('partial repair probe: frame time conversion', [[[30, 'TEXT:Bye'], [31, 'ENM'], [76, 'EOC'], [106, 'TEXT:Hi'], [107, 'EDM'], [137, 'EOC'], [166, 'EDM'], [167, 'TEXT: there']], 24], [[5708, 6916, 'Hi']]), ('partial repair variant: frame time conversion', [[[3, 'TEXT: there'], [4, 'EOC'], [11, 'EOC'], [12, 'TEXT:Hi'], [42, 'EOC'], [57, 'ENM']], 24], [[166, 458, ' there']]), ('boundary control', [[[0, 'EOC'], [5, 'EDM']], 30], []), ('boundary control', [[[0, 'TEXT:Hi'], [30, 'EOC'], [60, 'EDM']], 30], [[1000, 2000, 'Hi']]), ('normal control', [[[30, 'EDM'], [60, 'TEXT: there'], [90, 'TEXT:Bye']], 24], []), ('normal control', [[[0, 'EOC'], [7, 'TEXT:Bye'], [14, 'TEXT:Bye']], 25], []), ('normal control', [[[3, 'EDM'], [33, 'TEXT:Bye'], [63, 'TEXT:Hi'], [108, 'EOC'], [109, 'TEXT:Hi']], 30], [])], [('regression: frame time conversion', [[[30, 'TEXT:Bye'], [59, 'EOC'], [66, 'TEXT:Bye'], [111, 'EOC']], 24], [[2458, 4625, 'Bye']]), ('regression variant: frame time conversion', [[[0, 'TEXT:Bye'], [7, 'EOC'], [14, 'EDM'], [43, 'ENM'], [88, 'EDM'], [95, 'EOC'], [95, 'EOC'], [125, 'TEXT:Bye']], 24], [[291, 583, 'Bye']]), ('partial repair probe: frame time conversion', [[[30, 'TEXT: there'], [45, 'EOC'], [52, 'EOC'], [82, 'ENM'], [82, 'TEXT:Bye'], [127, 'EOC'], [127, 'EOC'], [156, 'TEXT:Hi']], 29], [[1551, 1793, ' there'], [4379, 4379, 'Bye']]), ('partial repair variant: frame time conversion', [[[3, 'TEXT:Hi'], [33, 'TEXT: there'], [48, 'TEXT: there'], [93, 'EOC'], [100, 'EOC']], 29], [[3206, 3448, 'Hi there there']]), ('boundary control', [[[0, 'TEXT:Hi'], [30, 'EOC'], [60, 'EDM']], 30], [[1000, 2000, 'Hi']]), ('boundary control', [[[0, 'EOC'], [5, 'EDM']], 30], []), ('normal control', [[[30, 'ENM'], [31, 'TEXT: there'], [60, 'EDM'], [89, 'ENM'], [96, 'EDM'], [111, 'EOC']], 30], []), ('normal control', [[[30, 'EOC'], [60, 'TEXT: there']], 29], []), ('normal control', [[[0, 'TEXT:Hi'], [45, 'ENM'], [60, 'EDM'], [89, 'TEXT:Hi'], [104, 'TEXT:Bye'], [119, 'EDM'], [126, 'TEXT: there']], 24], [])]]
for label, args, expected in fixtures[N-1]:
check(label, solve(*args), expected)
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
| Boundary fixture | Actual | Expected | Outcome |
|---|---|---|---|
| regression: frame time conversion | [[400, 1600, 'A'], [1600, 2000, 'B']] | [[400, 1600, 'A'], [1600, 2000, 'B']] | Passed |
| regression variant: frame time conversion | [[2792, 4667, ' there']] | [[2791, 4666, ' there']] | Failed |
| partial repair probe: frame time conversion | [[1517, 1759, 'Bye there there']] | [[1517, 1758, 'Bye there there']] | Failed |
| partial repair variant: frame time conversion | [[4750, 5042, 'Hi']] | [[4750, 5041, 'Hi']] | Failed |
| boundary control | [[1000, 2000, 'Hi']] | [[1000, 2000, 'Hi']] | Passed |
| boundary control | [] | [] | Passed |
| normal control | [] | [] | Passed |
| normal control | [] | [] | Passed |
| normal control | [] | [] | Passed |
SHA-256 / 196946f9a6ede383f4c7039a3eaf70c8050496a92b81038d5cb2343effb8ca31
3 / The verified repair
Exit 0"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(events, fps):
shown=''
hidden=''
since=None
out=[]
for frame,cmd in events:
t=frame*1000//fps
if cmd.startswith('TEXT:'):
hidden+=cmd[5:]
elif cmd=='ENM':
hidden=''
elif cmd=='EOC':
if shown:
out.append([since,t,shown])
shown,hidden=hidden,shown
since=t
elif cmd=='EDM':
if shown: out.append([since,t,shown])
shown=''
return out
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[('regression: frame time conversion', [[[0, 'TEXT:A'], [10, 'EOC'], [20, 'TEXT:B'], [40, 'EOC'], [50, 'EOC']], 25], [[400, 1600, 'A'], [1600, 2000, 'B']]), ('regression variant: frame time conversion', [[[30, 'EDM'], [60, 'TEXT: there'], [67, 'EOC'], [112, 'EOC']], 24], [[2791, 4666, ' there']]), ('partial repair probe: frame time conversion', [[[0, 'TEXT:Bye'], [29, 'TEXT: there'], [44, 'TEXT: there'], [44, 'EOC'], [51, 'EOC']], 29], [[1517, 1758, 'Bye there there']]), ('partial repair variant: frame time conversion', [[[3, 'TEXT: there'], [32, 'EDM'], [62, 'TEXT: there'], [77, 'ENM'], [84, 'TEXT:Hi'], [114, 'EOC'], [121, 'EOC'], [121, 'TEXT: there']], 24], [[4750, 5041, 'Hi']]), ('boundary control', [[[0, 'TEXT:Hi'], [30, 'EOC'], [60, 'EDM']], 30], [[1000, 2000, 'Hi']]), ('boundary control', [[[0, 'EOC'], [5, 'EDM']], 30], []), ('normal control', [[[30, 'EOC'], [30, 'TEXT:Hi'], [37, 'ENM']], 24], []), ('normal control', [[[0, 'EOC'], [7, 'TEXT:Bye'], [52, 'EDM'], [59, 'TEXT:Bye'], [74, 'EOC']], 24], []), ('normal control', [[[30, 'TEXT: there'], [30, 'EOC'], [59, 'ENM']], 30], [])], [('regression: frame time conversion', [[[30, 'TEXT:Bye'], [37, 'EOC'], [52, 'EDM'], [52, 'ENM'], [67, 'EDM']], 30], [[1233, 1733, 'Bye']]), ('regression variant: frame time conversion', [[[3, 'EDM'], [48, 'EOC'], [93, 'TEXT:Bye'], [123, 'EOC'], [130, 'EDM']], 29], [[4241, 4482, 'Bye']]), ('partial repair probe: frame time conversion', [[[0, 'TEXT:Bye'], [7, 'EOC'], [14, 'EDM'], [43, 'ENM'], [88, 'EDM'], [95, 'EOC'], [95, 'EOC'], [125, 'TEXT:Bye']], 24], [[291, 583, 'Bye']]), ('partial repair variant: frame time conversion', [[[30, 'TEXT:Hi'], [31, 'TEXT:Bye'], [61, 'EOC'], [91, 'TEXT:Bye'], [92, 'TEXT: there'], [93, 'ENM'], [93, 'TEXT:Hi'], [122, 'EOC']], 24], [[2541, 5083, 'HiBye']]), ('boundary control', [[[0, 'EOC'], [5, 'EDM']], 30], []), ('boundary control', [[[0, 'TEXT:Hi'], [30, 'EOC'], [60, 'EDM']], 30], [[1000, 2000, 'Hi']]), ('normal control', [[[3, 'EDM'], [32, 'EOC']], 29], []), ('normal control', [[[0, 'ENM'], [0, 'EOC'], [30, 'TEXT:Hi']], 24], []), ('normal control', [[[0, 'TEXT:Bye'], [1, 'EDM'], [31, 'TEXT: there'], [61, 'ENM'], [68, 'EOC'], [98, 'EOC'], [113, 'TEXT:Bye']], 25], [])], [('regression: frame time conversion', [[[0, 'EOC'], [30, 'TEXT:Bye'], [31, 'EOC'], [46, 'EOC'], [91, 'TEXT:Hi'], [92, 'TEXT: there'], [99, 'EDM'], [129, 'ENM']], 30], [[1033, 1533, 'Bye']]), ('regression variant: frame time conversion', [[[3, 'TEXT:Hi'], [48, 'EOC'], [49, 'EOC'], [49, 'TEXT:Hi'], [94, 'TEXT:Bye'], [123, 'EOC'], [130, 'EDM']], 25], [[1920, 1960, 'Hi'], [4920, 5200, 'HiHiBye']]), ('partial repair probe: frame time conversion', [[[3, 'ENM'], [3, 'TEXT:Bye'], [10, 'EOC'], [10, 'EOC'], [55, 'TEXT:Bye'], [56, 'EOC']], 29], [[344, 344, 'Bye']]), ('partial repair variant: frame time conversion', [[[0, 'TEXT: there'], [1, 'EOC'], [31, 'EDM'], [38, 'EOC'], [45, 'TEXT: there'], [46, 'ENM'], [76, 'TEXT: there']], 29], [[34, 1068, ' there']]), ('boundary control', [[[0, 'TEXT:Hi'], [30, 'EOC'], [60, 'EDM']], 30], [[1000, 2000, 'Hi']]), ('boundary control', [[[0, 'EOC'], [5, 'EDM']], 30], []), ('normal control', [[[30, 'TEXT: there'], [31, 'EDM']], 24], []), ('normal control', [[[30, 'EOC'], [59, 'EOC'], [60, 'TEXT: there'], [89, 'TEXT: there'], [96, 'ENM'], [96, 'TEXT:Bye'], [96, 'TEXT:Bye'], [96, 'TEXT: there']], 30], []), ('normal control', [[[0, 'EOC'], [29, 'EOC'], [29, 'ENM'], [36, 'TEXT: there'], [37, 'TEXT: there'], [38, 'EOC']], 25], [])], [('regression: frame time conversion', [[[3, 'TEXT: there'], [32, 'TEXT: there'], [33, 'TEXT: there'], [48, 'EOC'], [78, 'EOC'], [123, 'TEXT: there']], 25], [[1920, 3120, ' there there there']]), ('regression variant: frame time conversion', [[[0, 'TEXT:Bye'], [29, 'TEXT: there'], [44, 'TEXT: there'], [44, 'EOC'], [51, 'EOC']], 29], [[1517, 1758, 'Bye there there']]), ('partial repair probe: frame time conversion', [[[30, 'TEXT:Bye'], [31, 'ENM'], [76, 'EOC'], [106, 'TEXT:Hi'], [107, 'EDM'], [137, 'EOC'], [166, 'EDM'], [167, 'TEXT: there']], 24], [[5708, 6916, 'Hi']]), ('partial repair variant: frame time conversion', [[[3, 'TEXT: there'], [4, 'EOC'], [11, 'EOC'], [12, 'TEXT:Hi'], [42, 'EOC'], [57, 'ENM']], 24], [[166, 458, ' there']]), ('boundary control', [[[0, 'EOC'], [5, 'EDM']], 30], []), ('boundary control', [[[0, 'TEXT:Hi'], [30, 'EOC'], [60, 'EDM']], 30], [[1000, 2000, 'Hi']]), ('normal control', [[[30, 'EDM'], [60, 'TEXT: there'], [90, 'TEXT:Bye']], 24], []), ('normal control', [[[0, 'EOC'], [7, 'TEXT:Bye'], [14, 'TEXT:Bye']], 25], []), ('normal control', [[[3, 'EDM'], [33, 'TEXT:Bye'], [63, 'TEXT:Hi'], [108, 'EOC'], [109, 'TEXT:Hi']], 30], [])], [('regression: frame time conversion', [[[30, 'TEXT:Bye'], [59, 'EOC'], [66, 'TEXT:Bye'], [111, 'EOC']], 24], [[2458, 4625, 'Bye']]), ('regression variant: frame time conversion', [[[0, 'TEXT:Bye'], [7, 'EOC'], [14, 'EDM'], [43, 'ENM'], [88, 'EDM'], [95, 'EOC'], [95, 'EOC'], [125, 'TEXT:Bye']], 24], [[291, 583, 'Bye']]), ('partial repair probe: frame time conversion', [[[30, 'TEXT: there'], [45, 'EOC'], [52, 'EOC'], [82, 'ENM'], [82, 'TEXT:Bye'], [127, 'EOC'], [127, 'EOC'], [156, 'TEXT:Hi']], 29], [[1551, 1793, ' there'], [4379, 4379, 'Bye']]), ('partial repair variant: frame time conversion', [[[3, 'TEXT:Hi'], [33, 'TEXT: there'], [48, 'TEXT: there'], [93, 'EOC'], [100, 'EOC']], 29], [[3206, 3448, 'Hi there there']]), ('boundary control', [[[0, 'TEXT:Hi'], [30, 'EOC'], [60, 'EDM']], 30], [[1000, 2000, 'Hi']]), ('boundary control', [[[0, 'EOC'], [5, 'EDM']], 30], []), ('normal control', [[[30, 'ENM'], [31, 'TEXT: there'], [60, 'EDM'], [89, 'ENM'], [96, 'EDM'], [111, 'EOC']], 30], []), ('normal control', [[[30, 'EOC'], [60, 'TEXT: there']], 29], []), ('normal control', [[[0, 'TEXT:Hi'], [45, 'ENM'], [60, 'EDM'], [89, 'TEXT:Hi'], [104, 'TEXT:Bye'], [119, 'EDM'], [126, 'TEXT: there']], 24], [])]]
for label, args, expected in fixtures[N-1]:
check(label, solve(*args), expected)
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
| Boundary fixture | Actual | Expected | Outcome |
|---|---|---|---|
| regression: frame time conversion | [[400, 1600, 'A'], [1600, 2000, 'B']] | [[400, 1600, 'A'], [1600, 2000, 'B']] | Passed |
| regression variant: frame time conversion | [[2791, 4666, ' there']] | [[2791, 4666, ' there']] | Passed |
| partial repair probe: frame time conversion | [[1517, 1758, 'Bye there there']] | [[1517, 1758, 'Bye there there']] | Passed |
| partial repair variant: frame time conversion | [[4750, 5041, 'Hi']] | [[4750, 5041, 'Hi']] | Passed |
| boundary control | [[1000, 2000, 'Hi']] | [[1000, 2000, 'Hi']] | Passed |
| boundary control | [] | [] | Passed |
| normal control | [] | [] | Passed |
| normal control | [] | [] | Passed |
| normal control | [] | [] | Passed |
SHA-256 / 758bde7358d4c512cba893fb7de18072601dfde828b10de15ae42554fd8a7094
Verification & scope
A deterministic bounded teaching model with a stipulated toy contract; it does not claim conformance to any subtitle standard. This reproducer isolates one failure mechanism. Results cover the supplied fixtures. Variants within a family share a test contract and should remain grouped when constructing evaluation splits. Related mechanisms with a shared evaluation_group must also remain together; these controlled models are not independent production incidents.
Observations recorded using Python 3.12.14 at 2026-09-29T14:49:33.411823+00:00.
Case digest / e444cafcb374e94a39f84c27e09883afb6da84e4e3c637fbc238c43e9a841e22