import json from evaluate_pointcloud_dataset import evaluate_manifest def test_pointcloud_manifest_runner_aggregates_rows_and_failures(tmp_path): cloud = tmp_path / "cloud.ply" cloud.write_text("\n".join([ "ply", "format ascii 1.0", "element vertex 2", "property float x", "property float y", "property float z", "end_header", "0 0 0", "1 0 0", "", ]), encoding="utf-8") manifest = tmp_path / "pairs.jsonl" manifest.write_text("\n".join([ json.dumps({"id": "good", "prediction": cloud.name, "reference": cloud.name, "threshold": 0.01}), json.dumps({"id": "missing", "prediction": "missing.ply", "reference": cloud.name}), ]), encoding="utf-8") report = evaluate_manifest(manifest) assert report["successful_rows"] == 1 assert len(report["failed_rows"]) == 1 assert report["aggregate"]["fscore"]["mean"] == 1.0