feat(lidar): qualify Patchwork++ on GOOSE
This commit is contained in:
@@ -194,36 +194,97 @@ test("decodes one bounded point-aligned native-scan preview", async () => {
|
||||
);
|
||||
});
|
||||
|
||||
test("decodes a point-aligned current-vs-ground-truth comparison", async () => {
|
||||
test("decodes a point-aligned current-vs-Patchwork++ comparison", async () => {
|
||||
const payload = {
|
||||
schema_version: "missioncore.dataset-ground-comparison-preview/v1",
|
||||
schema_version: "missioncore.dataset-ground-comparison-preview/v2",
|
||||
source_id: "goose-3d/v2025-08-22",
|
||||
frame_id: "frame-1",
|
||||
sampling: "deterministic-even-index",
|
||||
point_count: 2,
|
||||
current_ground: [1, 1],
|
||||
patchwork_ground: [1, 0],
|
||||
patchwork_assigned: [1, 1],
|
||||
ground_truth_ground: [1, 0],
|
||||
evaluated: [1, 1],
|
||||
disagreement: [0, 1],
|
||||
current_disagreement: [0, 1],
|
||||
patchwork_disagreement: [0, 0],
|
||||
metrics: {
|
||||
true_positive: 1,
|
||||
false_positive: 1,
|
||||
false_negative: 0,
|
||||
true_negative: 0,
|
||||
precision: 0.5,
|
||||
recall: 1,
|
||||
f1: 2 / 3,
|
||||
ground_iou: 0.5,
|
||||
accuracy: 0.5,
|
||||
artificial_ground_recall: 1,
|
||||
natural_ground_recall: 0,
|
||||
obstacle_non_ground_recall: 1,
|
||||
current: {
|
||||
true_positive: 1,
|
||||
false_positive: 1,
|
||||
false_negative: 0,
|
||||
true_negative: 0,
|
||||
precision: 0.5,
|
||||
recall: 1,
|
||||
f1: 2 / 3,
|
||||
ground_iou: 0.5,
|
||||
accuracy: 0.5,
|
||||
artificial_ground_recall: 1,
|
||||
natural_ground_recall: 0,
|
||||
obstacle_non_ground_recall: 1,
|
||||
},
|
||||
patchworkpp: {
|
||||
true_positive: 1,
|
||||
false_positive: 0,
|
||||
false_negative: 0,
|
||||
true_negative: 1,
|
||||
precision: 1,
|
||||
recall: 1,
|
||||
f1: 1,
|
||||
ground_iou: 1,
|
||||
accuracy: 1,
|
||||
artificial_ground_recall: 1,
|
||||
natural_ground_recall: 1,
|
||||
obstacle_non_ground_recall: 1,
|
||||
},
|
||||
},
|
||||
latency_ms: 12.5,
|
||||
provider: {
|
||||
provider_id: "missioncore-local-percentile-ground/v1",
|
||||
implementation_sha256: "a".repeat(64),
|
||||
ground_truth: false,
|
||||
latency_ms: {
|
||||
current: 12.5,
|
||||
patchworkpp: 0.4,
|
||||
},
|
||||
patchwork_assigned_fraction: 1,
|
||||
providers: {
|
||||
current: {
|
||||
provider_id: "missioncore-local-percentile-ground/v1",
|
||||
implementation_sha256: "a".repeat(64),
|
||||
ground_truth: false,
|
||||
},
|
||||
patchworkpp: {
|
||||
provider_id: "patchworkpp/v1.4.1",
|
||||
source_url: "https://github.com/url-kaist/patchwork-plusplus",
|
||||
source_tag: "v1.4.1",
|
||||
source_commit: "3e6903a1d5537a4cc2ace897b0bbb98a92d6014c",
|
||||
binding_version: "0.0.1",
|
||||
binary_sha256: "b".repeat(64),
|
||||
platform: "linux",
|
||||
machine: "x86_64",
|
||||
ground_truth: false,
|
||||
},
|
||||
},
|
||||
input_profile: {
|
||||
schema_version: "missioncore.goose-patchwork-profile/v1",
|
||||
source_id: "goose-3d/v2025-08-22",
|
||||
representation: "native-scan",
|
||||
sensor_frame: {
|
||||
frame_id: "sensor/lidar/vls128_roof",
|
||||
handedness: "right",
|
||||
x: "forward",
|
||||
y: "left",
|
||||
z: "up",
|
||||
one_revolution: true,
|
||||
},
|
||||
height: {
|
||||
base_link_above_ground_m: 0.64,
|
||||
lidar_above_base_link_m: 1.6,
|
||||
sensor_above_ground_m: 2.24,
|
||||
evidence: "published-dimensioned-schematic",
|
||||
},
|
||||
scope: {
|
||||
patchworkpp_eligible: true,
|
||||
normalized_scan_produced: false,
|
||||
complete_vehicle_transform_known: false,
|
||||
deskew_claimed: false,
|
||||
},
|
||||
},
|
||||
safety: {
|
||||
qualification_only: true,
|
||||
@@ -231,15 +292,23 @@ test("decodes a point-aligned current-vs-ground-truth comparison", async () => {
|
||||
},
|
||||
};
|
||||
const parsed = parseDatasetGroundComparison(payload);
|
||||
assert.equal(parsed.metrics.groundIou, 0.5);
|
||||
assert.deepEqual(parsed.disagreement, [0, 1]);
|
||||
assert.equal(parsed.metrics.current.groundIou, 0.5);
|
||||
assert.equal(parsed.metrics.patchworkpp.groundIou, 1);
|
||||
assert.deepEqual(parsed.patchworkDisagreement, [0, 0]);
|
||||
assert.equal(parsed.inputProfile.sensorHeightM, 2.24);
|
||||
|
||||
const fetched = await fetchDatasetGroundComparison({
|
||||
fetcher: async () => new Response(JSON.stringify(payload), { status: 200 }),
|
||||
});
|
||||
assert.equal(fetched.latencyMs, 12.5);
|
||||
assert.equal(fetched.latencyMs.patchworkpp, 0.4);
|
||||
|
||||
payload.disagreement.pop();
|
||||
payload.patchwork_disagreement.pop();
|
||||
assert.throws(
|
||||
() => parseDatasetGroundComparison(payload),
|
||||
DatasetGatewayContractError,
|
||||
);
|
||||
payload.patchwork_disagreement.push(0);
|
||||
payload.input_profile.height.sensor_above_ground_m = 2.25;
|
||||
assert.throws(
|
||||
() => parseDatasetGroundComparison(payload),
|
||||
DatasetGatewayContractError,
|
||||
|
||||
Reference in New Issue
Block a user