feat: tune multi-source peak sensitivity
This commit is contained in:
@@ -61,6 +61,35 @@ test("단일 tone 장면과 실험이 관계 검증을 통과한다", async () =
|
||||
assertEqual((await validateExperiment(experiment, { arrayDefinition, scene })).length, 0, "experiment issues");
|
||||
});
|
||||
|
||||
test("Experiment 피크 검출 임계값 비율은 재현 가능하고 유효한 범위여야 한다", async () => {
|
||||
const [arrayDefinition, scene, experiment] = await Promise.all([
|
||||
loadJson("/assets/array-geometries/rectangular-16x12.array.json"),
|
||||
loadJson("/assets/sample-scenes/single-tone.scene.json"),
|
||||
loadJson("/assets/sample-scenes/single-tone.experiment.json"),
|
||||
]);
|
||||
assertEqual(experiment.evaluation.detectionThresholdRatio, 0.25, "sample threshold ratio");
|
||||
assertEqual(
|
||||
(await validateExperiment(experiment, { arrayDefinition, scene })).length,
|
||||
0,
|
||||
"0.25 threshold issues",
|
||||
);
|
||||
|
||||
experiment.evaluation.detectionThresholdRatio = 0;
|
||||
let issues = await validateExperiment(experiment, { arrayDefinition, scene });
|
||||
assert(
|
||||
issues.some(({ path, message }) =>
|
||||
path === "$.evaluation.detectionThresholdRatio" && message.includes("0보다 크고 1 이하")),
|
||||
"zero threshold is rejected with actionable guidance",
|
||||
);
|
||||
|
||||
experiment.evaluation.detectionThresholdRatio = 1.01;
|
||||
issues = await validateExperiment(experiment, { arrayDefinition, scene });
|
||||
assert(
|
||||
issues.some(({ path }) => path === "$.evaluation.detectionThresholdRatio"),
|
||||
"threshold above one is rejected",
|
||||
);
|
||||
});
|
||||
|
||||
test("이동 음원 trajectory의 keyframe 순서와 장면 시간 범위를 검증한다", async () => {
|
||||
const scene = await loadJson("/assets/sample-scenes/single-tone.scene.json");
|
||||
scene.sources[0].trajectory = [
|
||||
|
||||
Reference in New Issue
Block a user