@camstack/addon-pipeline 1.2.621 → 1.2.623
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 +3 -3
- package/dist/audio-analyzer/index.mjs +3 -3
- package/dist/{custom-model-catalog-Il8UY4D4.js → custom-model-catalog-BTBdgN2p.js} +29 -16
- package/dist/{custom-model-catalog-0_SnSXzN.mjs → custom-model-catalog-D5zTw1LU.mjs} +29 -10
- package/dist/detection-pipeline/index.js +67 -416
- package/dist/detection-pipeline/index.mjs +91 -440
- package/dist/{dist-ClkumZgv.js → dist-BVo3wa7s.js} +711 -302
- package/dist/{dist-DHqkQhTQ.mjs → dist-opSx6v5i.mjs} +651 -296
- package/dist/{model-catalogs-BagalaYp.js → model-catalogs-CQytR2AN.js} +1 -1
- package/dist/{model-catalogs-Z1GZAhSb.mjs → model-catalogs-rIvLUVlw.mjs} +1 -1
- package/dist/motion-wasm/index.js +1 -1
- package/dist/motion-wasm/index.mjs +1 -1
- package/dist/{node-CkJLxlWI.mjs → node-CGIYuJMN.mjs} +1 -1
- package/dist/{node-0O_61WVW.js → node-DqLsuN_A.js} +1 -1
- package/dist/pipeline-runner/index.js +115 -460
- package/dist/pipeline-runner/index.mjs +108 -453
- package/dist/{process-memory-Dj3UgL1e.mjs → process-memory-Bd-TuWfM.mjs} +1 -1
- package/dist/{process-memory-DdIOhjYB.js → process-memory-DyxG-0mG.js} +1 -1
- package/dist/recorder/index.js +2 -2
- package/dist/recorder/index.mjs +2 -2
- package/dist/{segment-demux-js-BePzacki.js → segment-demux-js-B4bfTQpK.js} +1 -1
- package/dist/{segment-demux-js-Bv0t0-tQ.mjs → segment-demux-js-CdVRzwSd.mjs} +1 -1
- package/dist/session-decode/decode-worker-main.js +12 -21
- package/dist/session-decode/decode-worker-main.mjs +12 -21
- package/dist/stream-broker/_stub.js +2 -2
- package/dist/stream-broker/{_virtual_mf-localSharedImportMap___mfe_internal__addon_stream_broker_widgets-dNk74ahz.mjs → _virtual_mf-localSharedImportMap___mfe_internal__addon_stream_broker_widgets-DF3FGCR8.mjs} +2 -2
- package/dist/stream-broker/_virtual_mf___mfe_internal__addon_stream_broker_widgets__loadShare___mf_0_camstack_mf_1_types__loadShare__.js-oUZNn2Kr.mjs +26 -0
- package/dist/stream-broker/_virtual_mf___mfe_internal__addon_stream_broker_widgets__loadShare___mf_0_camstack_mf_1_ui_mf_2_library__loadShare__.js-Bb-ETNGC.mjs +26 -0
- 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-CH5g78CJ.mjs → hostInit-BiyFzSqq.mjs} +2 -2
- package/dist/stream-broker/index.js +3 -3
- package/dist/stream-broker/index.mjs +3 -3
- package/dist/stream-broker/remoteEntry.js +1 -1
- package/dist/{worker-protocol-D_NzPcnh.mjs → worker-protocol-DngGEAT2.js} +102 -2
- package/dist/{worker-protocol-C-G8qmye.js → worker-protocol-_avq7y8O.mjs} +67 -25
- package/package.json +1 -1
- package/python/accelerator_facts.py +275 -0
- package/python/coreml_load_probe.py +105 -15
- package/python/inference_pool.py +19 -2
- package/python/openvino_compile_probe.py +72 -18
- package/python/postprocessors/ssd.py +12 -4
- package/python/postprocessors/test_ssd.py +64 -0
- package/python/test_accelerator_facts.py +105 -0
- package/python/test_coreml_load_probe.py +83 -0
- package/python/test_openvino_compile_probe.py +114 -0
- package/python/webgpu_isolated.py +19 -0
- package/dist/stream-broker/_virtual_mf___mfe_internal__addon_stream_broker_widgets__loadShare___mf_0_camstack_mf_1_types__loadShare__.js-2KkGoQ55.mjs +0 -26
- package/dist/stream-broker/_virtual_mf___mfe_internal__addon_stream_broker_widgets__loadShare___mf_0_camstack_mf_1_ui_mf_2_library__loadShare__.js-Dx-WrMx0.mjs +0 -26
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { i as NO_COST_CLAIM, t as ChildCostRegistry } from "../node-
|
|
3
|
-
import { a as stepsForElectedPool,
|
|
1
|
+
import { $n as defineCustomActions, A as NativeLeaseAdmissionSchema, E as FailureCounters, Er as EventCategory, F as PIPELINE_RAMP, Ft as fuseRecoveredDetections, Gn as BaseAddon, Ht as linkedStepOf, M as NodeBenchRunnerInputSchema, Nt as failureContributionCapability, Q as applyCropClassFloors, Qn as customAction, Sn as rootSuppliesOf, U as ROOT_SUPPLIABLE_STEP_IDS, Un as errMsg, Ut as loadContributionCapability, Yn as MODEL_FORMATS, Z as allowedSuppliedEffect, Zn as createEvent, _ as DEFAULT_DETAIL_CROP_CONVENTION, a as BackgroundRunRegistry, an as planMotionCrops, at as buildBenchStepTree, br as number, bt as deriveRootFaceRefineRect, cn as readRecoveryRecipeForSteps, ft as countRecoverySkips, gr as boolean, hr as array, in as pipelineRunnerCapability, j as NativeLeaseSettingsSchema, lr as nodePin, m as CROP_SUPPLY_SOURCES, mr as _enum, nn as pickNativeLeaseOverride, on as planRecoveryCrops, ot as cameraOwnsMotionViaSensor, pn as remapCropDetections, tn as pickDetailCropConvention, vn as resolveModelBoundSetting, vr as lazy, vt as deriveDetailCropRect, wn as selectRecoveryStep, wr as string, x as DEVICE_RAMP, xn as resolveRootSupply, xr as object, y as DEFAULT_NATIVE_LEASE_SETTINGS, yr as literal } from "../dist-opSx6v5i.mjs";
|
|
2
|
+
import { i as NO_COST_CLAIM, t as ChildCostRegistry } from "../node-CGIYuJMN.mjs";
|
|
3
|
+
import { a as stepsForElectedPool, c as resolveDefaultDetectionModel, d as localFrameRegistry, f as isSessionDecodeReadGone, i as placeDetailStep, l as macroGateVerdict, m as resolveFrameViewGeometry, p as createSessionDecodeCoordinator, s as resolveDeviceEngine, t as CustomModelCatalog, u as rootObjectGate, v as getStep, y as getStepDefinition } from "../custom-model-catalog-D5zTw1LU.mjs";
|
|
4
|
+
import { i as SessionHwaccelSource } from "../worker-protocol-_avq7y8O.mjs";
|
|
4
5
|
import { t as resolveHubHostname } from "../hub-hostname-cCknRYKj.mjs";
|
|
5
6
|
import { t as getSharp } from "../lazy-sharp-DXsqwpph.mjs";
|
|
6
7
|
import { c as withDetectionIntent, o as preRollRequestOf, t as DETECTION_PRE_ROLL_REQUEST_MS } from "../restream-intent-DyGmLAU9.mjs";
|
|
@@ -1766,6 +1767,7 @@ function startSessionDecodePump(deps) {
|
|
|
1766
1767
|
return child;
|
|
1767
1768
|
},
|
|
1768
1769
|
lease: deps.lease,
|
|
1770
|
+
hwaccel: deps.hwaccel,
|
|
1769
1771
|
logger: deps.logger,
|
|
1770
1772
|
teardownMode: () => teardownMode,
|
|
1771
1773
|
onSessionTeardown: (teardown) => {
|
|
@@ -4547,456 +4549,6 @@ function summarizeRunnerHardware(hardware, cpuCores = os$1.cpus().length) {
|
|
|
4547
4549
|
cpuCores
|
|
4548
4550
|
};
|
|
4549
4551
|
}
|
|
4550
|
-
/** Area of a normalised rectangle, never negative. Shared with the D396 recipe. */
|
|
4551
|
-
function normalizedArea(r) {
|
|
4552
|
-
return Math.max(0, r.w) * Math.max(0, r.h);
|
|
4553
|
-
}
|
|
4554
|
-
var area = normalizedArea;
|
|
4555
|
-
function intersection(a, b) {
|
|
4556
|
-
return Math.max(0, Math.min(a.x + a.w, b.x + b.w) - Math.max(a.x, b.x)) * Math.max(0, Math.min(a.y + a.h, b.y + b.h) - Math.max(a.y, b.y));
|
|
4557
|
-
}
|
|
4558
|
-
/**
|
|
4559
|
-
* Share of `region` not covered by any detection box. The sum of pairwise
|
|
4560
|
-
* intersections over-counts where detections overlap each other, which only
|
|
4561
|
-
* makes the pass MORE conservative; clipped at 1.
|
|
4562
|
-
*/
|
|
4563
|
-
function uncoveredFraction(region, detections) {
|
|
4564
|
-
const regionArea = area(region);
|
|
4565
|
-
if (regionArea <= 0) return 0;
|
|
4566
|
-
let covered = 0;
|
|
4567
|
-
for (const detection of detections) covered += intersection(region, detection);
|
|
4568
|
-
return 1 - Math.min(1, covered / regionArea);
|
|
4569
|
-
}
|
|
4570
|
-
/**
|
|
4571
|
-
* THE square-placement rule of this pass — one owner, shared by both recipes.
|
|
4572
|
-
*
|
|
4573
|
-
* A crop is a square of `side` native pixels centred where it can be and slid
|
|
4574
|
-
* inside the frame where it cannot. Both region rules place their squares
|
|
4575
|
-
* through this function so a crop means the same rectangle whichever rule
|
|
4576
|
-
* chose the region.
|
|
4577
|
-
*/
|
|
4578
|
-
function squareAround(centreX, centreY, side, native) {
|
|
4579
|
-
return {
|
|
4580
|
-
left: Math.round(Math.max(0, Math.min(native.width - side, centreX - side / 2))),
|
|
4581
|
-
top: Math.round(Math.max(0, Math.min(native.height - side, centreY - side / 2))),
|
|
4582
|
-
side
|
|
4583
|
-
};
|
|
4584
|
-
}
|
|
4585
|
-
function contains(crop, x, y) {
|
|
4586
|
-
return x >= crop.left && x <= crop.left + crop.side && y >= crop.top && y <= crop.top + crop.side;
|
|
4587
|
-
}
|
|
4588
|
-
/**
|
|
4589
|
-
* Squares for one region: one when it fits the largest side, otherwise up to
|
|
4590
|
-
* two tiles along its longer axis (a person-sized blob with something small
|
|
4591
|
-
* at either end). The padded region decides the side, never the frame.
|
|
4592
|
-
*/
|
|
4593
|
-
function cropsForRegion(region, native) {
|
|
4594
|
-
const widthPx = region.w * native.width;
|
|
4595
|
-
const heightPx = region.h * native.height;
|
|
4596
|
-
const longest = Math.max(widthPx, heightPx);
|
|
4597
|
-
const padded = longest * 1.5;
|
|
4598
|
-
const side = Math.round(Math.min(Math.max(padded, 640), 800));
|
|
4599
|
-
const centreX = (region.x + region.w / 2) * native.width;
|
|
4600
|
-
const centreY = (region.y + region.h / 2) * native.height;
|
|
4601
|
-
if (padded <= 800) return [squareAround(centreX, centreY, side, native)];
|
|
4602
|
-
const alongX = widthPx >= heightPx;
|
|
4603
|
-
const quarter = longest / 4;
|
|
4604
|
-
return [squareAround(alongX ? centreX - quarter : centreX, alongX ? centreY : centreY - quarter, side, native), squareAround(alongX ? centreX + quarter : centreX, alongX ? centreY : centreY + quarter, side, native)];
|
|
4605
|
-
}
|
|
4606
|
-
/**
|
|
4607
|
-
* The ONE place the two region gates are decided. `planRecoveryCrops` filters
|
|
4608
|
-
* on it and {@link countRecoverySkips} counts it, so the report can never
|
|
4609
|
-
* describe a gate the planner does not actually apply.
|
|
4610
|
-
*/
|
|
4611
|
-
function classifyRegion(region, uncovered) {
|
|
4612
|
-
if (area(region) > .25) return "too-large";
|
|
4613
|
-
if (uncovered < .35) return "covered";
|
|
4614
|
-
return "eligible";
|
|
4615
|
-
}
|
|
4616
|
-
/**
|
|
4617
|
-
* WHY A FRAME PLANNED NO CROP, AS A NUMBER (D378).
|
|
4618
|
-
*
|
|
4619
|
-
* The pass report counts the passes that RAN, so "the second pass stops running
|
|
4620
|
-
* when a person is beside the dog" — a plausible reading of
|
|
4621
|
-
* {@link RECOVERY_MAX_REGION_FRAME_FRACTION} and
|
|
4622
|
-
* {@link RECOVERY_MIN_UNCOVERED_FRACTION}, and a live hypothesis on camera 615
|
|
4623
|
-
* — could not be confirmed or killed from the logs at all. This classifies the
|
|
4624
|
-
* regions a frame offered, against the same predicate the planner filters on.
|
|
4625
|
-
*/
|
|
4626
|
-
function countRecoverySkips(input) {
|
|
4627
|
-
let tooLarge = 0;
|
|
4628
|
-
let covered = 0;
|
|
4629
|
-
let eligible = 0;
|
|
4630
|
-
for (const region of input.regions) switch (classifyRegion(region, uncoveredFraction(region, input.detections))) {
|
|
4631
|
-
case "too-large":
|
|
4632
|
-
tooLarge += 1;
|
|
4633
|
-
break;
|
|
4634
|
-
case "covered":
|
|
4635
|
-
covered += 1;
|
|
4636
|
-
break;
|
|
4637
|
-
case "eligible":
|
|
4638
|
-
eligible += 1;
|
|
4639
|
-
break;
|
|
4640
|
-
}
|
|
4641
|
-
return {
|
|
4642
|
-
tooLarge,
|
|
4643
|
-
covered,
|
|
4644
|
-
eligible
|
|
4645
|
-
};
|
|
4646
|
-
}
|
|
4647
|
-
function planRecoveryCrops(input) {
|
|
4648
|
-
const { native } = input;
|
|
4649
|
-
if (Math.min(native.width, native.height) < 640) return [];
|
|
4650
|
-
const ranked = input.regions.map((region) => ({
|
|
4651
|
-
region,
|
|
4652
|
-
uncovered: uncoveredFraction(region, input.detections)
|
|
4653
|
-
})).filter(({ region, uncovered }) => classifyRegion(region, uncovered) === "eligible").toSorted((a, b) => area(b.region) * b.uncovered - area(a.region) * a.uncovered);
|
|
4654
|
-
const planned = [];
|
|
4655
|
-
for (const { region } of ranked) for (const crop of cropsForRegion(region, native)) {
|
|
4656
|
-
if (planned.length >= 2) return planned;
|
|
4657
|
-
const centreX = crop.left + crop.side / 2;
|
|
4658
|
-
const centreY = crop.top + crop.side / 2;
|
|
4659
|
-
if (planned.some((existing) => contains(existing, centreX, centreY))) continue;
|
|
4660
|
-
planned.push(crop);
|
|
4661
|
-
}
|
|
4662
|
-
return planned;
|
|
4663
|
-
}
|
|
4664
|
-
/**
|
|
4665
|
-
* Boxes the executor produced on the crop VIEW → the result's own space.
|
|
4666
|
-
*
|
|
4667
|
-
* Three spaces meet here: the view the model saw (`view`, ≤640 px), the native
|
|
4668
|
-
* square it was cut from (`crop`, native px) and the space the full-frame
|
|
4669
|
-
* result reports in (`result`, native px on the `frameRef` path, the inline
|
|
4670
|
-
* ≤640 view otherwise). A box touching the view edge was clipped by the crop
|
|
4671
|
-
* and is dropped: half a person is not a person, and the tracker would take
|
|
4672
|
-
* the half as the whole.
|
|
4673
|
-
*/
|
|
4674
|
-
function remapCropDetections(detections, crop, view, result, native) {
|
|
4675
|
-
const viewToNative = crop.side / Math.max(1, view.width);
|
|
4676
|
-
const nativeToResultX = result.width / Math.max(1, native.width);
|
|
4677
|
-
const nativeToResultY = result.height / Math.max(1, native.height);
|
|
4678
|
-
const out = [];
|
|
4679
|
-
for (const detection of detections) {
|
|
4680
|
-
const { x, y, width, height } = detection.bbox;
|
|
4681
|
-
if (x <= 2 || y <= 2 || x + width >= view.width - 2 || y + height >= view.height - 2) continue;
|
|
4682
|
-
out.push({
|
|
4683
|
-
...detection,
|
|
4684
|
-
nativeRecovery: {
|
|
4685
|
-
score: detection.score,
|
|
4686
|
-
cropSidePx: crop.side,
|
|
4687
|
-
viewPx: view.width
|
|
4688
|
-
},
|
|
4689
|
-
bbox: {
|
|
4690
|
-
x: (crop.left + x * viewToNative) * nativeToResultX,
|
|
4691
|
-
y: (crop.top + y * viewToNative) * nativeToResultY,
|
|
4692
|
-
width: width * viewToNative * nativeToResultX,
|
|
4693
|
-
height: height * viewToNative * nativeToResultY
|
|
4694
|
-
}
|
|
4695
|
-
});
|
|
4696
|
-
}
|
|
4697
|
-
return out;
|
|
4698
|
-
}
|
|
4699
|
-
function boxIntersection(a, b) {
|
|
4700
|
-
return Math.max(0, Math.min(a.x + a.width, b.x + b.width) - Math.max(a.x, b.x)) * Math.max(0, Math.min(a.y + a.height, b.y + b.height) - Math.max(a.y, b.y));
|
|
4701
|
-
}
|
|
4702
|
-
function sameSubject(recovered, existing) {
|
|
4703
|
-
const inter = boxIntersection(recovered, existing);
|
|
4704
|
-
if (inter <= 0) return false;
|
|
4705
|
-
const areaR = recovered.width * recovered.height;
|
|
4706
|
-
const union = areaR + existing.width * existing.height - inter;
|
|
4707
|
-
if (union > 0 && inter / union >= .5) return true;
|
|
4708
|
-
return areaR > 0 && inter / areaR >= .7;
|
|
4709
|
-
}
|
|
4710
|
-
/**
|
|
4711
|
-
* Class-aware NMS of the recovered boxes against the full-frame ones. Every
|
|
4712
|
-
* full-frame box is kept as it is — the second pass only ADDS. A recovered box
|
|
4713
|
-
* is added when no full-frame box of the same macro class is the same subject
|
|
4714
|
-
* (`RECOVERY_FUSE_IOU`) or contains it (`RECOVERY_FUSE_CONTAINMENT`). Ids are
|
|
4715
|
-
* re-minted so a crop's `d0` cannot collide with the frame's.
|
|
4716
|
-
*/
|
|
4717
|
-
function fuseRecoveredDetections(full, recovered) {
|
|
4718
|
-
const accepted = [];
|
|
4719
|
-
for (const [index, candidate] of recovered.entries()) {
|
|
4720
|
-
if ([...full, ...accepted].some((existing) => existing.macroClass === candidate.macroClass && sameSubject(candidate.bbox, existing.bbox))) continue;
|
|
4721
|
-
accepted.push({
|
|
4722
|
-
...candidate,
|
|
4723
|
-
id: `recovered-${index}-${candidate.id}`
|
|
4724
|
-
});
|
|
4725
|
-
}
|
|
4726
|
-
return [...full, ...accepted];
|
|
4727
|
-
}
|
|
4728
|
-
/**
|
|
4729
|
-
* The step the second pass runs: the enabled first-level object detector of
|
|
4730
|
-
* the camera's own tree, with its own model and no children. Same model as
|
|
4731
|
-
* the full pass so a recovered box is comparable to a full-frame one.
|
|
4732
|
-
*/
|
|
4733
|
-
function selectRecoveryStep(steps) {
|
|
4734
|
-
const detector = steps.find((step) => step.addonId === "object-detection" && step.enabled !== false);
|
|
4735
|
-
if (!detector) return null;
|
|
4736
|
-
return {
|
|
4737
|
-
addonId: detector.addonId,
|
|
4738
|
-
...detector.modelId !== void 0 ? { modelId: detector.modelId } : {},
|
|
4739
|
-
enabled: true
|
|
4740
|
-
};
|
|
4741
|
-
}
|
|
4742
|
-
/**
|
|
4743
|
-
* The analyzer's last regions per camera, normalised, with the instant they
|
|
4744
|
-
* were measured. Refreshed off the motion path; read on the detection path.
|
|
4745
|
-
* A stale entry answers nothing — the regions of two seconds ago are not this
|
|
4746
|
-
* frame's. An EMPTY analyzer result replaces the previous regions: motion that
|
|
4747
|
-
* stopped is not motion.
|
|
4748
|
-
*/
|
|
4749
|
-
var MotionRegionMirror = class {
|
|
4750
|
-
byDevice = /* @__PURE__ */ new Map();
|
|
4751
|
-
note(deviceId, regions, frameWidth, frameHeight, now) {
|
|
4752
|
-
if (frameWidth <= 0 || frameHeight <= 0) return;
|
|
4753
|
-
this.byDevice.set(deviceId, {
|
|
4754
|
-
at: now,
|
|
4755
|
-
regions: regions.map((region) => ({
|
|
4756
|
-
x: region.bbox.x / frameWidth,
|
|
4757
|
-
y: region.bbox.y / frameHeight,
|
|
4758
|
-
w: region.bbox.w / frameWidth,
|
|
4759
|
-
h: region.bbox.h / frameHeight
|
|
4760
|
-
}))
|
|
4761
|
-
});
|
|
4762
|
-
}
|
|
4763
|
-
fresh(deviceId, now) {
|
|
4764
|
-
const entry = this.byDevice.get(deviceId);
|
|
4765
|
-
if (!entry || now - entry.at > 2e3) return [];
|
|
4766
|
-
return entry.regions;
|
|
4767
|
-
}
|
|
4768
|
-
forget(deviceId) {
|
|
4769
|
-
this.byDevice.delete(deviceId);
|
|
4770
|
-
}
|
|
4771
|
-
};
|
|
4772
|
-
/**
|
|
4773
|
-
* Read the opt-in. Anything that is not the boolean `true` is the shipped
|
|
4774
|
-
* rule: a stored string or a number is a mis-write (this repo has shipped a
|
|
4775
|
-
* setting written into the wrong sqlite table before), and a mis-write must
|
|
4776
|
-
* not silently change what a camera detects on.
|
|
4777
|
-
*/
|
|
4778
|
-
function readRecoveryRecipe(settings) {
|
|
4779
|
-
return settings?.["motionCropDispatch"] === true ? "motion-crop" : "uncovered-region";
|
|
4780
|
-
}
|
|
4781
|
-
/**
|
|
4782
|
-
* The recipe this camera's resolved step tree selects.
|
|
4783
|
-
*
|
|
4784
|
-
* Reads the ENABLED first-level detector's own settings, which is where
|
|
4785
|
-
* `pipelineOrchestrator.setCameraStepOverride` writes a per-camera value. A
|
|
4786
|
-
* tree with no enabled detector runs no second pass at all, so the answer
|
|
4787
|
-
* there is the shipped rule and it is never used.
|
|
4788
|
-
*/
|
|
4789
|
-
function readRecoveryRecipeForSteps(steps) {
|
|
4790
|
-
return readRecoveryRecipe(steps.find((step) => step.addonId === "object-detection" && step.enabled !== false)?.settings);
|
|
4791
|
-
}
|
|
4792
|
-
/**
|
|
4793
|
-
* A motion box is grown ×1.5 about its centre before anything else.
|
|
4794
|
-
*
|
|
4795
|
-
* The motion step's box is the CHANGED pixels, which on a moving animal is the
|
|
4796
|
-
* leading edge plus its shadow, not the animal. The detector needs the subject
|
|
4797
|
-
* and the context it was trained on.
|
|
4798
|
-
*/
|
|
4799
|
-
var MOTION_CROP_MOTION_PAD = 1.5;
|
|
4800
|
-
/**
|
|
4801
|
-
* An intersecting tracked box is grown ×1.25 — less, because it is already a
|
|
4802
|
-
* subject rectangle rather than a change mask.
|
|
4803
|
-
*/
|
|
4804
|
-
var MOTION_CROP_TRACKED_PAD = 1.25;
|
|
4805
|
-
/**
|
|
4806
|
-
* The floor a `person` or `vehicle` box must clear when it came out of a CROP
|
|
4807
|
-
* rather than out of the full frame.
|
|
4808
|
-
*
|
|
4809
|
-
* Collected, not assumed: 3 085 quiet frames produced 27 motion-positive
|
|
4810
|
-
* frames and 28 crop invocations. The full-frame arm produced 0 boxes above
|
|
4811
|
-
* any gate; the crop arm produced 3, of which two are genuine false positives,
|
|
4812
|
-
* and both are night-IR corners upscaled into a 320 model — `vehicle 0.749`
|
|
4813
|
-
* and `person 0.701`. Zero false `animal` at any gate, which is why `animal`
|
|
4814
|
-
* is deliberately absent from this table: the class the pass exists to recover
|
|
4815
|
-
* is the class that never produced a false positive, and gating it would cost
|
|
4816
|
-
* the whole measured gain.
|
|
4817
|
-
*
|
|
4818
|
-
* This is a CROP-ONLY floor, applied on top of the per-macro floors the
|
|
4819
|
-
* executor already enforced. A full-frame `person` at 0.70 is untouched — the
|
|
4820
|
-
* full-frame arm is the one arm with ground truth behind its floor
|
|
4821
|
-
* (`minConfidencePerson` 0.65, raised on 2026-07-30 from a measured
|
|
4822
|
-
* distribution).
|
|
4823
|
-
*
|
|
4824
|
-
* The cost of this floor is stated rather than assumed away: it can also
|
|
4825
|
-
* remove a real distant person or vehicle recovered from a crop at 0.70–0.80.
|
|
4826
|
-
* Nothing in the quiet-footage sample measures that, so the floor is a
|
|
4827
|
-
* constant here rather than a slider, and the runner reports every drop it
|
|
4828
|
-
* makes per camera.
|
|
4829
|
-
*/
|
|
4830
|
-
var CROP_CLASS_FLOORS = Object.freeze({
|
|
4831
|
-
person: .8,
|
|
4832
|
-
vehicle: .8
|
|
4833
|
-
});
|
|
4834
|
-
/**
|
|
4835
|
-
* Apply the crop-only class floors, REPORTING every drop.
|
|
4836
|
-
*
|
|
4837
|
-
* A class with no entry in {@link CROP_CLASS_FLOORS} is kept: a floor this
|
|
4838
|
-
* table cannot express is not a floor of zero, and silently dropping a class
|
|
4839
|
-
* nobody measured is the exact shape of silent drop this repo has paid for
|
|
4840
|
-
* three separate times.
|
|
4841
|
-
*/
|
|
4842
|
-
function applyCropClassFloors(detections) {
|
|
4843
|
-
const kept = [];
|
|
4844
|
-
const dropped = [];
|
|
4845
|
-
for (const detection of detections) {
|
|
4846
|
-
const floor = CROP_CLASS_FLOORS[detection.macroClass];
|
|
4847
|
-
if (floor !== void 0 && detection.score < floor) {
|
|
4848
|
-
dropped.push({
|
|
4849
|
-
macroClass: detection.macroClass,
|
|
4850
|
-
score: detection.score,
|
|
4851
|
-
floor
|
|
4852
|
-
});
|
|
4853
|
-
continue;
|
|
4854
|
-
}
|
|
4855
|
-
kept.push(detection);
|
|
4856
|
-
}
|
|
4857
|
-
return {
|
|
4858
|
-
kept,
|
|
4859
|
-
dropped
|
|
4860
|
-
};
|
|
4861
|
-
}
|
|
4862
|
-
function scaleAbout(rect, factor) {
|
|
4863
|
-
const w = rect.w * factor;
|
|
4864
|
-
const h = rect.h * factor;
|
|
4865
|
-
return {
|
|
4866
|
-
x: rect.x + rect.w / 2 - w / 2,
|
|
4867
|
-
y: rect.y + rect.h / 2 - h / 2,
|
|
4868
|
-
w,
|
|
4869
|
-
h
|
|
4870
|
-
};
|
|
4871
|
-
}
|
|
4872
|
-
function overlaps(a, b) {
|
|
4873
|
-
return Math.min(a.x + a.w, b.x + b.w) > Math.max(a.x, b.x) && Math.min(a.y + a.h, b.y + b.h) > Math.max(a.y, b.y);
|
|
4874
|
-
}
|
|
4875
|
-
function union(a, b) {
|
|
4876
|
-
const x = Math.min(a.x, b.x);
|
|
4877
|
-
const y = Math.min(a.y, b.y);
|
|
4878
|
-
return {
|
|
4879
|
-
x,
|
|
4880
|
-
y,
|
|
4881
|
-
w: Math.max(a.x + a.w, b.x + b.w) - x,
|
|
4882
|
-
h: Math.max(a.y + a.h, b.y + b.h) - y
|
|
4883
|
-
};
|
|
4884
|
-
}
|
|
4885
|
-
function clampToFrame(rect) {
|
|
4886
|
-
const x = Math.max(0, rect.x);
|
|
4887
|
-
const y = Math.max(0, rect.y);
|
|
4888
|
-
return {
|
|
4889
|
-
x,
|
|
4890
|
-
y,
|
|
4891
|
-
w: Math.min(1, rect.x + rect.w) - x,
|
|
4892
|
-
h: Math.min(1, rect.y + rect.h) - y
|
|
4893
|
-
};
|
|
4894
|
-
}
|
|
4895
|
-
/**
|
|
4896
|
-
* Merge transitively every seed whose padded box overlaps another, and answer
|
|
4897
|
-
* the union rectangles.
|
|
4898
|
-
*
|
|
4899
|
-
* Transitive on purpose: a person, the dog beside them and the dog's shadow
|
|
4900
|
-
* are three components of one subject, and cutting three crops for them spends
|
|
4901
|
-
* two inferences on pixels the first one already showed the detector.
|
|
4902
|
-
*/
|
|
4903
|
-
function mergeSeeds(seeds) {
|
|
4904
|
-
const merged = [];
|
|
4905
|
-
for (const seed of seeds) {
|
|
4906
|
-
let current = seed;
|
|
4907
|
-
let changed = true;
|
|
4908
|
-
while (changed) {
|
|
4909
|
-
changed = false;
|
|
4910
|
-
for (let i = merged.length - 1; i >= 0; i -= 1) {
|
|
4911
|
-
const other = merged[i];
|
|
4912
|
-
if (other === void 0 || !overlaps(current, other)) continue;
|
|
4913
|
-
current = union(current, other);
|
|
4914
|
-
merged.splice(i, 1);
|
|
4915
|
-
changed = true;
|
|
4916
|
-
}
|
|
4917
|
-
}
|
|
4918
|
-
merged.push(current);
|
|
4919
|
-
}
|
|
4920
|
-
return merged;
|
|
4921
|
-
}
|
|
4922
|
-
/**
|
|
4923
|
-
* The regions the measured recipe judges this frame on.
|
|
4924
|
-
*
|
|
4925
|
-
* Motion boxes padded {@link MOTION_CROP_MOTION_PAD}; every full-frame box
|
|
4926
|
-
* that intersects a RAW motion box padded {@link MOTION_CROP_TRACKED_PAD} and
|
|
4927
|
-
* added as a seed of its own; everything that overlaps merged; the result
|
|
4928
|
-
* clamped to the frame, ordered largest first and capped at
|
|
4929
|
-
* {@link MOTION_CROP_MAX_REGIONS}.
|
|
4930
|
-
*
|
|
4931
|
-
* There is deliberately no coverage gate and no size gate here. Those belong
|
|
4932
|
-
* to the shipped rule, and they are what makes it a rule about a subject
|
|
4933
|
-
* BESIDE a detected one; the measurement says the pass is worth running on the
|
|
4934
|
-
* detected subject's own region too.
|
|
4935
|
-
*/
|
|
4936
|
-
function planMotionCropRegions(input) {
|
|
4937
|
-
if (input.regions.length === 0) return [];
|
|
4938
|
-
const seeds = input.regions.map((r) => scaleAbout(r, MOTION_CROP_MOTION_PAD));
|
|
4939
|
-
for (const detection of input.detections) {
|
|
4940
|
-
if (!input.regions.some((region) => overlaps(detection, region))) continue;
|
|
4941
|
-
seeds.push(scaleAbout(detection, MOTION_CROP_TRACKED_PAD));
|
|
4942
|
-
}
|
|
4943
|
-
return mergeSeeds(seeds).map(clampToFrame).filter((r) => r.w > 0 && r.h > 0).toSorted((a, b) => normalizedArea(b) - normalizedArea(a)).slice(0, 3);
|
|
4944
|
-
}
|
|
4945
|
-
/**
|
|
4946
|
-
* The square the detector is fed for one measured region.
|
|
4947
|
-
*
|
|
4948
|
-
* "Grow to the detector's input aspect ratio without ever shrinking" is a
|
|
4949
|
-
* SQUARE here, and that is a fact about the production detector rather than a
|
|
4950
|
-
* simplification: `yolov9m-320-int8` takes 320×320, as does every hardware
|
|
4951
|
-
* default in the catalog.
|
|
4952
|
-
*
|
|
4953
|
-
* The side is the region's longer side, floored at
|
|
4954
|
-
* {@link RECOVERY_CROP_MIN_SIDE_PX} — the growth is what magnifies the subject
|
|
4955
|
-
* — and ceilinged at {@link RECOVERY_CROP_MAX_SIDE_PX}. The ceiling is NOT a
|
|
4956
|
-
* simplification either: at 1024 px the same 320 model scored the reference
|
|
4957
|
-
* dog 0.52–0.76, and at 1280 px lost it entirely
|
|
4958
|
-
* (`docs/benchmarks/pipeline-frame-model-eval.md`, case `miss-dog-615`). A
|
|
4959
|
-
* region longer than the ceiling is TILED along its longer axis, never zoomed
|
|
4960
|
-
* out.
|
|
4961
|
-
*/
|
|
4962
|
-
function motionCropsForRegion(region, native) {
|
|
4963
|
-
const widthPx = region.w * native.width;
|
|
4964
|
-
const heightPx = region.h * native.height;
|
|
4965
|
-
const longest = Math.max(widthPx, heightPx);
|
|
4966
|
-
const side = Math.round(Math.min(Math.max(longest, 640), 800));
|
|
4967
|
-
const centreX = (region.x + region.w / 2) * native.width;
|
|
4968
|
-
const centreY = (region.y + region.h / 2) * native.height;
|
|
4969
|
-
if (longest <= 800) return [squareAround(centreX, centreY, side, native)];
|
|
4970
|
-
const alongX = widthPx >= heightPx;
|
|
4971
|
-
const quarter = longest / 4;
|
|
4972
|
-
return [squareAround(alongX ? centreX - quarter : centreX, alongX ? centreY : centreY - quarter, side, native), squareAround(alongX ? centreX + quarter : centreX, alongX ? centreY : centreY + quarter, side, native)];
|
|
4973
|
-
}
|
|
4974
|
-
/** `true` when `inner` lies entirely inside `outer`. */
|
|
4975
|
-
function cropContains(outer, inner) {
|
|
4976
|
-
return inner.left >= outer.left && inner.top >= outer.top && inner.left + inner.side <= outer.left + outer.side && inner.top + inner.side <= outer.top + outer.side;
|
|
4977
|
-
}
|
|
4978
|
-
/**
|
|
4979
|
-
* The crops the measured recipe runs on this frame.
|
|
4980
|
-
*
|
|
4981
|
-
* Dedupe is by CONTAINMENT only. Two squares that merely overlap both run: the
|
|
4982
|
-
* pixels the second adds are pixels no other crop shows the detector, and the
|
|
4983
|
-
* fusion step downstream already refuses a duplicate BOX. Dropping a crop
|
|
4984
|
-
* because it overlapped would drop the subject sitting at its edge, which is
|
|
4985
|
-
* the whole population this pass exists for.
|
|
4986
|
-
*
|
|
4987
|
-
* A frame that cannot hold the smallest crop yields nothing: it is already
|
|
4988
|
-
* seen at scale.
|
|
4989
|
-
*/
|
|
4990
|
-
function planMotionCrops(input) {
|
|
4991
|
-
const { native } = input;
|
|
4992
|
-
if (Math.min(native.width, native.height) < 640) return [];
|
|
4993
|
-
const planned = [];
|
|
4994
|
-
for (const region of planMotionCropRegions(input)) for (const crop of motionCropsForRegion(region, native)) {
|
|
4995
|
-
if (planned.some((existing) => cropContains(existing, crop))) continue;
|
|
4996
|
-
planned.push(crop);
|
|
4997
|
-
}
|
|
4998
|
-
return planned;
|
|
4999
|
-
}
|
|
5000
4552
|
//#endregion
|
|
5001
4553
|
//#region src/pipeline-runner/motion-frame-view.ts
|
|
5002
4554
|
var MOTION_FRAME_VIEW = {
|
|
@@ -7294,6 +6846,97 @@ var PipelineRunner = class {
|
|
|
7294
6846
|
}
|
|
7295
6847
|
};
|
|
7296
6848
|
//#endregion
|
|
6849
|
+
//#region src/pipeline-runner/small-subject-recovery.ts
|
|
6850
|
+
/**
|
|
6851
|
+
* Small-subject recovery — a second detector pass at NATIVE resolution on
|
|
6852
|
+
* the moving regions the full-frame pass did not account for.
|
|
6853
|
+
*
|
|
6854
|
+
* ## Why
|
|
6855
|
+
*
|
|
6856
|
+
* The first-level detector sees the frame at its input size (320 px on every
|
|
6857
|
+
* hardware-aware default). A 4K frame is reduced 12×: a dog measured at
|
|
6858
|
+
* 89–277 px in the source is 7–38 px for the model and is not emitted. Camera 615, six
|
|
6859
|
+
* instants with a dog in the scene, five with no `animal` detection at all —
|
|
6860
|
+
* nothing downstream (tracker, gate, notifications) ever saw a subject. The
|
|
6861
|
+
* confirmation gate, which re-runs the same detector on a 320 px native crop
|
|
6862
|
+
* of the PERSON, found the dog at 0.74–0.91 as `bestIncompatibleClass`. The
|
|
6863
|
+
* measurement that decided the constants below is
|
|
6864
|
+
* `docs/benchmarks/pipeline-frame-model-eval.md`, case `miss-dog-615`: a
|
|
6865
|
+
* 640–800 px native square around the moving region brings the dog to
|
|
6866
|
+
* 0.82–0.91 with the SAME 320 model; a 1280 px square loses it again.
|
|
6867
|
+
*
|
|
6868
|
+
* ## What this is NOT (D52)
|
|
6869
|
+
*
|
|
6870
|
+
* Not a detail/CLIP crop. `deriveDetailCropRect` derives the rectangle a
|
|
6871
|
+
* detail or embedding step is fed from a KNOWN subject box, and one vector
|
|
6872
|
+
* index tolerates exactly one such derivation. This module derives a square
|
|
6873
|
+
* from a MOTION region, before any subject exists, for the FIRST-LEVEL
|
|
6874
|
+
* detector; its output is a detection, never a vector. Nothing here may be
|
|
6875
|
+
* reused for a detail crop, and nothing here calls the detail derivation.
|
|
6876
|
+
*
|
|
6877
|
+
* ## When it runs — NOT only when the frame is empty
|
|
6878
|
+
*
|
|
6879
|
+
* The trigger is an UNCOVERED MOTION REGION, deliberately broader than "the
|
|
6880
|
+
* full-frame pass found nothing". Camera 615, 2026-09-06 19:54:33 local: the
|
|
6881
|
+
* gate DID confirm an `animal` birth (bestScore 0.8983) — and the track held
|
|
6882
|
+
* 9 positions over 1 666 ms, then coasted out its `maxMissedMs` (4 000 ms) and
|
|
6883
|
+
* died at 19:54:39, before the dog reached the Aiuola zone. Both of its object
|
|
6884
|
+
* events carry `zones: []`, while in the same seconds the animal was in fact
|
|
6885
|
+
* at x≈3200, inside the zone. So the defect is not only "the subject is never
|
|
6886
|
+
* born" — it is "the subject is born and then the full-frame pass stops seeing
|
|
6887
|
+
* it", and a pass gated on "no detections at all" would not have run on a
|
|
6888
|
+
* single one of those frames, because the PERSON was still detected.
|
|
6889
|
+
*
|
|
6890
|
+
* Gating on the motion region instead makes the pass fire in both cases with
|
|
6891
|
+
* one rule: a moving thing the full-frame boxes do not account for. A live
|
|
6892
|
+
* track feeding on recovered boxes needs one hit per `maxMissedMs` to survive
|
|
6893
|
+
* and `minHits` (3) to be born; at {@link RECOVERY_MIN_INTERVAL_MS} the pass
|
|
6894
|
+
* supplies 2/s, which is 8× the coasting budget and births a subject in 1.5 s.
|
|
6895
|
+
*
|
|
6896
|
+
* ## Where
|
|
6897
|
+
*
|
|
6898
|
+
* In the runner, in-process, on the frame the full pass just ran on. The
|
|
6899
|
+
* pixels come from the same process-local `frameRef` lease the full pass
|
|
6900
|
+
* used; the crop is resolved as one compressed ≤640 px view. Frames never
|
|
6901
|
+
* cross a process boundary at frame rate (D9/D18) — a second crop of the
|
|
6902
|
+
* same frame on the same channel does not change that.
|
|
6903
|
+
*
|
|
6904
|
+
* The pure planning lives in `@camstack/types` (`pipeline/second-pass/`) so the
|
|
6905
|
+
* offline accuracy eval runs the same planner; this module re-exports it and
|
|
6906
|
+
* keeps the one stateful piece, the per-camera motion-region mirror. The
|
|
6907
|
+
* runner wires the lease, the executor call and the rate limit around it.
|
|
6908
|
+
*/
|
|
6909
|
+
/**
|
|
6910
|
+
* The analyzer's last regions per camera, normalised, with the instant they
|
|
6911
|
+
* were measured. Refreshed off the motion path; read on the detection path.
|
|
6912
|
+
* A stale entry answers nothing — the regions of two seconds ago are not this
|
|
6913
|
+
* frame's. An EMPTY analyzer result replaces the previous regions: motion that
|
|
6914
|
+
* stopped is not motion.
|
|
6915
|
+
*/
|
|
6916
|
+
var MotionRegionMirror = class {
|
|
6917
|
+
byDevice = /* @__PURE__ */ new Map();
|
|
6918
|
+
note(deviceId, regions, frameWidth, frameHeight, now) {
|
|
6919
|
+
if (frameWidth <= 0 || frameHeight <= 0) return;
|
|
6920
|
+
this.byDevice.set(deviceId, {
|
|
6921
|
+
at: now,
|
|
6922
|
+
regions: regions.map((region) => ({
|
|
6923
|
+
x: region.bbox.x / frameWidth,
|
|
6924
|
+
y: region.bbox.y / frameHeight,
|
|
6925
|
+
w: region.bbox.w / frameWidth,
|
|
6926
|
+
h: region.bbox.h / frameHeight
|
|
6927
|
+
}))
|
|
6928
|
+
});
|
|
6929
|
+
}
|
|
6930
|
+
fresh(deviceId, now) {
|
|
6931
|
+
const entry = this.byDevice.get(deviceId);
|
|
6932
|
+
if (!entry || now - entry.at > 2e3) return [];
|
|
6933
|
+
return entry.regions;
|
|
6934
|
+
}
|
|
6935
|
+
forget(deviceId) {
|
|
6936
|
+
this.byDevice.delete(deviceId);
|
|
6937
|
+
}
|
|
6938
|
+
};
|
|
6939
|
+
//#endregion
|
|
7297
6940
|
//#region src/pipeline-runner/stateless-step.ts
|
|
7298
6941
|
function modelServability(step, modelId, format) {
|
|
7299
6942
|
const entry = step.models.find((m) => m.id === modelId);
|
|
@@ -10947,6 +10590,14 @@ var PipelineRunnerAddon = class PipelineRunnerAddon extends BaseAddon {
|
|
|
10947
10590
|
*/
|
|
10948
10591
|
resolveSessionLeaseKnobs = () => resolveNativeLeaseKnobs(process.env, this.nativeLease.current());
|
|
10949
10592
|
/**
|
|
10593
|
+
* The decode hwaccel backends this node's kernel resolver offers (D926),
|
|
10594
|
+
* refreshed on the acquire leg with the lease knobs and read when `start` is
|
|
10595
|
+
* sent. A node whose libva cannot initialise the driver offers no vaapi/qsv,
|
|
10596
|
+
* so its session workers never try them.
|
|
10597
|
+
*/
|
|
10598
|
+
sessionHwaccel = new SessionHwaccelSource();
|
|
10599
|
+
resolveSessionHwaccel = () => this.sessionHwaccel.current();
|
|
10600
|
+
/**
|
|
10950
10601
|
* Refresh the lease knobs before a decode worker is spawned. Awaited on the
|
|
10951
10602
|
* `acquire` leg of `startGuardedSessionDecode` (which always completes before
|
|
10952
10603
|
* `startPump` forks), so the spawn sees a value at most one TTL stale rather
|
|
@@ -11539,6 +11190,7 @@ var PipelineRunnerAddon = class PipelineRunnerAddon extends BaseAddon {
|
|
|
11539
11190
|
*/
|
|
11540
11191
|
async acquireSessionDecodeRestream(api, deviceId, streamId, tag, hostname, ownerNodeId, detectionIntent) {
|
|
11541
11192
|
await this.refreshNativeLeaseSettings();
|
|
11193
|
+
await this.sessionHwaccel.refresh(this.ctxIfReady?.kernel.hwaccel);
|
|
11542
11194
|
return acquireSessionDecodeRestreamFrom(api, this.ctx.logger, {
|
|
11543
11195
|
deviceId,
|
|
11544
11196
|
streamId,
|
|
@@ -11724,6 +11376,7 @@ var PipelineRunnerAddon = class PipelineRunnerAddon extends BaseAddon {
|
|
|
11724
11376
|
return startSessionDecodePump({
|
|
11725
11377
|
fork: this.forkDecodeWorkerWithLease,
|
|
11726
11378
|
lease: this.resolveSessionLeaseKnobs,
|
|
11379
|
+
hwaccel: this.resolveSessionHwaccel,
|
|
11727
11380
|
onWorkerGone: hooks.onWorkerGone,
|
|
11728
11381
|
logger: log,
|
|
11729
11382
|
source,
|
|
@@ -11905,6 +11558,7 @@ var PipelineRunnerAddon = class PipelineRunnerAddon extends BaseAddon {
|
|
|
11905
11558
|
return startSessionDecodePump({
|
|
11906
11559
|
fork: this.forkDecodeWorkerWithLease,
|
|
11907
11560
|
lease: this.resolveSessionLeaseKnobs,
|
|
11561
|
+
hwaccel: this.resolveSessionHwaccel,
|
|
11908
11562
|
onWorkerGone: hooks.onWorkerGone,
|
|
11909
11563
|
logger: log,
|
|
11910
11564
|
source,
|
|
@@ -12774,6 +12428,7 @@ var PipelineRunnerAddon = class PipelineRunnerAddon extends BaseAddon {
|
|
|
12774
12428
|
return startSessionDecodePump({
|
|
12775
12429
|
fork: this.forkDecodeWorkerWithLease,
|
|
12776
12430
|
lease: this.resolveSessionLeaseKnobs,
|
|
12431
|
+
hwaccel: this.resolveSessionHwaccel,
|
|
12777
12432
|
onWorkerGone: hooks.onWorkerGone,
|
|
12778
12433
|
logger: log,
|
|
12779
12434
|
source,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
const require_chunk = require("./chunk-emK7D4bc.js");
|
|
2
|
-
const require_dist = require("./dist-
|
|
2
|
+
const require_dist = require("./dist-BVo3wa7s.js");
|
|
3
3
|
let node_fs = require("node:fs");
|
|
4
4
|
node_fs = require_chunk.__toESM(node_fs);
|
|
5
5
|
let node_child_process = require("node:child_process");
|
package/dist/recorder/index.js
CHANGED
|
@@ -3,8 +3,8 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
const require_chunk = require("../chunk-emK7D4bc.js");
|
|
6
|
-
const require_dist = require("../dist-
|
|
7
|
-
const require_node = require("../node-
|
|
6
|
+
const require_dist = require("../dist-BVo3wa7s.js");
|
|
7
|
+
const require_node = require("../node-DqLsuN_A.js");
|
|
8
8
|
const require_hub_hostname = require("../hub-hostname-DAJXlOgV.js");
|
|
9
9
|
const require_restream_intent = require("../restream-intent-7uDNqMKs.js");
|
|
10
10
|
let node_crypto = require("node:crypto");
|
package/dist/recorder/index.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { i as NO_COST_CLAIM, o as physicalRootOf, t as ChildCostRegistry } from "../node-
|
|
1
|
+
import { $n as defineCustomActions, An as stripRetiredBandPreBufferSec, At as evictionPolicyForMode, B as RECORDING_SOURCE_CAMSTACK, Bt as isFirstLevelMacroClass, C as EVENT_PAD_MS, Cr as record, Ct as dominantClipLabels, Dn as storageEvictableCapability, Er as EventCategory, G as RecordingSignalStatusSchema, Gn as BaseAddon, Hn as DeviceType, It as gbToBytes, J as VISIT_MERGE_GAP_MS, Jt as memoizePinnedFfmpeg, Kt as mayReadLocation, Mn as videoclipsCapability, Mt as exportSubjectOf, On as storageOccupancyCapability, P as OpsLogEntrySchema, Qn as customAction, Rn as evaluateSensorEdge, S as EVENT_OWNER_TYPES, Sr as preprocess, St as deviceRemovalHookCapability, T as ExportRecordSchema, Tn as startMoverUnderClearance, Un as errMsg$1, Ut as loadContributionCapability, V as RECORDING_SOURCE_CAMSTACK_ADDON, Vn as DeviceFeature, W as RecordingConfigSchema, Xt as modeMayWrite, Yt as migrateLegacyDeviceSignalConfig, _n as resolveLocationMode, _t as deriveBatteryPresence, bn as resolveRecordingProfiles, br as number, ct as clipExportFailure, dn as recordingExportCapability, dr as selectAssignedProfileSlots, er as defineRecordKinds, et as armRemovalReconcile, fn as recordingSignalCapability, fr as sleep$1, gr as boolean, hn as resolveCreateExportSubject, hr as array, it as batteryCapability, jt as evictionPolicyOfLocation, kt as eventOverlapsClipWindow, ln as recordingArchiveCapability, lr as nodePin, lt as clipExportFailureOf, mr as _enum, o as BatteryStatusSchema, pr as userError, q as VIDEOCLIPS_MAX_OFFER_BYTES, qt as mayWriteToLocation, rr as hydrateSchema, s as CLIP_BROKER_PACED_RATES, un as recordingCapability, v as DEFAULT_EVENTS_BAND_BUFFER_SEC, wr as string, xr as object, yt as deriveRecordingMode, z as RECORDING_EXPORT_MAX_READ_BYTES } from "../dist-opSx6v5i.mjs";
|
|
2
|
+
import { i as NO_COST_CLAIM, o as physicalRootOf, t as ChildCostRegistry } from "../node-CGIYuJMN.mjs";
|
|
3
3
|
import { t as resolveHubHostname } from "../hub-hostname-cCknRYKj.mjs";
|
|
4
4
|
import { d as PREBUFFER_MAX_MS, l as withRecordingIntent, r as RECORDING_PRE_ROLL_REQUEST_MS } from "../restream-intent-DyGmLAU9.mjs";
|
|
5
5
|
import { randomUUID } from "node:crypto";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
const require_chunk = require("./chunk-emK7D4bc.js");
|
|
2
|
-
const require_dist = require("./dist-
|
|
2
|
+
const require_dist = require("./dist-BVo3wa7s.js");
|
|
3
3
|
let node_child_process = require("node:child_process");
|
|
4
4
|
//#region src/stream-broker/recorded/avcc-annexb.ts
|
|
5
5
|
/**
|