text string |
|---|
/verifier/test_outputs.py:400: AssertionError |
________________ test_block_frequency_reduction_matches_counts _________________ |
def test_block_frequency_reduction_matches_counts(): |
got = agent_blocks() |
ref = reference()["blocks"] |
keys = [ |
"run_id", |
"block_id", |
"t_s", |
"freq_R_hz", |
"freq_L_hz", |
"freq_bar_hz", |
"sigma_bar_hz", |
"field_gauss", |
"axial_khz", |
"zeeman_correction_hz", |
"quadrupole_correction_hz", |
"corrected_hz", |
"unwrap_R", |
"unwrap_L", |
] |
assert list(got[0]) == keys |
failures = [] |
for index, (actual, expected) in enumerate(zip(got, ref, strict=True)): |
if actual["run_id"] != expected["run_id"]: |
failures.append(f"row {index}: run_id") |
continue |
for key in ("block_id", "unwrap_R", "unwrap_L"): |
if int(float(actual[key])) != int(expected[key]): |
failures.append(f"row {index}: {key}") |
for key in ("freq_R_hz", "freq_L_hz", "freq_bar_hz", "corrected_hz"): |
if abs(float(actual[key]) - expected[key]) > 0.16: |
failures.append(f"row {index}: {key}") |
sigma = float(actual["sigma_bar_hz"]) |
if not (0.45 * expected["sigma_bar_hz"] <= sigma <= 2.2 * expected["sigma_bar_hz"]): |
failures.append(f"row {index}: sigma_bar_hz") |
for key in ( |
"field_gauss", |
"axial_khz", |
"zeeman_correction_hz", |
"quadrupole_correction_hz", |
): |
tolerance = 2e-5 if key == "field_gauss" else 0.025 |
if abs(float(actual[key]) - expected[key]) > tolerance: |
failures.append(f"row {index}: {key}") |
> assert not failures, "block reduction mismatch:\n" + "\n".join(failures[:40]) |
E AssertionError: block reduction mismatch: |
E row 0: unwrap_R |
E row 0: corrected_hz |
E row 0: zeeman_correction_hz |
E row 1: corrected_hz |
E row 1: zeeman_correction_hz |
E row 2: corrected_hz |
E row 2: zeeman_correction_hz |
E row 3: unwrap_L |
E row 3: corrected_hz |
E row 3: zeeman_correction_hz |
E row 4: corrected_hz |
E row 4: zeeman_correction_hz |
E row 5: unwrap_L |
E row 5: corrected_hz |
E row 5: zeeman_correction_hz |
E row 6: unwrap_L |
E row 6: corrected_hz |
E row 6: zeeman_correction_hz |
E row 7: unwrap_L |
E row 7: corrected_hz |
E row 7: zeeman_correction_hz |
E row 8: corrected_hz |
E row 8: zeeman_correction_hz |
E row 9: corrected_hz |
E row 9: zeeman_correction_hz |
E row 10: corrected_hz |
E row 10: zeeman_correction_hz |
E row 11: unwrap_R |
E row 11: corrected_hz |
E row 11: zeeman_correction_hz |
E row 12: unwrap_L |
E row 12: corrected_hz |
E row 12: zeeman_correction_hz |
E row 13: corrected_hz |
E row 13: zeeman_correction_hz |
E row 14: unwrap_R |
E row 14: corrected_hz |
E row 14: zeeman_correction_hz |
E row 15: corrected_hz |
E row 15: zeeman_correction_hz |
E assert not ['row 0: unwrap_R', 'row 0: corrected_hz', 'row 0: zeeman_correction_hz', 'row 1: corrected_hz', 'row 1: zeeman_correction_hz', 'row 2: corrected_hz', ...] |
/verifier/test_outputs.py:447: AssertionError |
___________________ test_hourly_bins_are_weighted_reductions ___________________ |
def test_hourly_bins_are_weighted_reductions(): |
got = agent_hourly() |
ref = reference()["hourly"] |
assert list(got[0]) == [ |
"run_id", |
"hour_index", |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.