@camstack/addon-pipeline 1.2.218 → 1.2.220
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/audio-analyzer/index.js +49 -5
- package/dist/audio-analyzer/index.mjs +46 -3
- package/dist/chunk-emK7D4bc.js +35 -0
- package/dist/{default-detection-model-AJyhoTLF.mjs → default-detection-model-DBNEc3iw.mjs} +1 -1
- package/dist/{default-detection-model-Bf45EQ98.js → default-detection-model-x6oNMBDH.js} +1 -1
- package/dist/detection-pipeline/index.js +10 -9
- package/dist/detection-pipeline/index.mjs +4 -4
- package/dist/{dist-BbvtiBNc.js → dist-ByPsWlTa.js} +57 -38
- package/dist/{dist-Dl6GntEh.mjs → dist-ClihWGOZ.mjs} +57 -3
- package/dist/{lazy-sharp-L9Lcr62v.js → lazy-sharp-BuwKlQLR.js} +2 -2
- package/dist/motion-wasm/index.js +2 -2
- package/dist/motion-wasm/index.mjs +1 -1
- package/dist/{node-CbCVHEvJ.js → node-CNPnaux4.js} +4 -3
- package/dist/{node-CEyw52D2.mjs → node-DiaTmz84.mjs} +1 -1
- package/dist/pipeline-runner/index.js +222 -157
- package/dist/pipeline-runner/index.mjs +218 -154
- package/dist/{process-memory-DBxdiCSF.js → process-memory-9KqRtUHt.js} +3 -2
- package/dist/{process-memory-Du00R6-e.mjs → process-memory-D4t8hpJd.mjs} +1 -1
- package/dist/recorder/index.js +334 -123
- package/dist/recorder/index.mjs +332 -122
- package/dist/{segment-demux-js-B278aBtB.mjs → segment-demux-js-CFFXVae4.mjs} +1 -1
- package/dist/{segment-demux-js-D7bjzY8M.js → segment-demux-js-CZefXDLx.js} +4 -3
- package/dist/session-decode/decode-worker-child.js +155 -74
- package/dist/session-decode/decode-worker-child.mjs +154 -73
- package/dist/stream-broker/_stub.js +1 -1
- package/dist/stream-broker/{_virtual_mf-localSharedImportMap___mfe_internal__addon_stream_broker_widgets-BnmbfnAd.mjs → _virtual_mf-localSharedImportMap___mfe_internal__addon_stream_broker_widgets-CtdpN7Sz.mjs} +3 -3
- package/dist/stream-broker/{_virtual_mf___mfe_internal__addon_stream_broker_widgets__loadShare___mf_0_camstack_mf_1_types__loadShare__.js-yJ2CyixO.mjs → _virtual_mf___mfe_internal__addon_stream_broker_widgets__loadShare___mf_0_camstack_mf_1_types__loadShare__.js-7hqrrd88.mjs} +1 -1
- package/dist/stream-broker/demux-worker-child.js +1 -1
- package/dist/stream-broker/demux-worker-child.mjs +1 -1
- package/dist/stream-broker/{hostInit-MIKQqs86.mjs → hostInit-McoUiljf.mjs} +3 -3
- package/dist/stream-broker/index.js +24 -25
- package/dist/stream-broker/index.mjs +17 -19
- package/dist/stream-broker/remoteEntry.js +1 -1
- package/dist/worker-protocol-B2MfQLlu.js +184 -0
- package/dist/worker-protocol-C_W-P_g-.mjs +161 -0
- package/package.json +1 -1
- package/dist/worker-protocol-BEbD5adq.mjs +0 -264
- package/dist/worker-protocol-C4rh5uiS.js +0 -299
|
@@ -2,12 +2,13 @@ Object.defineProperties(exports, {
|
|
|
2
2
|
__esModule: { value: true },
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
|
-
const
|
|
6
|
-
const
|
|
5
|
+
const require_chunk = require("../chunk-emK7D4bc.js");
|
|
6
|
+
const require_dist = require("../dist-ByPsWlTa.js");
|
|
7
|
+
const require_process_memory = require("../process-memory-9KqRtUHt.js");
|
|
7
8
|
let node_fs = require("node:fs");
|
|
8
|
-
node_fs =
|
|
9
|
+
node_fs = require_chunk.__toESM(node_fs);
|
|
9
10
|
let node_path = require("node:path");
|
|
10
|
-
node_path =
|
|
11
|
+
node_path = require_chunk.__toESM(node_path);
|
|
11
12
|
let _camstack_system_addon_utils = require("@camstack/system/addon-utils");
|
|
12
13
|
//#region src/audio-analyzer/audio-pipeline.ts
|
|
13
14
|
/**
|
|
@@ -369,7 +370,12 @@ var AppleSoundAnalysisPipeline = class {
|
|
|
369
370
|
}
|
|
370
371
|
}
|
|
371
372
|
};
|
|
372
|
-
/**
|
|
373
|
+
/**
|
|
374
|
+
* Resample to 16 kHz mono by linear interpolation — the ONE place a window
|
|
375
|
+
* is brought to the classifier's rate. The plane carries the source rate
|
|
376
|
+
* (8 kHz for G.711, D450); the model that needs 16 kHz gets it here, next to
|
|
377
|
+
* the model, over a whole window. Exported so the guard can pin it.
|
|
378
|
+
*/
|
|
373
379
|
function resampleMono16k(chunk) {
|
|
374
380
|
const { data, sampleRate, channels } = chunk;
|
|
375
381
|
const numSamples = data.length / channels;
|
|
@@ -404,6 +410,9 @@ var CLASSIFY_ERROR_SUPPRESS_MS = 3e4;
|
|
|
404
410
|
var CLASSIFY_MIN_INTERVAL_MS = 500;
|
|
405
411
|
var PIPELINE_IDLE_DISPOSE_MS = 5 * 6e4;
|
|
406
412
|
var GLOBAL_DEVICE_KEY = -1;
|
|
413
|
+
/** What the classifier consumes natively; anything else is resampled next to it. */
|
|
414
|
+
var CLASSIFIER_SAMPLE_RATE = 16e3;
|
|
415
|
+
var CLASSIFIER_CHANNELS = 1;
|
|
407
416
|
/**
|
|
408
417
|
* Reconstruct a Float32 view over f32le PCM bytes carried in a Uint8Array.
|
|
409
418
|
*
|
|
@@ -435,6 +444,8 @@ var AudioAnalyzerProvider = class {
|
|
|
435
444
|
debugClassifySamples = false;
|
|
436
445
|
/** Per-camera in-flight state. Key = deviceId (or GLOBAL_DEVICE_KEY for legacy callers). */
|
|
437
446
|
cameraState = /* @__PURE__ */ new Map();
|
|
447
|
+
/** Last window format seen per camera — the first and every change is logged (D450). */
|
|
448
|
+
windowFormats = /* @__PURE__ */ new Map();
|
|
438
449
|
/** Global pipeline lock — Apple SA and ONNX are single-channel: only one classify() can
|
|
439
450
|
* run at a time. Without this, concurrent calls from different cameras overwrite the
|
|
440
451
|
* single pendingResolve slot in AppleSoundAnalysisPipeline, causing 30s timeouts. */
|
|
@@ -600,6 +611,7 @@ var AudioAnalyzerProvider = class {
|
|
|
600
611
|
}
|
|
601
612
|
async analyseChunk({ chunk, settings }) {
|
|
602
613
|
const samples = float32FromBytes(chunk.data);
|
|
614
|
+
this.reportWindowFormat(chunk, samples.length);
|
|
603
615
|
let sumSquares = 0;
|
|
604
616
|
for (let i = 0; i < samples.length; i++) sumSquares += samples[i] * samples[i];
|
|
605
617
|
const rms = Math.sqrt(sumSquares / samples.length);
|
|
@@ -668,6 +680,38 @@ var AudioAnalyzerProvider = class {
|
|
|
668
680
|
timestamp: chunk.timestamp
|
|
669
681
|
};
|
|
670
682
|
}
|
|
683
|
+
/**
|
|
684
|
+
* Say what this camera's windows arrive as — once, and again on every
|
|
685
|
+
* change. The plane carries the source rate (8 kHz for G.711 since D450,
|
|
686
|
+
* 16 kHz for AAC through the codec session), and the classifier resamples
|
|
687
|
+
* anything that is not 16 kHz mono next to the model. A camera whose
|
|
688
|
+
* format flips mid-subscription (a broker redeploy) is visible here, and
|
|
689
|
+
* a consumer that stopped receiving what it expected is never silent
|
|
690
|
+
* (D427).
|
|
691
|
+
*/
|
|
692
|
+
reportWindowFormat(chunk, sampleCount) {
|
|
693
|
+
const key = chunk.deviceId ?? GLOBAL_DEVICE_KEY;
|
|
694
|
+
const format = {
|
|
695
|
+
sampleRate: chunk.sampleRate,
|
|
696
|
+
channels: chunk.channels
|
|
697
|
+
};
|
|
698
|
+
const previous = this.windowFormats.get(key) ?? null;
|
|
699
|
+
if (previous !== null && previous.sampleRate === format.sampleRate && previous.channels === format.channels) return;
|
|
700
|
+
this.windowFormats.set(key, format);
|
|
701
|
+
const channels = chunk.channels > 0 ? chunk.channels : 1;
|
|
702
|
+
const windowMs = chunk.sampleRate > 0 ? Math.round(sampleCount / channels / chunk.sampleRate * 1e3) : null;
|
|
703
|
+
this.log.info("audio window format", {
|
|
704
|
+
tags: chunk.deviceId !== void 0 ? { deviceId: chunk.deviceId } : void 0,
|
|
705
|
+
meta: {
|
|
706
|
+
sampleRate: chunk.sampleRate,
|
|
707
|
+
channels: chunk.channels,
|
|
708
|
+
bytes: chunk.data.byteLength,
|
|
709
|
+
windowMs,
|
|
710
|
+
classifierResamples: chunk.sampleRate !== CLASSIFIER_SAMPLE_RATE || chunk.channels !== CLASSIFIER_CHANNELS,
|
|
711
|
+
previous
|
|
712
|
+
}
|
|
713
|
+
});
|
|
714
|
+
}
|
|
671
715
|
async classify(chunk) {
|
|
672
716
|
const camKey = chunk.deviceId ?? GLOBAL_DEVICE_KEY;
|
|
673
717
|
const now = Date.now();
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { n as __require } from "../chunk-DnnnRqeS.mjs";
|
|
2
|
-
import { Dt as resolvePoolMemoryPolicy, It as errMsg, Jt as hydrateSchema, M as audioAnalyzerCapability, S as PoolMemoryWatchdog, Ut as BaseAddon, j as audioAnalysisCapability, n as AUDIO_BACKEND_CHOICES, ot as mapAudioLabelToMacro, s as DEFAULT_AUDIO_ANALYZER_CONFIG, v as HF_BASE_URL } from "../dist-
|
|
3
|
-
import { n as pickNodePlatformArch, t as readProcessMemory } from "../process-memory-
|
|
2
|
+
import { Dt as resolvePoolMemoryPolicy, It as errMsg, Jt as hydrateSchema, M as audioAnalyzerCapability, S as PoolMemoryWatchdog, Ut as BaseAddon, j as audioAnalysisCapability, n as AUDIO_BACKEND_CHOICES, ot as mapAudioLabelToMacro, s as DEFAULT_AUDIO_ANALYZER_CONFIG, v as HF_BASE_URL } from "../dist-ClihWGOZ.mjs";
|
|
3
|
+
import { n as pickNodePlatformArch, t as readProcessMemory } from "../process-memory-D4t8hpJd.mjs";
|
|
4
4
|
import * as fs from "node:fs";
|
|
5
5
|
import * as path$1 from "node:path";
|
|
6
6
|
import { downloadFile } from "@camstack/system/addon-utils";
|
|
@@ -364,7 +364,12 @@ var AppleSoundAnalysisPipeline = class {
|
|
|
364
364
|
}
|
|
365
365
|
}
|
|
366
366
|
};
|
|
367
|
-
/**
|
|
367
|
+
/**
|
|
368
|
+
* Resample to 16 kHz mono by linear interpolation — the ONE place a window
|
|
369
|
+
* is brought to the classifier's rate. The plane carries the source rate
|
|
370
|
+
* (8 kHz for G.711, D450); the model that needs 16 kHz gets it here, next to
|
|
371
|
+
* the model, over a whole window. Exported so the guard can pin it.
|
|
372
|
+
*/
|
|
368
373
|
function resampleMono16k(chunk) {
|
|
369
374
|
const { data, sampleRate, channels } = chunk;
|
|
370
375
|
const numSamples = data.length / channels;
|
|
@@ -399,6 +404,9 @@ var CLASSIFY_ERROR_SUPPRESS_MS = 3e4;
|
|
|
399
404
|
var CLASSIFY_MIN_INTERVAL_MS = 500;
|
|
400
405
|
var PIPELINE_IDLE_DISPOSE_MS = 5 * 6e4;
|
|
401
406
|
var GLOBAL_DEVICE_KEY = -1;
|
|
407
|
+
/** What the classifier consumes natively; anything else is resampled next to it. */
|
|
408
|
+
var CLASSIFIER_SAMPLE_RATE = 16e3;
|
|
409
|
+
var CLASSIFIER_CHANNELS = 1;
|
|
402
410
|
/**
|
|
403
411
|
* Reconstruct a Float32 view over f32le PCM bytes carried in a Uint8Array.
|
|
404
412
|
*
|
|
@@ -430,6 +438,8 @@ var AudioAnalyzerProvider = class {
|
|
|
430
438
|
debugClassifySamples = false;
|
|
431
439
|
/** Per-camera in-flight state. Key = deviceId (or GLOBAL_DEVICE_KEY for legacy callers). */
|
|
432
440
|
cameraState = /* @__PURE__ */ new Map();
|
|
441
|
+
/** Last window format seen per camera — the first and every change is logged (D450). */
|
|
442
|
+
windowFormats = /* @__PURE__ */ new Map();
|
|
433
443
|
/** Global pipeline lock — Apple SA and ONNX are single-channel: only one classify() can
|
|
434
444
|
* run at a time. Without this, concurrent calls from different cameras overwrite the
|
|
435
445
|
* single pendingResolve slot in AppleSoundAnalysisPipeline, causing 30s timeouts. */
|
|
@@ -595,6 +605,7 @@ var AudioAnalyzerProvider = class {
|
|
|
595
605
|
}
|
|
596
606
|
async analyseChunk({ chunk, settings }) {
|
|
597
607
|
const samples = float32FromBytes(chunk.data);
|
|
608
|
+
this.reportWindowFormat(chunk, samples.length);
|
|
598
609
|
let sumSquares = 0;
|
|
599
610
|
for (let i = 0; i < samples.length; i++) sumSquares += samples[i] * samples[i];
|
|
600
611
|
const rms = Math.sqrt(sumSquares / samples.length);
|
|
@@ -663,6 +674,38 @@ var AudioAnalyzerProvider = class {
|
|
|
663
674
|
timestamp: chunk.timestamp
|
|
664
675
|
};
|
|
665
676
|
}
|
|
677
|
+
/**
|
|
678
|
+
* Say what this camera's windows arrive as — once, and again on every
|
|
679
|
+
* change. The plane carries the source rate (8 kHz for G.711 since D450,
|
|
680
|
+
* 16 kHz for AAC through the codec session), and the classifier resamples
|
|
681
|
+
* anything that is not 16 kHz mono next to the model. A camera whose
|
|
682
|
+
* format flips mid-subscription (a broker redeploy) is visible here, and
|
|
683
|
+
* a consumer that stopped receiving what it expected is never silent
|
|
684
|
+
* (D427).
|
|
685
|
+
*/
|
|
686
|
+
reportWindowFormat(chunk, sampleCount) {
|
|
687
|
+
const key = chunk.deviceId ?? GLOBAL_DEVICE_KEY;
|
|
688
|
+
const format = {
|
|
689
|
+
sampleRate: chunk.sampleRate,
|
|
690
|
+
channels: chunk.channels
|
|
691
|
+
};
|
|
692
|
+
const previous = this.windowFormats.get(key) ?? null;
|
|
693
|
+
if (previous !== null && previous.sampleRate === format.sampleRate && previous.channels === format.channels) return;
|
|
694
|
+
this.windowFormats.set(key, format);
|
|
695
|
+
const channels = chunk.channels > 0 ? chunk.channels : 1;
|
|
696
|
+
const windowMs = chunk.sampleRate > 0 ? Math.round(sampleCount / channels / chunk.sampleRate * 1e3) : null;
|
|
697
|
+
this.log.info("audio window format", {
|
|
698
|
+
tags: chunk.deviceId !== void 0 ? { deviceId: chunk.deviceId } : void 0,
|
|
699
|
+
meta: {
|
|
700
|
+
sampleRate: chunk.sampleRate,
|
|
701
|
+
channels: chunk.channels,
|
|
702
|
+
bytes: chunk.data.byteLength,
|
|
703
|
+
windowMs,
|
|
704
|
+
classifierResamples: chunk.sampleRate !== CLASSIFIER_SAMPLE_RATE || chunk.channels !== CLASSIFIER_CHANNELS,
|
|
705
|
+
previous
|
|
706
|
+
}
|
|
707
|
+
});
|
|
708
|
+
}
|
|
666
709
|
async classify(chunk) {
|
|
667
710
|
const camKey = chunk.deviceId ?? GLOBAL_DEVICE_KEY;
|
|
668
711
|
const now = Date.now();
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
//#region \0rolldown/runtime.js
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __commonJSMin = (cb, mod) => () => (mod || (cb((mod = { exports: {} }).exports, mod), cb = null), mod.exports);
|
|
9
|
+
var __copyProps = (to, from, except, desc) => {
|
|
10
|
+
if (from && typeof from === "object" || typeof from === "function") for (var keys = __getOwnPropNames(from), i = 0, n = keys.length, key; i < n; i++) {
|
|
11
|
+
key = keys[i];
|
|
12
|
+
if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
13
|
+
get: ((k) => from[k]).bind(null, key),
|
|
14
|
+
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
15
|
+
});
|
|
16
|
+
}
|
|
17
|
+
return to;
|
|
18
|
+
};
|
|
19
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
|
|
20
|
+
value: mod,
|
|
21
|
+
enumerable: true
|
|
22
|
+
}) : target, mod));
|
|
23
|
+
//#endregion
|
|
24
|
+
Object.defineProperty(exports, "__commonJSMin", {
|
|
25
|
+
enumerable: true,
|
|
26
|
+
get: function() {
|
|
27
|
+
return __commonJSMin;
|
|
28
|
+
}
|
|
29
|
+
});
|
|
30
|
+
Object.defineProperty(exports, "__toESM", {
|
|
31
|
+
enumerable: true,
|
|
32
|
+
get: function() {
|
|
33
|
+
return __toESM;
|
|
34
|
+
}
|
|
35
|
+
});
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { N as audioKindId, a as COCO_80_LABELS, o as COCO_TO_MACRO, r as AUDIO_MACRO_LABELS, tt as hfModelUrl } from "./dist-
|
|
1
|
+
import { N as audioKindId, a as COCO_80_LABELS, o as COCO_TO_MACRO, r as AUDIO_MACRO_LABELS, tt as hfModelUrl } from "./dist-ClihWGOZ.mjs";
|
|
2
2
|
import { randomUUID } from "node:crypto";
|
|
3
3
|
//#region src/detection-pipeline/pipeline/landmark-precision-gate.ts
|
|
4
4
|
/**
|
|
@@ -2,20 +2,21 @@ Object.defineProperties(exports, {
|
|
|
2
2
|
__esModule: { value: true },
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
|
-
const
|
|
6
|
-
const
|
|
7
|
-
const
|
|
8
|
-
const
|
|
9
|
-
const
|
|
5
|
+
const require_chunk = require("../chunk-emK7D4bc.js");
|
|
6
|
+
const require_dist = require("../dist-ByPsWlTa.js");
|
|
7
|
+
const require_node = require("../node-CNPnaux4.js");
|
|
8
|
+
const require_default_detection_model = require("../default-detection-model-x6oNMBDH.js");
|
|
9
|
+
const require_lazy_sharp = require("../lazy-sharp-BuwKlQLR.js");
|
|
10
|
+
const require_process_memory = require("../process-memory-9KqRtUHt.js");
|
|
10
11
|
let node_os = require("node:os");
|
|
11
|
-
node_os =
|
|
12
|
+
node_os = require_chunk.__toESM(node_os);
|
|
12
13
|
let node_fs = require("node:fs");
|
|
13
|
-
node_fs =
|
|
14
|
+
node_fs = require_chunk.__toESM(node_fs);
|
|
14
15
|
let node_path = require("node:path");
|
|
15
|
-
node_path =
|
|
16
|
+
node_path = require_chunk.__toESM(node_path);
|
|
16
17
|
let node_child_process = require("node:child_process");
|
|
17
18
|
let sharp = require("sharp");
|
|
18
|
-
sharp =
|
|
19
|
+
sharp = require_chunk.__toESM(sharp);
|
|
19
20
|
let _camstack_system_addon_utils = require("@camstack/system/addon-utils");
|
|
20
21
|
//#region src/detection-pipeline/runtimes.ts
|
|
21
22
|
var KNOWN_PLATFORMS = [
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { n as __require } from "../chunk-DnnnRqeS.mjs";
|
|
2
|
-
import { $t as parseJsonUnknown, B as defaultDeviceFor$1, Dt as resolvePoolMemoryPolicy, G as detectionPipelineCapability, It as errMsg, J as enumerateInferenceDevices, Jt as hydrateSchema, Pt as supportedRuntimes$1, Qt as nodePin, S as PoolMemoryWatchdog, Ut as BaseAddon, X as evaluateZoneRules, c as DEFAULT_CLUSTER_STEP_MODELS, gt as pickClusterStepSettings, hn as EventCategory, ht as pickClusterStepModels, in as array, it as loadContributionCapability, k as YAMNET_TO_MACRO, kt as runtimeDevices$1, l as DEFAULT_CLUSTER_STEP_SETTINGS, m as DEVICE_BACKEND_TO_FORMAT, mn as union, nn as sleep, nt as inferModelProvider, pn as string, pt as overlayClusterStepSettings, qt as createEvent, t as APPLE_SA_TO_MACRO, un as object, wt as resolveClusterStepModelId, yt as pipelineExecutorCapability } from "../dist-
|
|
3
|
-
import { o as readProcessCost } from "../node-
|
|
4
|
-
import { a as ALL_PIPELINE_STEPS, c as getStep, d as landmarkPrecisionVerdict, l as getStepDefinition, n as resolveDefaultDetectionModel, o as ALL_STEPS, r as localFrameRegistry, s as getDefaultModelForFormat, u as resolveModelForFormat } from "../default-detection-model-
|
|
2
|
+
import { $t as parseJsonUnknown, B as defaultDeviceFor$1, Dt as resolvePoolMemoryPolicy, G as detectionPipelineCapability, It as errMsg, J as enumerateInferenceDevices, Jt as hydrateSchema, Pt as supportedRuntimes$1, Qt as nodePin, S as PoolMemoryWatchdog, Ut as BaseAddon, X as evaluateZoneRules, c as DEFAULT_CLUSTER_STEP_MODELS, gt as pickClusterStepSettings, hn as EventCategory, ht as pickClusterStepModels, in as array, it as loadContributionCapability, k as YAMNET_TO_MACRO, kt as runtimeDevices$1, l as DEFAULT_CLUSTER_STEP_SETTINGS, m as DEVICE_BACKEND_TO_FORMAT, mn as union, nn as sleep, nt as inferModelProvider, pn as string, pt as overlayClusterStepSettings, qt as createEvent, t as APPLE_SA_TO_MACRO, un as object, wt as resolveClusterStepModelId, yt as pipelineExecutorCapability } from "../dist-ClihWGOZ.mjs";
|
|
3
|
+
import { o as readProcessCost } from "../node-DiaTmz84.mjs";
|
|
4
|
+
import { a as ALL_PIPELINE_STEPS, c as getStep, d as landmarkPrecisionVerdict, l as getStepDefinition, n as resolveDefaultDetectionModel, o as ALL_STEPS, r as localFrameRegistry, s as getDefaultModelForFormat, u as resolveModelForFormat } from "../default-detection-model-DBNEc3iw.mjs";
|
|
5
5
|
import { t as getSharp } from "../lazy-sharp-DXsqwpph.mjs";
|
|
6
|
-
import { n as pickNodePlatformArch, t as readProcessMemory } from "../process-memory-
|
|
6
|
+
import { n as pickNodePlatformArch, t as readProcessMemory } from "../process-memory-D4t8hpJd.mjs";
|
|
7
7
|
import * as os from "node:os";
|
|
8
8
|
import * as fs from "node:fs";
|
|
9
9
|
import * as path$1 from "node:path";
|
|
@@ -1,26 +1,3 @@
|
|
|
1
|
-
//#region \0rolldown/runtime.js
|
|
2
|
-
var __create = Object.create;
|
|
3
|
-
var __defProp = Object.defineProperty;
|
|
4
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
-
var __commonJSMin = (cb, mod) => () => (mod || (cb((mod = { exports: {} }).exports, mod), cb = null), mod.exports);
|
|
9
|
-
var __copyProps = (to, from, except, desc) => {
|
|
10
|
-
if (from && typeof from === "object" || typeof from === "function") for (var keys = __getOwnPropNames(from), i = 0, n = keys.length, key; i < n; i++) {
|
|
11
|
-
key = keys[i];
|
|
12
|
-
if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
13
|
-
get: ((k) => from[k]).bind(null, key),
|
|
14
|
-
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
15
|
-
});
|
|
16
|
-
}
|
|
17
|
-
return to;
|
|
18
|
-
};
|
|
19
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
|
|
20
|
-
value: mod,
|
|
21
|
-
enumerable: true
|
|
22
|
-
}) : target, mod));
|
|
23
|
-
//#endregion
|
|
24
1
|
let node_crypto = require("node:crypto");
|
|
25
2
|
//#region ../types/dist/event-category-DAXzJeTX.mjs
|
|
26
3
|
var EventCategory = /* @__PURE__ */ function(EventCategory) {
|
|
@@ -18695,6 +18672,7 @@ var NcSystemEventKindSchema = _enum([
|
|
|
18695
18672
|
"addon-crash-loop",
|
|
18696
18673
|
"addon-update-available",
|
|
18697
18674
|
"server-update-available",
|
|
18675
|
+
"wrapper-update-available",
|
|
18698
18676
|
"alarm-triggered",
|
|
18699
18677
|
"alarm-armed",
|
|
18700
18678
|
"alarm-disarmed",
|
|
@@ -24571,6 +24549,53 @@ var ImageContractSchema = object({
|
|
|
24571
24549
|
/** One operator-grade sentence: this node runs image X; the contract says Y. */
|
|
24572
24550
|
message: string()
|
|
24573
24551
|
});
|
|
24552
|
+
/**
|
|
24553
|
+
* The shell verdict (see {@link WrapperKindSchema}) with the proofs that
|
|
24554
|
+
* produced it.
|
|
24555
|
+
*
|
|
24556
|
+
* There is deliberately NO `canSelfUpdate` and no apply action: a wrapper
|
|
24557
|
+
* update is an ANNOUNCEMENT. The notification body carries the exact command
|
|
24558
|
+
* for a `docker` shell and says the app restarts into the new build for
|
|
24559
|
+
* `electron`, and that sentence is chosen from `kind` alone — a boolean
|
|
24560
|
+
* nothing reads is the defect this repo keeps paying for.
|
|
24561
|
+
*/
|
|
24562
|
+
var WrapperIdentitySchema = object({
|
|
24563
|
+
kind: _enum([
|
|
24564
|
+
"docker",
|
|
24565
|
+
"electron",
|
|
24566
|
+
"native",
|
|
24567
|
+
"contradictory",
|
|
24568
|
+
"unknown"
|
|
24569
|
+
]),
|
|
24570
|
+
/** Every probe that ran, in a stable order. Never empty. */
|
|
24571
|
+
evidence: array(object({
|
|
24572
|
+
/** Which probe this row reports. */
|
|
24573
|
+
fact: _enum([
|
|
24574
|
+
"dockerenv-file",
|
|
24575
|
+
"proc-1-cgroup",
|
|
24576
|
+
"platform",
|
|
24577
|
+
"electron-app-version-env"
|
|
24578
|
+
]),
|
|
24579
|
+
/**
|
|
24580
|
+
* `observed` — this process read it itself. `declared` — the shell told the
|
|
24581
|
+
* process and nothing here can check it. Only the Electron app version is
|
|
24582
|
+
* ever `declared`, and only because a child cannot see its parent.
|
|
24583
|
+
*/
|
|
24584
|
+
mode: _enum(["observed", "declared"]),
|
|
24585
|
+
/** Did the probe support the fact it names? A `false` row is still evidence. */
|
|
24586
|
+
holds: boolean(),
|
|
24587
|
+
/** What was actually read, verbatim enough for an operator to argue with. */
|
|
24588
|
+
detail: string()
|
|
24589
|
+
})),
|
|
24590
|
+
/**
|
|
24591
|
+
* The version of the SHELL, when the shell has one it can state: the
|
|
24592
|
+
* Electron app version it declared, or the baked seed closure that
|
|
24593
|
+
* fingerprints a container / app bundle. `null` for `contradictory` and
|
|
24594
|
+
* `unknown` — which version belongs to the shell is precisely what is not
|
|
24595
|
+
* known there.
|
|
24596
|
+
*/
|
|
24597
|
+
currentVersion: string().nullable()
|
|
24598
|
+
});
|
|
24574
24599
|
var ServerRollbackInfoSchema = object({
|
|
24575
24600
|
/** The version that failed (or was manually rolled back). */
|
|
24576
24601
|
fromVersion: string(),
|
|
@@ -24612,7 +24637,13 @@ var ServerPackageStatusSchema = object({
|
|
|
24612
24637
|
* Seed-vs-contract verdict (see {@link ImageContractSchema}). Optional for
|
|
24613
24638
|
* version skew: an older provider's payload simply omits it.
|
|
24614
24639
|
*/
|
|
24615
|
-
imageContract: ImageContractSchema.optional()
|
|
24640
|
+
imageContract: ImageContractSchema.optional(),
|
|
24641
|
+
/**
|
|
24642
|
+
* What this node runs INSIDE (see {@link WrapperIdentitySchema}). Optional
|
|
24643
|
+
* for version skew: an older provider's payload simply omits it, and an
|
|
24644
|
+
* absent wrapper is unknown — never `native`.
|
|
24645
|
+
*/
|
|
24646
|
+
wrapper: WrapperIdentitySchema.optional()
|
|
24616
24647
|
});
|
|
24617
24648
|
var ServerUpdateCheckResultSchema = object({
|
|
24618
24649
|
packageName: string(),
|
|
@@ -27823,8 +27854,8 @@ includeCrops: boolean().optional() }).optional(), array(IdentitySchema).readonly
|
|
|
27823
27854
|
*
|
|
27824
27855
|
* An **empty array reads NOTHING** — `[]` is an empty page, never
|
|
27825
27856
|
* "every camera". A request for no devices is a request, not an
|
|
27826
|
-
* omission; same contract as `deviceManager.
|
|
27827
|
-
* `pipelineAnalytics.listRecentTracks`.
|
|
27857
|
+
* omission; same contract as `deviceManager.listAll`'s `deviceIds`
|
|
27858
|
+
* and `pipelineAnalytics.listRecentTracks`.
|
|
27828
27859
|
*
|
|
27829
27860
|
* Absent (`undefined`) is the omission, and keeps the cluster-wide view.
|
|
27830
27861
|
*/
|
|
@@ -43516,18 +43547,6 @@ Object.defineProperty(exports, "YAMNET_TO_MACRO", {
|
|
|
43516
43547
|
return YAMNET_TO_MACRO;
|
|
43517
43548
|
}
|
|
43518
43549
|
});
|
|
43519
|
-
Object.defineProperty(exports, "__commonJSMin", {
|
|
43520
|
-
enumerable: true,
|
|
43521
|
-
get: function() {
|
|
43522
|
-
return __commonJSMin;
|
|
43523
|
-
}
|
|
43524
|
-
});
|
|
43525
|
-
Object.defineProperty(exports, "__toESM", {
|
|
43526
|
-
enumerable: true,
|
|
43527
|
-
get: function() {
|
|
43528
|
-
return __toESM;
|
|
43529
|
-
}
|
|
43530
|
-
});
|
|
43531
43550
|
Object.defineProperty(exports, "_enum", {
|
|
43532
43551
|
enumerable: true,
|
|
43533
43552
|
get: function() {
|
|
@@ -18672,6 +18672,7 @@ var NcSystemEventKindSchema = _enum([
|
|
|
18672
18672
|
"addon-crash-loop",
|
|
18673
18673
|
"addon-update-available",
|
|
18674
18674
|
"server-update-available",
|
|
18675
|
+
"wrapper-update-available",
|
|
18675
18676
|
"alarm-triggered",
|
|
18676
18677
|
"alarm-armed",
|
|
18677
18678
|
"alarm-disarmed",
|
|
@@ -24548,6 +24549,53 @@ var ImageContractSchema = object({
|
|
|
24548
24549
|
/** One operator-grade sentence: this node runs image X; the contract says Y. */
|
|
24549
24550
|
message: string()
|
|
24550
24551
|
});
|
|
24552
|
+
/**
|
|
24553
|
+
* The shell verdict (see {@link WrapperKindSchema}) with the proofs that
|
|
24554
|
+
* produced it.
|
|
24555
|
+
*
|
|
24556
|
+
* There is deliberately NO `canSelfUpdate` and no apply action: a wrapper
|
|
24557
|
+
* update is an ANNOUNCEMENT. The notification body carries the exact command
|
|
24558
|
+
* for a `docker` shell and says the app restarts into the new build for
|
|
24559
|
+
* `electron`, and that sentence is chosen from `kind` alone — a boolean
|
|
24560
|
+
* nothing reads is the defect this repo keeps paying for.
|
|
24561
|
+
*/
|
|
24562
|
+
var WrapperIdentitySchema = object({
|
|
24563
|
+
kind: _enum([
|
|
24564
|
+
"docker",
|
|
24565
|
+
"electron",
|
|
24566
|
+
"native",
|
|
24567
|
+
"contradictory",
|
|
24568
|
+
"unknown"
|
|
24569
|
+
]),
|
|
24570
|
+
/** Every probe that ran, in a stable order. Never empty. */
|
|
24571
|
+
evidence: array(object({
|
|
24572
|
+
/** Which probe this row reports. */
|
|
24573
|
+
fact: _enum([
|
|
24574
|
+
"dockerenv-file",
|
|
24575
|
+
"proc-1-cgroup",
|
|
24576
|
+
"platform",
|
|
24577
|
+
"electron-app-version-env"
|
|
24578
|
+
]),
|
|
24579
|
+
/**
|
|
24580
|
+
* `observed` — this process read it itself. `declared` — the shell told the
|
|
24581
|
+
* process and nothing here can check it. Only the Electron app version is
|
|
24582
|
+
* ever `declared`, and only because a child cannot see its parent.
|
|
24583
|
+
*/
|
|
24584
|
+
mode: _enum(["observed", "declared"]),
|
|
24585
|
+
/** Did the probe support the fact it names? A `false` row is still evidence. */
|
|
24586
|
+
holds: boolean(),
|
|
24587
|
+
/** What was actually read, verbatim enough for an operator to argue with. */
|
|
24588
|
+
detail: string()
|
|
24589
|
+
})),
|
|
24590
|
+
/**
|
|
24591
|
+
* The version of the SHELL, when the shell has one it can state: the
|
|
24592
|
+
* Electron app version it declared, or the baked seed closure that
|
|
24593
|
+
* fingerprints a container / app bundle. `null` for `contradictory` and
|
|
24594
|
+
* `unknown` — which version belongs to the shell is precisely what is not
|
|
24595
|
+
* known there.
|
|
24596
|
+
*/
|
|
24597
|
+
currentVersion: string().nullable()
|
|
24598
|
+
});
|
|
24551
24599
|
var ServerRollbackInfoSchema = object({
|
|
24552
24600
|
/** The version that failed (or was manually rolled back). */
|
|
24553
24601
|
fromVersion: string(),
|
|
@@ -24589,7 +24637,13 @@ var ServerPackageStatusSchema = object({
|
|
|
24589
24637
|
* Seed-vs-contract verdict (see {@link ImageContractSchema}). Optional for
|
|
24590
24638
|
* version skew: an older provider's payload simply omits it.
|
|
24591
24639
|
*/
|
|
24592
|
-
imageContract: ImageContractSchema.optional()
|
|
24640
|
+
imageContract: ImageContractSchema.optional(),
|
|
24641
|
+
/**
|
|
24642
|
+
* What this node runs INSIDE (see {@link WrapperIdentitySchema}). Optional
|
|
24643
|
+
* for version skew: an older provider's payload simply omits it, and an
|
|
24644
|
+
* absent wrapper is unknown — never `native`.
|
|
24645
|
+
*/
|
|
24646
|
+
wrapper: WrapperIdentitySchema.optional()
|
|
24593
24647
|
});
|
|
24594
24648
|
var ServerUpdateCheckResultSchema = object({
|
|
24595
24649
|
packageName: string(),
|
|
@@ -27800,8 +27854,8 @@ includeCrops: boolean().optional() }).optional(), array(IdentitySchema).readonly
|
|
|
27800
27854
|
*
|
|
27801
27855
|
* An **empty array reads NOTHING** — `[]` is an empty page, never
|
|
27802
27856
|
* "every camera". A request for no devices is a request, not an
|
|
27803
|
-
* omission; same contract as `deviceManager.
|
|
27804
|
-
* `pipelineAnalytics.listRecentTracks`.
|
|
27857
|
+
* omission; same contract as `deviceManager.listAll`'s `deviceIds`
|
|
27858
|
+
* and `pipelineAnalytics.listRecentTracks`.
|
|
27805
27859
|
*
|
|
27806
27860
|
* Absent (`undefined`) is the omission, and keeps the cluster-wide view.
|
|
27807
27861
|
*/
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
const
|
|
1
|
+
const require_chunk = require("./chunk-emK7D4bc.js");
|
|
2
2
|
let node_path = require("node:path");
|
|
3
|
-
node_path =
|
|
3
|
+
node_path = require_chunk.__toESM(node_path);
|
|
4
4
|
let node_url = require("node:url");
|
|
5
5
|
let node_module = require("node:module");
|
|
6
6
|
//#region src/shared/host-external-import.ts
|
|
@@ -2,8 +2,8 @@ Object.defineProperties(exports, {
|
|
|
2
2
|
__esModule: { value: true },
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
|
-
const require_dist = require("../dist-
|
|
6
|
-
const require_lazy_sharp = require("../lazy-sharp-
|
|
5
|
+
const require_dist = require("../dist-ByPsWlTa.js");
|
|
6
|
+
const require_lazy_sharp = require("../lazy-sharp-BuwKlQLR.js");
|
|
7
7
|
let node_fs = require("node:fs");
|
|
8
8
|
let node_path = require("node:path");
|
|
9
9
|
//#region src/motion-wasm/region-grouping.ts
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Jt as hydrateSchema, Kt as DeviceType, Ut as BaseAddon, X as evaluateZoneRules, ft as motionDetectionCapability } from "../dist-
|
|
1
|
+
import { Jt as hydrateSchema, Kt as DeviceType, Ut as BaseAddon, X as evaluateZoneRules, ft as motionDetectionCapability } from "../dist-ClihWGOZ.mjs";
|
|
2
2
|
import { t as getSharp } from "../lazy-sharp-DXsqwpph.mjs";
|
|
3
3
|
import { readFileSync } from "node:fs";
|
|
4
4
|
import { join } from "node:path";
|
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
const
|
|
1
|
+
const require_chunk = require("./chunk-emK7D4bc.js");
|
|
2
|
+
const require_dist = require("./dist-ByPsWlTa.js");
|
|
2
3
|
let node_crypto = require("node:crypto");
|
|
3
4
|
let node_fs = require("node:fs");
|
|
4
|
-
node_fs =
|
|
5
|
+
node_fs = require_chunk.__toESM(node_fs, 1);
|
|
5
6
|
let node_path = require("node:path");
|
|
6
|
-
node_path =
|
|
7
|
+
node_path = require_chunk.__toESM(node_path, 1);
|
|
7
8
|
require("node:child_process");
|
|
8
9
|
let node_fs_promises = require("node:fs/promises");
|
|
9
10
|
var DEFAULT_FIRST_UNIT_TIMEOUT_MS = 12e3;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { It as errMsg, Rt as Fmp4BoxSplitter, Vt as isSoftwareDecode, zt as buildFfmpegArgs } from "./dist-
|
|
1
|
+
import { It as errMsg, Rt as Fmp4BoxSplitter, Vt as isSoftwareDecode, zt as buildFfmpegArgs } from "./dist-ClihWGOZ.mjs";
|
|
2
2
|
import { randomUUID } from "node:crypto";
|
|
3
3
|
import { realpathSync } from "node:fs";
|
|
4
4
|
import path from "node:path";
|