@camstack/addon-post-analysis 1.2.123 → 1.2.124

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.
@@ -25937,6 +25937,11 @@ var embeddingActions = require_dist.defineCustomActions({
25937
25937
  "embedding.reembedFacesStatus": require_dist.customAction(NoInputSchema$1, ReembedFacesStatusSchema)
25938
25938
  });
25939
25939
  //#endregion
25940
+ //#region src/pipeline-analytics/include-crops-default.ts
25941
+ function resolveIncludeCrops(input) {
25942
+ return input?.includeCrops === true;
25943
+ }
25944
+ //#endregion
25940
25945
  //#region src/pipeline-analytics/map-with-concurrency.ts
25941
25946
  /**
25942
25947
  * Apply `mapper` to every item with at most `limit` in flight at once.
@@ -26595,7 +26600,7 @@ var FaceGalleryProvider = class {
26595
26600
  });
26596
26601
  const identities = await this.identityStore.listIdentities();
26597
26602
  const nameMap = new Map(identities.map((i) => [i.id, i.name]));
26598
- const includeCrops = input?.includeCrops ?? true;
26603
+ const includeCrops = resolveIncludeCrops(input);
26599
26604
  return mapWithConcurrency(faces, FACE_CROP_FETCH_CONCURRENCY, async (face) => {
26600
26605
  const base64 = includeCrops ? await this.faceCropBase64(face) : void 0;
26601
26606
  const cropUrl = this.cropUrlFor(face);
@@ -30867,7 +30872,7 @@ var PlateGalleryProvider = class {
30867
30872
  return media.length > 0 ? media[0].base64 : void 0;
30868
30873
  }
30869
30874
  async toPlateInfo(plate, nameMap, opts) {
30870
- const base64 = opts?.includeCrops ?? true ? await this.plateCropBase64(plate) : void 0;
30875
+ const base64 = resolveIncludeCrops(opts) ? await this.plateCropBase64(plate) : void 0;
30871
30876
  const cropUrl = this.cropUrlFor(plate);
30872
30877
  const vehicleName = plate.recognizedVehicleId != null ? nameMap?.get(plate.recognizedVehicleId) : void 0;
30873
30878
  return {
@@ -30905,7 +30910,7 @@ var PlateGalleryProvider = class {
30905
30910
  ...input?.limit !== void 0 ? { limit: input.limit } : {}
30906
30911
  });
30907
30912
  const nameMap = await this.vehicleNameMap();
30908
- const includeCrops = input?.includeCrops ?? true;
30913
+ const includeCrops = resolveIncludeCrops(input);
30909
30914
  return Promise.all(rows.map((p) => this.toPlateInfo(p, nameMap, { includeCrops })));
30910
30915
  }
30911
30916
  async getPlateByTrack(input) {
@@ -25915,6 +25915,11 @@ var embeddingActions = defineCustomActions({
25915
25915
  "embedding.reembedFacesStatus": customAction(NoInputSchema$1, ReembedFacesStatusSchema)
25916
25916
  });
25917
25917
  //#endregion
25918
+ //#region src/pipeline-analytics/include-crops-default.ts
25919
+ function resolveIncludeCrops(input) {
25920
+ return input?.includeCrops === true;
25921
+ }
25922
+ //#endregion
25918
25923
  //#region src/pipeline-analytics/map-with-concurrency.ts
25919
25924
  /**
25920
25925
  * Apply `mapper` to every item with at most `limit` in flight at once.
@@ -26573,7 +26578,7 @@ var FaceGalleryProvider = class {
26573
26578
  });
26574
26579
  const identities = await this.identityStore.listIdentities();
26575
26580
  const nameMap = new Map(identities.map((i) => [i.id, i.name]));
26576
- const includeCrops = input?.includeCrops ?? true;
26581
+ const includeCrops = resolveIncludeCrops(input);
26577
26582
  return mapWithConcurrency(faces, FACE_CROP_FETCH_CONCURRENCY, async (face) => {
26578
26583
  const base64 = includeCrops ? await this.faceCropBase64(face) : void 0;
26579
26584
  const cropUrl = this.cropUrlFor(face);
@@ -30843,7 +30848,7 @@ var PlateGalleryProvider = class {
30843
30848
  return media.length > 0 ? media[0].base64 : void 0;
30844
30849
  }
30845
30850
  async toPlateInfo(plate, nameMap, opts) {
30846
- const base64 = opts?.includeCrops ?? true ? await this.plateCropBase64(plate) : void 0;
30851
+ const base64 = resolveIncludeCrops(opts) ? await this.plateCropBase64(plate) : void 0;
30847
30852
  const cropUrl = this.cropUrlFor(plate);
30848
30853
  const vehicleName = plate.recognizedVehicleId != null ? nameMap?.get(plate.recognizedVehicleId) : void 0;
30849
30854
  return {
@@ -30881,7 +30886,7 @@ var PlateGalleryProvider = class {
30881
30886
  ...input?.limit !== void 0 ? { limit: input.limit } : {}
30882
30887
  });
30883
30888
  const nameMap = await this.vehicleNameMap();
30884
- const includeCrops = input?.includeCrops ?? true;
30889
+ const includeCrops = resolveIncludeCrops(input);
30885
30890
  return Promise.all(rows.map((p) => this.toPlateInfo(p, nameMap, { includeCrops })));
30886
30891
  }
30887
30892
  async getPlateByTrack(input) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camstack/addon-post-analysis",
3
- "version": "1.2.123",
3
+ "version": "1.2.124",
4
4
  "description": "Post-Analysis bundle — enrichment, embedding-encoder, pipeline-analytics. Multi-entry npm package shipping addons that consume pipeline output.",
5
5
  "keywords": [
6
6
  "camstack",