feat(laboratory): publish repeated M48S load envelope

This commit is contained in:
DCCONSTRUCTIONS
2026-08-25 22:31:27 +03:00
parent f50e0077c5
commit 209d0bfc26
9 changed files with 898 additions and 173 deletions
@@ -118,8 +118,12 @@ export interface M48SLoadEnvelopeScenario {
worldStateCompletionAgeP95Ms: number;
worldStateCompletionAgeP99Ms: number;
worldStateCompletionAgeMaximumMs: number;
decodeP95Ms: number;
decodeMaximumMs: number;
hotLoopDecodeP95Ms: number;
hotLoopDecodeMaximumMs: number;
preadmissionDecodeMaximumMs: number;
sourcePrefetchPreparationMaximumMs: number;
sourcePacingLatenessP95Ms: number;
sourcePacingLatenessMaximumMs: number;
detectorP95Ms: number;
detectorMaximumMs: number;
gpuUtilizationMeanPercent: number;
@@ -129,6 +133,8 @@ export interface M48SLoadEnvelopeScenario {
queueHighWatermarks: Readonly<Record<"detector" | "geometry" | "temporal" | "rolling" | "threat", number>>;
queueCapacity: number;
additionalInferencePasses: number;
repeatCount: number;
allRepetitionsPassed: boolean;
integrityGatePassed: boolean;
operatingTargetGatePassed: boolean;
thresholds: {
@@ -136,15 +142,36 @@ export interface M48SLoadEnvelopeScenario {
minimumEffectiveWorldStateFps: number;
maximumWorldStateCompletionP95Ms: number;
};
repetitions: readonly M48SLoadEnvelopeRepetition[];
}
export interface M48SLoadEnvelopeRepetition {
runId: string;
repetition: 1 | 2 | 3;
deliveredWorldStates: number;
supersededFrames: number;
deliveryRatio: number;
effectiveWorldStateFps: number;
worldStateCompletionAgeP95Ms: number;
hotLoopDecodeP95Ms: number;
hotLoopDecodeMaximumMs: number;
preadmissionDecodeMaximumMs: number;
sourcePacingLatenessMaximumMs: number;
operatingTargetGatePassed: boolean;
resultSha256: string;
frameEvidenceSha256: string;
}
export interface M48SLoadEnvelopeComparison {
productionRateRepeatabilityPassed: false;
reserve12FpsPassed: true;
limit15FpsPassed: true;
loadEnvelopeAccepted: false;
repeatCountPerRate: number;
productionRateRepeatabilityPassed: boolean;
reserve12FpsPassed: boolean;
limit15FpsPassed: boolean;
loadEnvelopeAccepted: boolean;
computeCapacityAtLeastFps: 15;
bottleneckInterpretation: "rare-source-decode-or-scheduling-tail-not-steady-gpu-saturation";
bottleneckInterpretation:
| "rare-source-decode-or-scheduling-tail-not-steady-gpu-saturation"
| "cold-video-decode-isolated-before-admission-no-steady-gpu-saturation";
scenarios: readonly M48SLoadEnvelopeScenario[];
}
@@ -508,24 +535,113 @@ function runtimeHardeningComparisonValue(value: unknown): M48SRuntimeHardeningCo
function loadEnvelopeComparisonValue(value: unknown): M48SLoadEnvelopeComparison {
const comparison = objectValue(value, "M4.8S.metrics.load_envelope");
if (comparison.schema_version === "missioncore.m48s-load-envelope-comparison/v1") {
exact(comparison.production_rate_repeatability_passed, false, "M4.8S.load_envelope.production_rate_repeatability_passed");
exact(comparison.reserve_12_fps_passed, true, "M4.8S.load_envelope.reserve_12_fps_passed");
exact(comparison.limit_15_fps_passed, true, "M4.8S.load_envelope.limit_15_fps_passed");
exact(comparison.load_envelope_accepted, false, "M4.8S.load_envelope.load_envelope_accepted");
exact(comparison.compute_capacity_at_least_fps, 15, "M4.8S.load_envelope.compute_capacity_at_least_fps");
exact(
comparison.bottleneck_interpretation,
"rare-source-decode-or-scheduling-tail-not-steady-gpu-saturation",
"M4.8S.load_envelope.bottleneck_interpretation",
);
const ids = ["production-10fps", "reserve-12fps", "limit-15fps"] as const;
const purposes = ["production-rate", "reserve-gate", "limit-discovery"] as const;
const targetGates = [false, true, true] as const;
const scenarios = arrayValue(comparison.scenarios, "M4.8S.load_envelope.scenarios").map((value, index) => {
const label = `M4.8S.load_envelope.scenarios[${index}]`;
const scenario = objectValue(value, label);
const id = ids[index];
const purpose = purposes[index];
const targetGate = targetGates[index];
if (id === undefined || purpose === undefined || targetGate === undefined) {
throw new M48SFixedClassDetectorContractError("M4.8S.load_envelope.scenarios: лишний legacy-сценарий.");
}
exact(scenario.id, id, `${label}.id`);
exact(scenario.load_purpose, purpose, `${label}.load_purpose`);
exact(scenario.integrity_gate_passed, true, `${label}.integrity_gate_passed`);
exact(scenario.operating_target_gate_passed, targetGate, `${label}.operating_target_gate_passed`);
exact(scenario.additional_inference_passes, 0, `${label}.additional_inference_passes`);
const queues = integerRecordValue(scenario.queue_high_watermarks, `${label}.queue_high_watermarks`);
const thresholds = objectValue(scenario.thresholds, `${label}.thresholds`);
const frameEvidenceSha256 = textValue(scenario.frame_evidence_sha256, `${label}.frame_evidence_sha256`);
if (!SHA256.test(frameEvidenceSha256)) {
throw new M48SFixedClassDetectorContractError(`${label}.frame_evidence_sha256: нарушен SHA-256.`);
}
const legacyDecodeP95 = numberValue(scenario.decode_p95_ms, `${label}.decode_p95_ms`);
const legacyDecodeMaximum = numberValue(scenario.decode_maximum_ms, `${label}.decode_maximum_ms`);
return {
id,
loadPurpose: purpose,
requestedSourceRateHz: numberValue(scenario.requested_source_rate_hz, `${label}.requested_source_rate_hz`),
sourceFramesAdmitted: integerValue(scenario.source_frames_admitted, `${label}.source_frames_admitted`),
deliveredWorldStates: integerValue(scenario.delivered_world_states, `${label}.delivered_world_states`),
supersededFrames: integerValue(scenario.superseded_frames, `${label}.superseded_frames`),
deliveryRatio: numberValue(scenario.delivery_ratio, `${label}.delivery_ratio`),
effectiveWorldStateFps: numberValue(scenario.effective_world_state_fps, `${label}.effective_world_state_fps`),
worldStateCompletionAgeP95Ms: numberValue(scenario.world_state_completion_age_p95_ms, `${label}.world_state_completion_age_p95_ms`),
worldStateCompletionAgeP99Ms: numberValue(scenario.world_state_completion_age_p99_ms, `${label}.world_state_completion_age_p99_ms`),
worldStateCompletionAgeMaximumMs: numberValue(scenario.world_state_completion_age_maximum_ms, `${label}.world_state_completion_age_maximum_ms`),
hotLoopDecodeP95Ms: legacyDecodeP95,
hotLoopDecodeMaximumMs: legacyDecodeMaximum,
preadmissionDecodeMaximumMs: legacyDecodeMaximum,
sourcePrefetchPreparationMaximumMs: 0,
sourcePacingLatenessP95Ms: 0,
sourcePacingLatenessMaximumMs: 0,
detectorP95Ms: numberValue(scenario.detector_p95_ms, `${label}.detector_p95_ms`),
detectorMaximumMs: numberValue(scenario.detector_maximum_ms, `${label}.detector_maximum_ms`),
gpuUtilizationMeanPercent: numberValue(scenario.gpu_utilization_mean_percent, `${label}.gpu_utilization_mean_percent`),
gpuUtilizationMaximumPercent: numberValue(scenario.gpu_utilization_maximum_percent, `${label}.gpu_utilization_maximum_percent`),
gpuMemoryMaximumMib: numberValue(scenario.gpu_memory_maximum_mib, `${label}.gpu_memory_maximum_mib`),
processPeakRssMib: numberValue(scenario.process_peak_rss_mib, `${label}.process_peak_rss_mib`),
queueHighWatermarks: queues as M48SLoadEnvelopeScenario["queueHighWatermarks"],
queueCapacity: integerValue(scenario.queue_capacity, `${label}.queue_capacity`),
additionalInferencePasses: 0,
repeatCount: 1,
allRepetitionsPassed: targetGate,
integrityGatePassed: true,
operatingTargetGatePassed: targetGate,
thresholds: {
minimumDeliveryRatio: numberValue(thresholds.minimum_delivery_ratio, `${label}.thresholds.minimum_delivery_ratio`),
minimumEffectiveWorldStateFps: numberValue(thresholds.minimum_effective_world_state_fps, `${label}.thresholds.minimum_effective_world_state_fps`),
maximumWorldStateCompletionP95Ms: numberValue(thresholds.maximum_world_state_completion_p95_ms, `${label}.thresholds.maximum_world_state_completion_p95_ms`),
},
repetitions: [],
};
});
if (scenarios.length !== 3) {
throw new M48SFixedClassDetectorContractError("M4.8S.load_envelope.scenarios: неполный legacy-набор.");
}
return {
repeatCountPerRate: 1,
productionRateRepeatabilityPassed: false,
reserve12FpsPassed: true,
limit15FpsPassed: true,
loadEnvelopeAccepted: false,
computeCapacityAtLeastFps: 15,
bottleneckInterpretation: "rare-source-decode-or-scheduling-tail-not-steady-gpu-saturation",
scenarios,
};
}
exact(
comparison.schema_version,
"missioncore.m48s-load-envelope-comparison/v1",
"missioncore.m48s-load-envelope-comparison/v2",
"M4.8S.metrics.load_envelope.schema_version",
);
exact(comparison.production_rate_repeatability_passed, false, "M4.8S.load_envelope.production_rate_repeatability_passed");
exact(comparison.repeat_count_per_rate, 3, "M4.8S.load_envelope.repeat_count_per_rate");
exact(comparison.production_rate_repeatability_passed, true, "M4.8S.load_envelope.production_rate_repeatability_passed");
exact(comparison.reserve_12_fps_passed, true, "M4.8S.load_envelope.reserve_12_fps_passed");
exact(comparison.limit_15_fps_passed, true, "M4.8S.load_envelope.limit_15_fps_passed");
exact(comparison.load_envelope_accepted, false, "M4.8S.load_envelope.load_envelope_accepted");
exact(comparison.load_envelope_accepted, true, "M4.8S.load_envelope.load_envelope_accepted");
exact(comparison.compute_capacity_at_least_fps, 15, "M4.8S.load_envelope.compute_capacity_at_least_fps");
exact(
comparison.bottleneck_interpretation,
"rare-source-decode-or-scheduling-tail-not-steady-gpu-saturation",
"cold-video-decode-isolated-before-admission-no-steady-gpu-saturation",
"M4.8S.load_envelope.bottleneck_interpretation",
);
const ids = ["production-10fps", "reserve-12fps", "limit-15fps"] as const;
const purposes = ["production-rate", "reserve-gate", "limit-discovery"] as const;
const targetGates = [false, true, true] as const;
const scenarios = arrayValue(comparison.scenarios, "M4.8S.load_envelope.scenarios").map((value, index) => {
const label = `M4.8S.load_envelope.scenarios[${index}]`;
const scenario = objectValue(value, label);
@@ -536,8 +652,10 @@ function loadEnvelopeComparisonValue(value: unknown): M48SLoadEnvelopeComparison
}
exact(scenario.id, id, `${label}.id`);
exact(scenario.load_purpose, purpose, `${label}.load_purpose`);
exact(scenario.repeat_count, 3, `${label}.repeat_count`);
exact(scenario.all_repetitions_passed, true, `${label}.all_repetitions_passed`);
exact(scenario.integrity_gate_passed, true, `${label}.integrity_gate_passed`);
exact(scenario.operating_target_gate_passed, targetGates[index], `${label}.operating_target_gate_passed`);
exact(scenario.operating_target_gate_passed, true, `${label}.operating_target_gate_passed`);
exact(scenario.additional_inference_passes, 0, `${label}.additional_inference_passes`);
const queues = integerRecordValue(scenario.queue_high_watermarks, `${label}.queue_high_watermarks`);
for (const key of ["detector", "geometry", "temporal", "rolling", "threat"] as const) {
@@ -546,9 +664,37 @@ function loadEnvelopeComparisonValue(value: unknown): M48SLoadEnvelopeComparison
}
}
const thresholds = objectValue(scenario.thresholds, `${label}.thresholds`);
const frameEvidenceSha256 = textValue(scenario.frame_evidence_sha256, `${label}.frame_evidence_sha256`);
if (!SHA256.test(frameEvidenceSha256)) {
throw new M48SFixedClassDetectorContractError(`${label}.frame_evidence_sha256: нарушен SHA-256.`);
const repetitions = arrayValue(scenario.repetitions, `${label}.repetitions`).map((value, repetitionIndex) => {
const repetitionLabel = `${label}.repetitions[${repetitionIndex}]`;
const repetition = objectValue(value, repetitionLabel);
const repetitionNumber = repetitionIndex + 1;
exact(repetition.repetition, repetitionNumber, `${repetitionLabel}.repetition`);
exact(repetition.operating_target_gate_passed, true, `${repetitionLabel}.operating_target_gate_passed`);
const runId = textValue(repetition.run_id, `${repetitionLabel}.run_id`);
const resultSha256 = textValue(repetition.result_sha256, `${repetitionLabel}.result_sha256`);
const frameEvidenceSha256 = textValue(repetition.frame_evidence_sha256, `${repetitionLabel}.frame_evidence_sha256`);
if (!SHA256.test(resultSha256) || !SHA256.test(frameEvidenceSha256)) {
throw new M48SFixedClassDetectorContractError(`${repetitionLabel}: нарушен SHA-256.`);
}
return {
runId,
repetition: repetitionNumber as 1 | 2 | 3,
deliveredWorldStates: integerValue(repetition.delivered_world_states, `${repetitionLabel}.delivered_world_states`),
supersededFrames: integerValue(repetition.superseded_frames, `${repetitionLabel}.superseded_frames`),
deliveryRatio: numberValue(repetition.delivery_ratio, `${repetitionLabel}.delivery_ratio`),
effectiveWorldStateFps: numberValue(repetition.effective_world_state_fps, `${repetitionLabel}.effective_world_state_fps`),
worldStateCompletionAgeP95Ms: numberValue(repetition.world_state_completion_age_p95_ms, `${repetitionLabel}.world_state_completion_age_p95_ms`),
hotLoopDecodeP95Ms: numberValue(repetition.hot_loop_decode_p95_ms, `${repetitionLabel}.hot_loop_decode_p95_ms`),
hotLoopDecodeMaximumMs: numberValue(repetition.hot_loop_decode_maximum_ms, `${repetitionLabel}.hot_loop_decode_maximum_ms`),
preadmissionDecodeMaximumMs: numberValue(repetition.preadmission_decode_maximum_ms, `${repetitionLabel}.preadmission_decode_maximum_ms`),
sourcePacingLatenessMaximumMs: numberValue(repetition.source_pacing_lateness_maximum_ms, `${repetitionLabel}.source_pacing_lateness_maximum_ms`),
operatingTargetGatePassed: true as const,
resultSha256,
frameEvidenceSha256,
};
});
if (repetitions.length !== 3) {
throw new M48SFixedClassDetectorContractError(`${label}.repetitions: требуется три повтора.`);
}
return {
id,
@@ -562,8 +708,12 @@ function loadEnvelopeComparisonValue(value: unknown): M48SLoadEnvelopeComparison
worldStateCompletionAgeP95Ms: numberValue(scenario.world_state_completion_age_p95_ms, `${label}.world_state_completion_age_p95_ms`),
worldStateCompletionAgeP99Ms: numberValue(scenario.world_state_completion_age_p99_ms, `${label}.world_state_completion_age_p99_ms`),
worldStateCompletionAgeMaximumMs: numberValue(scenario.world_state_completion_age_maximum_ms, `${label}.world_state_completion_age_maximum_ms`),
decodeP95Ms: numberValue(scenario.decode_p95_ms, `${label}.decode_p95_ms`),
decodeMaximumMs: numberValue(scenario.decode_maximum_ms, `${label}.decode_maximum_ms`),
hotLoopDecodeP95Ms: numberValue(scenario.hot_loop_decode_p95_ms, `${label}.hot_loop_decode_p95_ms`),
hotLoopDecodeMaximumMs: numberValue(scenario.hot_loop_decode_maximum_ms, `${label}.hot_loop_decode_maximum_ms`),
preadmissionDecodeMaximumMs: numberValue(scenario.preadmission_decode_maximum_ms, `${label}.preadmission_decode_maximum_ms`),
sourcePrefetchPreparationMaximumMs: numberValue(scenario.source_prefetch_preparation_maximum_ms, `${label}.source_prefetch_preparation_maximum_ms`),
sourcePacingLatenessP95Ms: numberValue(scenario.source_pacing_lateness_p95_ms, `${label}.source_pacing_lateness_p95_ms`),
sourcePacingLatenessMaximumMs: numberValue(scenario.source_pacing_lateness_maximum_ms, `${label}.source_pacing_lateness_maximum_ms`),
detectorP95Ms: numberValue(scenario.detector_p95_ms, `${label}.detector_p95_ms`),
detectorMaximumMs: numberValue(scenario.detector_maximum_ms, `${label}.detector_maximum_ms`),
gpuUtilizationMeanPercent: numberValue(scenario.gpu_utilization_mean_percent, `${label}.gpu_utilization_mean_percent`),
@@ -573,25 +723,29 @@ function loadEnvelopeComparisonValue(value: unknown): M48SLoadEnvelopeComparison
queueHighWatermarks: queues as M48SLoadEnvelopeScenario["queueHighWatermarks"],
queueCapacity: integerValue(scenario.queue_capacity, `${label}.queue_capacity`),
additionalInferencePasses: 0,
integrityGatePassed: true,
operatingTargetGatePassed: targetGates[index],
repeatCount: 3 as const,
allRepetitionsPassed: true as const,
integrityGatePassed: true as const,
operatingTargetGatePassed: true as const,
thresholds: {
minimumDeliveryRatio: numberValue(thresholds.minimum_delivery_ratio, `${label}.thresholds.minimum_delivery_ratio`),
minimumEffectiveWorldStateFps: numberValue(thresholds.minimum_effective_world_state_fps, `${label}.thresholds.minimum_effective_world_state_fps`),
maximumWorldStateCompletionP95Ms: numberValue(thresholds.maximum_world_state_completion_p95_ms, `${label}.thresholds.maximum_world_state_completion_p95_ms`),
},
repetitions,
};
});
if (scenarios.length !== ids.length) {
throw new M48SFixedClassDetectorContractError("M4.8S.load_envelope.scenarios: неполный набор.");
}
return {
productionRateRepeatabilityPassed: false,
repeatCountPerRate: 3,
productionRateRepeatabilityPassed: true,
reserve12FpsPassed: true,
limit15FpsPassed: true,
loadEnvelopeAccepted: false,
loadEnvelopeAccepted: true,
computeCapacityAtLeastFps: 15,
bottleneckInterpretation: "rare-source-decode-or-scheduling-tail-not-steady-gpu-saturation",
bottleneckInterpretation: "cold-video-decode-isolated-before-admission-no-steady-gpu-saturation",
scenarios,
};
}
@@ -647,10 +801,10 @@ function parseResult(value: unknown, resultId: string): M48SFixedClassDetectorRe
exact(decision.production_accepted, false, "M4.8S.decision.production_accepted");
if (loadEnvelope !== null) {
exact(decision.load_envelope_evaluated, true, "M4.8S.decision.load_envelope_evaluated");
exact(decision.production_rate_repeatability_passed, false, "M4.8S.decision.production_rate_repeatability_passed");
exact(decision.reserve_12_fps_passed, true, "M4.8S.decision.reserve_12_fps_passed");
exact(decision.limit_15_fps_passed, true, "M4.8S.decision.limit_15_fps_passed");
exact(decision.load_envelope_accepted, false, "M4.8S.decision.load_envelope_accepted");
exact(decision.production_rate_repeatability_passed, loadEnvelope.productionRateRepeatabilityPassed, "M4.8S.decision.production_rate_repeatability_passed");
exact(decision.reserve_12_fps_passed, loadEnvelope.reserve12FpsPassed, "M4.8S.decision.reserve_12_fps_passed");
exact(decision.limit_15_fps_passed, loadEnvelope.limit15FpsPassed, "M4.8S.decision.limit_15_fps_passed");
exact(decision.load_envelope_accepted, loadEnvelope.loadEnvelopeAccepted, "M4.8S.decision.load_envelope_accepted");
}
const frames = arrayValue(payload.frames, "M4.8S.frames").map(descriptorValue);
const evidenceFrameCount = integerValue(source.evidence_frame_count, "M4.8S.source.evidence_frame_count");
@@ -709,10 +863,10 @@ function parseResult(value: unknown, resultId: string): M48SFixedClassDetectorRe
integratedWorldStateGatePassed: integratedGate,
detectorReplacementAuthorized: false,
loadEnvelopeEvaluated: loadEnvelope !== null,
productionRateRepeatabilityPassed: false,
productionRateRepeatabilityPassed: loadEnvelope?.productionRateRepeatabilityPassed ?? false,
reserve12FpsPassed: loadEnvelope?.reserve12FpsPassed ?? false,
limit15FpsPassed: loadEnvelope?.limit15FpsPassed ?? false,
loadEnvelopeAccepted: false,
loadEnvelopeAccepted: loadEnvelope?.loadEnvelopeAccepted ?? false,
productionAccepted: false,
},
limitations: arrayValue(payload.limitations, "M4.8S.limitations").map((item, index) => textValue(item, `M4.8S.limitations[${index}]`)),
@@ -29,8 +29,11 @@ export function M48SFixedClassDetectorResultView({
const load = loadEnvelope && production && reserve && limit
? { comparison: loadEnvelope, production, reserve, limit }
: null;
const loadAccepted = load?.comparison.loadEnvelopeAccepted === true;
const status = load
? "Capacity ≥ 15 FPS подтверждён; repeatability 10 FPS требует закрытия"
? loadAccepted
? "3 × 10 / 12 / 15 FPS прошли; realtime envelope ≥ 15 FPS принят"
: "Capacity ≥ 15 FPS подтверждён; repeatability 10 FPS требует закрытия"
: hardening
? `После hardening: ${hardening.hardened.deliveredWorldStates.toLocaleString("ru-RU")} из ${hardening.hardened.sourceFramesAdmitted.toLocaleString("ru-RU")} world states доставлены`
: integrated
@@ -41,9 +44,11 @@ export function M48SFixedClassDetectorResultView({
summary={(
<LaboratorySummary
title="M4.8S · fixed-class semantics риск-объектов"
description="RF-DETR-L встроен в полный source-paced граф RF-DETR → geometry → temporal → motion → rolling map → threat. После hardening один и тот же immutable проход отдельно измерен на 10, 12 и 15 FPS: показаны не только средние значения, но delivery, хвосты задержки, GPU/VRAM/RAM и честный незакрытый gate."
description={loadAccepted
? "RF-DETR-L встроен в полный source-paced граф RF-DETR → geometry → temporal → motion → rolling map → threat. Холодный video decode вынесен до допуска источника, после чего один immutable проход выполнен по три раза на 10, 12 и 15 FPS. LAB показывает худший результат каждой серии, хвосты decode/pacing и каждый из девяти sealed-прогонов."
: "RF-DETR-L встроен в полный source-paced граф RF-DETR → geometry → temporal → motion → rolling map → threat. Исторический immutable проход отдельно измерен на 10, 12 и 15 FPS; незакрытый 10 FPS delivery gate сохранён без постфактум-сдвига thresholds."}
status={status}
statusTone={load ? "warning" : "success"}
statusTone={load && !loadAccepted ? "warning" : "success"}
facts={[
{ label: "Источник", value: `${rigLabel} RIGHT · raw KB4 · ${result.source.evidenceFrameCount} diagnostic frames` },
{ label: "Сравнение", value: "YOLOX-S · D-FINE-S · RF-DETR-L · единый threshold 0.50" },
@@ -54,18 +59,24 @@ export function M48SFixedClassDetectorResultView({
question: load
? "Какой realtime-запас имеет неизменный single-pass RF-DETR graph на Worker 006 и где начинается его вычислительный предел?"
: "Можно ли заменить слабую class-семантику YOLOX готовой моделью, не потеряв realtime на предельном Worker с RTX 4090?",
approach: load
approach: loadAccepted
? "Один и тот же проход из 4489 кадров прогнали строго последовательно девять раз: по три повтора на 10, 12 и 15 FPS. Bounded prefetch на 64 кадра завершался до source admission; sensor timestamps, модель, providers, очереди и single inference не менялись. Пороги и порядок были записаны заранее."
: load
? "Один и тот же проход из 4489 кадров прогнали последовательно на 10, 12 и 15 FPS. Sensor timestamps, модель, graph providers, очереди, prewarm и single inference не менялись; менялся только wall-clock pacing. Пороги delivery/FPS/p95 были записаны до запусков."
: `YOLOX-S, D-FINE-S и RF-DETR-L сравнили на одинаковых ${result.source.evidenceFrameCount} raw-KB4 кадрах с порогом 0.50. RF-DETR-L отдельно квалифицировали ${decimal(result.metrics.detectorLoad.durationSeconds / 60, 0)} минут, затем встроили в полный reference graph без дополнительного inference-прохода.`,
principalResult: load
? `12 FPS прошли reserve-gate: ${load.reserve.deliveredWorldStates.toLocaleString("ru-RU")}/${load.reserve.sourceFramesAdmitted.toLocaleString("ru-RU")} доставлено. 15 FPS также прошли: ${load.limit.deliveredWorldStates.toLocaleString("ru-RU")}/${load.limit.sourceFramesAdmitted.toLocaleString("ru-RU")}. Но 10 FPS не добрали заранее заданный delivery ratio: ${load.production.deliveredWorldStates.toLocaleString("ru-RU")}/${load.production.sourceFramesAdmitted.toLocaleString("ru-RU")}, на два кадра ниже порога.`
principalResult: loadAccepted && load
? `Все девять прогонов прошли integrity и predeclared target gates. Худший результат: 10 FPS — ${load.production.deliveredWorldStates.toLocaleString("ru-RU")}/${load.production.sourceFramesAdmitted.toLocaleString("ru-RU")}, 12 FPS ${load.reserve.deliveredWorldStates.toLocaleString("ru-RU")}/${load.reserve.sourceFramesAdmitted.toLocaleString("ru-RU")}, 15 FPS ${load.limit.deliveredWorldStates.toLocaleString("ru-RU")}/${load.limit.sourceFramesAdmitted.toLocaleString("ru-RU")}. Во всех сериях сохранён один inference на кадр.`
: load
? `12 FPS прошли reserve-gate: ${load.reserve.deliveredWorldStates.toLocaleString("ru-RU")}/${load.reserve.sourceFramesAdmitted.toLocaleString("ru-RU")} доставлено. 15 FPS также прошли: ${load.limit.deliveredWorldStates.toLocaleString("ru-RU")}/${load.limit.sourceFramesAdmitted.toLocaleString("ru-RU")}. Но 10 FPS не добрали заранее заданный delivery ratio: ${load.production.deliveredWorldStates.toLocaleString("ru-RU")}/${load.production.sourceFramesAdmitted.toLocaleString("ru-RU")}.`
: hardening
? `На одинаковых ${hardening.baseline.sourceFramesAdmitted.toLocaleString("ru-RU")} входных кадрах полный граф увеличил доставку с ${hardening.baseline.deliveredWorldStates.toLocaleString("ru-RU")} до ${hardening.hardened.deliveredWorldStates.toLocaleString("ru-RU")} world states, а число вытесненных кадров снизил с ${hardening.baseline.supersededFrames} до ${hardening.hardened.supersededFrames}. Отдельный ${hardening.startup.validationFrames.toLocaleString("ru-RU")}-кадровый прогон подтвердил prewarm до допуска источника.`
: integrated
? `Полный граф доставил ${integrated.deliveredWorldStates.toLocaleString("ru-RU")} world states при ${decimal(integrated.effectiveWorldStateFps, 3)} FPS и p95 ${decimal(integrated.worldStateCompletionAgeP95Ms, 3)} ms; ${integrated.supersededFrames} входных кадров штатно вытеснены latest-wins очередью.`
: `RF-DETR-L выбран из трёх кандидатов и обработал ${detectorLoad.sourceFramesConsumed.toLocaleString("ru-RU")} кадров detector-only без замен и ошибок.`,
limitation: load
? "Capacity полного графа доказан как минимум до 15 FPS, но production repeatability не принята: delivery на 10 FPS немонотонно хуже 12/15 из-за редкого decode/scheduling tail. Истинность классов, collision safety и physical-live не проверялись; команды отключены."
limitation: loadAccepted
? "Runtime repeatability и capacity полного графа закрыты как минимум до 15 FPS. Это не доказывает истинность классов, track/risk truth, collision safety или physical-live поведение; команды и production authority по-прежнему отключены."
: load
? "Capacity полного графа доказан как минимум до 15 FPS, но исторический production repeatability gate не принят. Истинность классов, collision safety и physical-live не проверялись; команды отключены."
: "Прогон доказывает runtime envelope, а не истинность классов, качество track identity, корректность risk policy или безопасность движения. Production authority и команды отключены.",
}}
method={{
@@ -103,13 +114,16 @@ export function M48SFixedClassDetectorResultView({
? "Что дал прогон: полный world-state graph проходит realtime envelope"
: "Что дал прогон: RF-DETR-L проходит detector-only realtime envelope"}
status={status}
statusTone={load ? "warning" : "success"}
statusTone={load && !loadAccepted ? "warning" : "success"}
metrics={load ? [
{ label: "Effective world-state FPS", value: `${decimal(load.production.effectiveWorldStateFps, 3)} / ${decimal(load.reserve.effectiveWorldStateFps, 3)} / ${decimal(load.limit.effectiveWorldStateFps, 3)}`, hint: "вход 10 / 12 / 15 FPS" },
{ label: "Delivered / superseded", value: `${load.production.deliveredWorldStates.toLocaleString("ru-RU")}/${load.production.supersededFrames} · ${load.reserve.deliveredWorldStates.toLocaleString("ru-RU")}/${load.reserve.supersededFrames} · ${load.limit.deliveredWorldStates.toLocaleString("ru-RU")}/${load.limit.supersededFrames}`, hint: "10 FPS gate не прошёл · 12 и 15 прошли" },
{ label: "Worst delivered / superseded", value: `${load.production.deliveredWorldStates.toLocaleString("ru-RU")}/${load.production.supersededFrames} · ${load.reserve.deliveredWorldStates.toLocaleString("ru-RU")}/${load.reserve.supersededFrames} · ${load.limit.deliveredWorldStates.toLocaleString("ru-RU")}/${load.limit.supersededFrames}`, hint: "минимальная доставка / максимум вытеснений из трёх повторов" },
{ label: "World-state p95", value: `${decimal(load.production.worldStateCompletionAgeP95Ms, 3)} / ${decimal(load.reserve.worldStateCompletionAgeP95Ms, 3)} / ${decimal(load.limit.worldStateCompletionAgeP95Ms, 3)} ms`, hint: "10 / 12 / 15 FPS" },
{ label: "World-state p99", value: `${decimal(load.production.worldStateCompletionAgeP99Ms, 3)} / ${decimal(load.reserve.worldStateCompletionAgeP99Ms, 3)} / ${decimal(load.limit.worldStateCompletionAgeP99Ms, 3)} ms`, hint: "хвост не растёт вместе с rate" },
{ label: "Decode maximum", value: `${decimal(load.production.decodeMaximumMs, 0)} / ${decimal(load.reserve.decodeMaximumMs, 0)} / ${decimal(load.limit.decodeMaximumMs, 0)} ms`, hint: "редкий source/decode tail · не steady compute" },
{ label: loadAccepted ? "Hot-loop decode p95" : "Decode p95", value: `${decimal(load.production.hotLoopDecodeP95Ms, 3)} / ${decimal(load.reserve.hotLoopDecodeP95Ms, 3)} / ${decimal(load.limit.hotLoopDecodeP95Ms, 3)} ms`, hint: loadAccepted ? "холодный open/decode исключён из realtime" : "исторический decode включает cold tail" },
loadAccepted
? { label: "Prefetch / pacing max", value: `${decimal(Math.max(...load.comparison.scenarios.map((scenario) => scenario.sourcePrefetchPreparationMaximumMs)) / 1000, 2)} s / ${decimal(Math.max(...load.comparison.scenarios.map((scenario) => scenario.sourcePacingLatenessMaximumMs)), 3)} ms`, hint: "prefetch до admission / wall-clock pacing в hot loop" }
: { label: "Decode maximum", value: `${decimal(load.production.hotLoopDecodeMaximumMs, 0)} / ${decimal(load.reserve.hotLoopDecodeMaximumMs, 0)} / ${decimal(load.limit.hotLoopDecodeMaximumMs, 0)} ms`, hint: "редкий cold source/decode tail" },
{ label: "Detector p95", value: `${decimal(load.production.detectorP95Ms, 3)} / ${decimal(load.reserve.detectorP95Ms, 3)} / ${decimal(load.limit.detectorP95Ms, 3)} ms`, hint: "тот же RF-DETR · один inference" },
{ label: "GPU mean", value: `${decimal(load.production.gpuUtilizationMeanPercent)}% / ${decimal(load.reserve.gpuUtilizationMeanPercent)}% / ${decimal(load.limit.gpuUtilizationMeanPercent)}%`, hint: "10 / 12 / 15 FPS · насыщения нет" },
{ label: "VRAM / process RAM peak", value: `${decimal(Math.max(...load.comparison.scenarios.map((scenario) => scenario.gpuMemoryMaximumMib)) / 1024, 2)} / ${decimal(Math.max(...load.comparison.scenarios.map((scenario) => scenario.processPeakRssMib)) / 1024, 2)} GiB`, hint: "общий GPU counter / graph process RSS" },
@@ -135,17 +149,21 @@ export function M48SFixedClassDetectorResultView({
]}
conclusion={{
proved: load
? `Полный single-pass graph сохранил bounded queues 2/2, нулевые failed/stale/rejected/unavailable и нулевые дополнительные inference-проходы во всех трёх режимах. Reserve 12 FPS прошёл с delivery ${(load.reserve.deliveryRatio * 100).toLocaleString("ru-RU", { maximumFractionDigits: 3 })}% и p95 ${decimal(load.reserve.worldStateCompletionAgeP95Ms, 3)} ms; 15 FPS также прошли с delivery ${(load.limit.deliveryRatio * 100).toLocaleString("ru-RU", { maximumFractionDigits: 3 })}%. Вычислительная capacity доказана как минимум до 15 FPS без более мощного Worker.`
? `Все ${load.comparison.repeatCountPerRate * load.comparison.scenarios.length} полных single-pass прогона сохранили bounded queues 2/2, нулевые failed/stale/rejected/unavailable и нулевые дополнительные inference-проходы. Худший 10 FPS delivery ${(load.production.deliveryRatio * 100).toLocaleString("ru-RU", { maximumFractionDigits: 3 })}%, 12 FPS — ${(load.reserve.deliveryRatio * 100).toLocaleString("ru-RU", { maximumFractionDigits: 3 })}%, 15 FPS — ${(load.limit.deliveryRatio * 100).toLocaleString("ru-RU", { maximumFractionDigits: 3 })}%. Realtime capacity доказана как минимум до 15 FPS без более мощного Worker.`
: hardening
? `На полном сравнительном прогоне с ${hardening.hardened.sourceFramesAdmitted.toLocaleString("ru-RU")} одинаковыми входными кадрами hardening сохранил realtime FPS, доставил на ${(hardening.hardened.deliveredWorldStates - hardening.baseline.deliveredWorldStates).toLocaleString("ru-RU")} world states больше и сократил вытеснения ${hardening.baseline.supersededFrames}${hardening.hardened.supersededFrames}. Максимальный стоп rolling stage уменьшился ${decimal(hardening.baseline.rollingMaximumMs, 3)}${decimal(hardening.hardened.rollingMaximumMs, 3)} ms. Отдельный prewarm-прогон снизил первый detector frame ${decimal(hardening.startup.baseline.detectorMs, 3)}${decimal(hardening.startup.prewarmed.detectorMs, 3)} ms и первый world state ${decimal(hardening.startup.baseline.worldStateMs, 3)}${decimal(hardening.startup.prewarmed.worldStateMs, 3)} ms без дополнительного inference на кадрах.`
: integrated
? `На Worker 006 полный граф обработал ${integrated.sourceFramesAdmitted.toLocaleString("ru-RU")} входных кадров, доставил ${integrated.deliveredWorldStates.toLocaleString("ru-RU")} состояний без ошибок, удержал все очереди в пределах ${integrated.queueCapacity} и p95 ${decimal(integrated.worldStateCompletionAgeP95Ms, 3)} ms. Advisory сформировал публикации по семействам: geometry-only (${integrated.advisoryFamilyCounts["generic-obstacle"].toLocaleString("ru-RU")}), люди (${integrated.advisoryFamilyCounts.person.toLocaleString("ru-RU")}), животные (${integrated.advisoryFamilyCounts.animal.toLocaleString("ru-RU")}) и транспорт (${integrated.advisoryFamilyCounts.vehicle.toLocaleString("ru-RU")}); это не количество уникальных физических объектов и не потребовало второго inference.`
: `RF-DETR-L ${decimal(detectorLoad.durationSeconds / 60, 0)} минут устойчиво потреблял source-paced поток около 10 FPS: ${detectorLoad.sourceFramesConsumed.toLocaleString("ru-RU")} кадров, 0 замен, 0 ошибок, completion-age p95 ${decimal(detectorLoad.completionAgeP95Ms, 3)} ms.`,
notProved: load
? `Не закрыта repeatability delivery на production-rate: 10 FPS дали ${(load.production.deliveryRatio * 100).toLocaleString("ru-RU", { maximumFractionDigits: 3 })}% при gate ${(load.production.thresholds.minimumDeliveryRatio * 100).toLocaleString("ru-RU", { maximumFractionDigits: 1 })}%. Немонотонность 10 → 12 → 15 и decode maxima 3,23,6 s не позволяют объявить production envelope принятым.`
notProved: loadAccepted
? "Не доказаны unbiased precision/recall классов, независимая истинность track identity и risk policy, работа planner, collision safety или physical-live режим. Принятый runtime envelope не включает production/navigation authority."
: load
? `Не закрыта repeatability delivery на production-rate: 10 FPS дали ${(load.production.deliveryRatio * 100).toLocaleString("ru-RU", { maximumFractionDigits: 3 })}% при gate ${(load.production.thresholds.minimumDeliveryRatio * 100).toLocaleString("ru-RU", { maximumFractionDigits: 1 })}%. Исторический v1 результат сохранён; он не переинтерпретируется после появления v2.`
: "Не доказаны unbiased precision/recall классов, независимое качество track identity и risk policy, поведение planner или collision safety. Кадровые рамки не заменяют геометрическую occupancy-карту.",
decision: load
? "Не усиливать GPU и не добавлять второй детектор. Сначала изолировать/предзагружать video decode и измерить scheduler tail, затем повторить тот же sealed 10/12/15 FPS набор серией прогонов. До закрытия repeatability production switch не разрешён."
decision: loadAccepted
? "Сохранить bounded 64-frame prefetch до source admission как runtime baseline. Не усиливать GPU и не добавлять второй детектор: Worker 006 уже держит как минимум 15 FPS. Следующий этап — semantic/track/risk truth и physical-live shadow; production switch не разрешён."
: load
? "Историческое решение v1: не усиливать GPU и не добавлять второй детектор; изолировать cold video decode и повторить sealed 10/12/15 FPS серией прогонов. Результат v2 закрывает этот следующий этап отдельно, не переписывая v1."
: hardening
? "Сохранить разгрузку cyclic GC и обязательный detector prewarm как текущий runtime baseline. Следующий этап — измерять запас realtime при росте сцены и числа семантических объектов, не добавляя второй детектор и не расширяя inference-нагрузку. Production switch не разрешён."
: "Сохранить RF-DETR-L как risk-semantic shadow provider полного reference graph. Не классифицировать миллионы статических форм: неизвестное неподвижное препятствие остаётся geometry-owned и объезжается; классы сохраняются для людей, животных и транспорта. Production switch не разрешён.",