@ultralytics/yolo 0.0.60 → 0.0.61

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.
@@ -37,7 +37,7 @@ export class YoloModel {
37
37
  let deferred1_0;
38
38
  let deferred1_1;
39
39
  try {
40
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
40
+ const retptr = wasm.__wbindgen_add_to_stack_pointer(-16) >>> 0;
41
41
  wasm.yolomodel_device(retptr, this.__wbg_ptr);
42
42
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
43
43
  var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
@@ -46,7 +46,7 @@ export class YoloModel {
46
46
  return getStringFromWasm0(r0, r1);
47
47
  } finally {
48
48
  wasm.__wbindgen_add_to_stack_pointer(16);
49
- wasm.__wbindgen_export4(deferred1_0, deferred1_1, 1);
49
+ wasm.__wbindgen_export3(deferred1_0, deferred1_1, 1);
50
50
  }
51
51
  }
52
52
  /**
@@ -64,20 +64,28 @@ export class YoloModel {
64
64
  * # Errors
65
65
  * Returns a JS error if the backend cannot start, the bytes are not a valid
66
66
  * model, or the model lacks Ultralytics metadata.
67
- * @param {Uint8Array} bytes
67
+ * @param {Uint8Array | number[]} bytes
68
68
  * @param {string | null | undefined} ort_base_url
69
69
  * @param {string} device
70
70
  * @returns {Promise<YoloModel>}
71
71
  */
72
72
  static load_bytes(bytes, ort_base_url, device) {
73
- const ptr0 = passArray8ToWasm0(bytes, wasm.__wbindgen_export);
74
- const len0 = WASM_VECTOR_LEN;
75
- var ptr1 = isLikeNone(ort_base_url) ? 0 : passStringToWasm0(ort_base_url, wasm.__wbindgen_export, wasm.__wbindgen_export2);
76
- var len1 = WASM_VECTOR_LEN;
77
- const ptr2 = passStringToWasm0(device, wasm.__wbindgen_export, wasm.__wbindgen_export2);
78
- const len2 = WASM_VECTOR_LEN;
73
+ let ptr0, len0, ptr1, len1, ptr2, len2;
74
+ try {
75
+ ptr0 = passArray8ToWasm0(bytes, wasm.__wbindgen_export);
76
+ len0 = WASM_VECTOR_LEN;
77
+ ptr1 = isLikeNone(ort_base_url) ? 0 : passStringToWasm0(ort_base_url, wasm.__wbindgen_export, wasm.__wbindgen_export2);
78
+ len1 = WASM_VECTOR_LEN;
79
+ ptr2 = passStringToWasm0(device, wasm.__wbindgen_export, wasm.__wbindgen_export2);
80
+ len2 = WASM_VECTOR_LEN;
81
+ } catch (e) {
82
+ if (ptr2) { wasm.__wbindgen_export3(ptr2, len2 * 1, 1); }
83
+ if (ptr1) { wasm.__wbindgen_export3(ptr1, len1 * 1, 1); }
84
+ if (ptr0) { wasm.__wbindgen_export3(ptr0, len0 * 1, 1); }
85
+ throw e;
86
+ }
79
87
  const ret = wasm.yolomodel_load_bytes(ptr0, len0, ptr1, len1, ptr2, len2);
80
- return takeObject(ret);
88
+ return ret;
81
89
  }
82
90
  /**
83
91
  * Class id -> name map (like Ultralytics `model.names`), as a JS object.
@@ -88,15 +96,15 @@ export class YoloModel {
88
96
  */
89
97
  get names() {
90
98
  try {
91
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
99
+ const retptr = wasm.__wbindgen_add_to_stack_pointer(-16) >>> 0;
92
100
  wasm.yolomodel_names(retptr, this.__wbg_ptr);
93
101
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
94
102
  var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
95
103
  var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
96
104
  if (r2) {
97
- throw takeObject(r1);
105
+ throw takeFromExternrefTable0(r1);
98
106
  }
99
- return takeObject(r0);
107
+ return takeFromExternrefTable0(r0);
100
108
  } finally {
101
109
  wasm.__wbindgen_add_to_stack_pointer(16);
102
110
  }
@@ -114,28 +122,40 @@ export class YoloModel {
114
122
  * # Errors
115
123
  * Returns a JS error if the image cannot be decoded, the tracker is unknown or
116
124
  * inference fails.
117
- * @param {Uint8Array} image
125
+ * @param {Uint8Array | number[]} image
118
126
  * @param {number | null | undefined} conf
119
127
  * @param {number | null | undefined} iou
120
- * @param {Uint32Array | null | undefined} classes
128
+ * @param {Uint32Array | number[] | null | undefined} classes
121
129
  * @param {string} colormap
122
130
  * @param {string} depth_viz
123
131
  * @param {string | null} [tracker]
124
132
  * @returns {Promise<any>}
125
133
  */
126
134
  predict(image, conf, iou, classes, colormap, depth_viz, tracker) {
127
- const ptr0 = passArray8ToWasm0(image, wasm.__wbindgen_export);
128
- const len0 = WASM_VECTOR_LEN;
129
- var ptr1 = isLikeNone(classes) ? 0 : passArray32ToWasm0(classes, wasm.__wbindgen_export);
130
- var len1 = WASM_VECTOR_LEN;
131
- const ptr2 = passStringToWasm0(colormap, wasm.__wbindgen_export, wasm.__wbindgen_export2);
132
- const len2 = WASM_VECTOR_LEN;
133
- const ptr3 = passStringToWasm0(depth_viz, wasm.__wbindgen_export, wasm.__wbindgen_export2);
134
- const len3 = WASM_VECTOR_LEN;
135
- var ptr4 = isLikeNone(tracker) ? 0 : passStringToWasm0(tracker, wasm.__wbindgen_export, wasm.__wbindgen_export2);
136
- var len4 = WASM_VECTOR_LEN;
137
- const ret = wasm.yolomodel_predict(this.__wbg_ptr, ptr0, len0, isLikeNone(conf) ? Number.MAX_SAFE_INTEGER : Math.fround(conf), isLikeNone(iou) ? Number.MAX_SAFE_INTEGER : Math.fround(iou), ptr1, len1, ptr2, len2, ptr3, len3, ptr4, len4);
138
- return takeObject(ret);
135
+ const val6 = +(isLikeNone(conf) ? Number.MAX_SAFE_INTEGER : Math.fround(conf));
136
+ const val7 = +(isLikeNone(iou) ? Number.MAX_SAFE_INTEGER : Math.fround(iou));
137
+ let ptr0, len0, ptr1, len1, ptr2, len2, ptr3, len3, ptr4, len4;
138
+ try {
139
+ ptr0 = passArray8ToWasm0(image, wasm.__wbindgen_export);
140
+ len0 = WASM_VECTOR_LEN;
141
+ ptr1 = isLikeNone(classes) ? 0 : passArray32ToWasm0(classes, wasm.__wbindgen_export);
142
+ len1 = WASM_VECTOR_LEN;
143
+ ptr2 = passStringToWasm0(colormap, wasm.__wbindgen_export, wasm.__wbindgen_export2);
144
+ len2 = WASM_VECTOR_LEN;
145
+ ptr3 = passStringToWasm0(depth_viz, wasm.__wbindgen_export, wasm.__wbindgen_export2);
146
+ len3 = WASM_VECTOR_LEN;
147
+ ptr4 = isLikeNone(tracker) ? 0 : passStringToWasm0(tracker, wasm.__wbindgen_export, wasm.__wbindgen_export2);
148
+ len4 = WASM_VECTOR_LEN;
149
+ } catch (e) {
150
+ if (ptr4) { wasm.__wbindgen_export3(ptr4, len4 * 1, 1); }
151
+ if (ptr3) { wasm.__wbindgen_export3(ptr3, len3 * 1, 1); }
152
+ if (ptr2) { wasm.__wbindgen_export3(ptr2, len2 * 1, 1); }
153
+ if (ptr1) { wasm.__wbindgen_export3(ptr1, len1 * 4, 4); }
154
+ if (ptr0) { wasm.__wbindgen_export3(ptr0, len0 * 1, 1); }
155
+ throw e;
156
+ }
157
+ const ret = wasm.yolomodel_predict(this.__wbg_ptr, ptr0, len0, val6, val7, ptr1, len1, ptr2, len2, ptr3, len3, ptr4, len4);
158
+ return ret;
139
159
  }
140
160
  /**
141
161
  * Run inference on raw `RGBA` pixels (e.g. a canvas/webcam `ImageData`).
@@ -145,30 +165,44 @@ export class YoloModel {
145
165
  *
146
166
  * # Errors
147
167
  * Returns a JS error if the buffer size is wrong or inference fails.
148
- * @param {Uint8Array} rgba
168
+ * @param {Uint8Array | number[]} rgba
149
169
  * @param {number} width
150
170
  * @param {number} height
151
171
  * @param {number | null | undefined} conf
152
172
  * @param {number | null | undefined} iou
153
- * @param {Uint32Array | null | undefined} classes
173
+ * @param {Uint32Array | number[] | null | undefined} classes
154
174
  * @param {string} colormap
155
175
  * @param {string} depth_viz
156
176
  * @param {string | null} [tracker]
157
177
  * @returns {Promise<any>}
158
178
  */
159
179
  predict_rgba(rgba, width, height, conf, iou, classes, colormap, depth_viz, tracker) {
160
- const ptr0 = passArray8ToWasm0(rgba, wasm.__wbindgen_export);
161
- const len0 = WASM_VECTOR_LEN;
162
- var ptr1 = isLikeNone(classes) ? 0 : passArray32ToWasm0(classes, wasm.__wbindgen_export);
163
- var len1 = WASM_VECTOR_LEN;
164
- const ptr2 = passStringToWasm0(colormap, wasm.__wbindgen_export, wasm.__wbindgen_export2);
165
- const len2 = WASM_VECTOR_LEN;
166
- const ptr3 = passStringToWasm0(depth_viz, wasm.__wbindgen_export, wasm.__wbindgen_export2);
167
- const len3 = WASM_VECTOR_LEN;
168
- var ptr4 = isLikeNone(tracker) ? 0 : passStringToWasm0(tracker, wasm.__wbindgen_export, wasm.__wbindgen_export2);
169
- var len4 = WASM_VECTOR_LEN;
170
- const ret = wasm.yolomodel_predict_rgba(this.__wbg_ptr, ptr0, len0, width, height, isLikeNone(conf) ? Number.MAX_SAFE_INTEGER : Math.fround(conf), isLikeNone(iou) ? Number.MAX_SAFE_INTEGER : Math.fround(iou), ptr1, len1, ptr2, len2, ptr3, len3, ptr4, len4);
171
- return takeObject(ret);
180
+ const val6 = +width;
181
+ const val7 = +height;
182
+ const val8 = +(isLikeNone(conf) ? Number.MAX_SAFE_INTEGER : Math.fround(conf));
183
+ const val9 = +(isLikeNone(iou) ? Number.MAX_SAFE_INTEGER : Math.fround(iou));
184
+ let ptr0, len0, ptr1, len1, ptr2, len2, ptr3, len3, ptr4, len4;
185
+ try {
186
+ ptr0 = passArray8ToWasm0(rgba, wasm.__wbindgen_export);
187
+ len0 = WASM_VECTOR_LEN;
188
+ ptr1 = isLikeNone(classes) ? 0 : passArray32ToWasm0(classes, wasm.__wbindgen_export);
189
+ len1 = WASM_VECTOR_LEN;
190
+ ptr2 = passStringToWasm0(colormap, wasm.__wbindgen_export, wasm.__wbindgen_export2);
191
+ len2 = WASM_VECTOR_LEN;
192
+ ptr3 = passStringToWasm0(depth_viz, wasm.__wbindgen_export, wasm.__wbindgen_export2);
193
+ len3 = WASM_VECTOR_LEN;
194
+ ptr4 = isLikeNone(tracker) ? 0 : passStringToWasm0(tracker, wasm.__wbindgen_export, wasm.__wbindgen_export2);
195
+ len4 = WASM_VECTOR_LEN;
196
+ } catch (e) {
197
+ if (ptr4) { wasm.__wbindgen_export3(ptr4, len4 * 1, 1); }
198
+ if (ptr3) { wasm.__wbindgen_export3(ptr3, len3 * 1, 1); }
199
+ if (ptr2) { wasm.__wbindgen_export3(ptr2, len2 * 1, 1); }
200
+ if (ptr1) { wasm.__wbindgen_export3(ptr1, len1 * 4, 4); }
201
+ if (ptr0) { wasm.__wbindgen_export3(ptr0, len0 * 1, 1); }
202
+ throw e;
203
+ }
204
+ const ret = wasm.yolomodel_predict_rgba(this.__wbg_ptr, ptr0, len0, val6, val7, val8, val9, ptr1, len1, ptr2, len2, ptr3, len3, ptr4, len4);
205
+ return ret;
172
206
  }
173
207
  /**
174
208
  * Forget the tracks, so the next frame starts a new video.
@@ -185,7 +219,7 @@ export class YoloModel {
185
219
  let deferred1_0;
186
220
  let deferred1_1;
187
221
  try {
188
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
222
+ const retptr = wasm.__wbindgen_add_to_stack_pointer(-16) >>> 0;
189
223
  wasm.yolomodel_task(retptr, this.__wbg_ptr);
190
224
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
191
225
  var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
@@ -194,7 +228,7 @@ export class YoloModel {
194
228
  return getStringFromWasm0(r0, r1);
195
229
  } finally {
196
230
  wasm.__wbindgen_add_to_stack_pointer(16);
197
- wasm.__wbindgen_export4(deferred1_0, deferred1_1, 1);
231
+ wasm.__wbindgen_export3(deferred1_0, deferred1_1, 1);
198
232
  }
199
233
  }
200
234
  }
@@ -230,12 +264,12 @@ export class YoloPipeline {
230
264
  */
231
265
  get inputShape() {
232
266
  try {
233
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
267
+ const retptr = wasm.__wbindgen_add_to_stack_pointer(-16) >>> 0;
234
268
  wasm.yolopipeline_inputShape(retptr, this.__wbg_ptr);
235
269
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
236
270
  var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
237
271
  var v1 = getArrayU32FromWasm0(r0, r1).slice();
238
- wasm.__wbindgen_export4(r0, r1 * 4, 4);
272
+ wasm.__wbindgen_export3(r0, r1 * 4, 4);
239
273
  return v1;
240
274
  } finally {
241
275
  wasm.__wbindgen_add_to_stack_pointer(16);
@@ -250,15 +284,15 @@ export class YoloPipeline {
250
284
  */
251
285
  get names() {
252
286
  try {
253
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
287
+ const retptr = wasm.__wbindgen_add_to_stack_pointer(-16) >>> 0;
254
288
  wasm.yolopipeline_names(retptr, this.__wbg_ptr);
255
289
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
256
290
  var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
257
291
  var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
258
292
  if (r2) {
259
- throw takeObject(r1);
293
+ throw takeFromExternrefTable0(r1);
260
294
  }
261
- return takeObject(r0);
295
+ return takeFromExternrefTable0(r0);
262
296
  } finally {
263
297
  wasm.__wbindgen_add_to_stack_pointer(16);
264
298
  }
@@ -272,11 +306,11 @@ export class YoloPipeline {
272
306
  * # Errors
273
307
  * Returns a JS error if the model carries no Ultralytics metadata or it
274
308
  * cannot be parsed.
275
- * @param {Uint8Array} tflite
309
+ * @param {Uint8Array | number[]} tflite
276
310
  */
277
311
  constructor(tflite) {
278
312
  try {
279
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
313
+ const retptr = wasm.__wbindgen_add_to_stack_pointer(-16) >>> 0;
280
314
  const ptr0 = passArray8ToWasm0(tflite, wasm.__wbindgen_export);
281
315
  const len0 = WASM_VECTOR_LEN;
282
316
  wasm.yolopipeline_new(retptr, ptr0, len0);
@@ -284,7 +318,7 @@ export class YoloPipeline {
284
318
  var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
285
319
  var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
286
320
  if (r2) {
287
- throw takeObject(r1);
321
+ throw takeFromExternrefTable0(r1);
288
322
  }
289
323
  this.__wbg_ptr = r0;
290
324
  YoloPipelineFinalization.register(this, this.__wbg_ptr, this);
@@ -312,7 +346,7 @@ export class YoloPipeline {
312
346
  * @param {number} inference_ms
313
347
  * @param {number | null | undefined} conf
314
348
  * @param {number | null | undefined} iou
315
- * @param {Uint32Array | null | undefined} classes
349
+ * @param {Uint32Array | number[] | null | undefined} classes
316
350
  * @param {string} colormap
317
351
  * @param {string} depth_viz
318
352
  * @param {string | null} [tracker]
@@ -320,27 +354,41 @@ export class YoloPipeline {
320
354
  */
321
355
  postprocess(outputs, shapes, inference_ms, conf, iou, classes, colormap, depth_viz, tracker) {
322
356
  try {
323
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
324
- const ptr0 = passArrayJsValueToWasm0(outputs, wasm.__wbindgen_export);
325
- const len0 = WASM_VECTOR_LEN;
326
- const ptr1 = passArrayJsValueToWasm0(shapes, wasm.__wbindgen_export);
327
- const len1 = WASM_VECTOR_LEN;
328
- var ptr2 = isLikeNone(classes) ? 0 : passArray32ToWasm0(classes, wasm.__wbindgen_export);
329
- var len2 = WASM_VECTOR_LEN;
330
- const ptr3 = passStringToWasm0(colormap, wasm.__wbindgen_export, wasm.__wbindgen_export2);
331
- const len3 = WASM_VECTOR_LEN;
332
- const ptr4 = passStringToWasm0(depth_viz, wasm.__wbindgen_export, wasm.__wbindgen_export2);
333
- const len4 = WASM_VECTOR_LEN;
334
- var ptr5 = isLikeNone(tracker) ? 0 : passStringToWasm0(tracker, wasm.__wbindgen_export, wasm.__wbindgen_export2);
335
- var len5 = WASM_VECTOR_LEN;
336
- wasm.yolopipeline_postprocess(retptr, this.__wbg_ptr, ptr0, len0, ptr1, len1, inference_ms, isLikeNone(conf) ? Number.MAX_SAFE_INTEGER : Math.fround(conf), isLikeNone(iou) ? Number.MAX_SAFE_INTEGER : Math.fround(iou), ptr2, len2, ptr3, len3, ptr4, len4, ptr5, len5);
357
+ const retptr = wasm.__wbindgen_add_to_stack_pointer(-16) >>> 0;
358
+ const val7 = +inference_ms;
359
+ const val8 = +(isLikeNone(conf) ? Number.MAX_SAFE_INTEGER : Math.fround(conf));
360
+ const val9 = +(isLikeNone(iou) ? Number.MAX_SAFE_INTEGER : Math.fround(iou));
361
+ let ptr0, len0, ptr1, len1, ptr2, len2, ptr3, len3, ptr4, len4, ptr5, len5;
362
+ try {
363
+ ptr0 = passArrayJsValueToWasm0(outputs, wasm.__wbindgen_export);
364
+ len0 = WASM_VECTOR_LEN;
365
+ ptr1 = passArrayJsValueToWasm0(shapes, wasm.__wbindgen_export);
366
+ len1 = WASM_VECTOR_LEN;
367
+ ptr2 = isLikeNone(classes) ? 0 : passArray32ToWasm0(classes, wasm.__wbindgen_export);
368
+ len2 = WASM_VECTOR_LEN;
369
+ ptr3 = passStringToWasm0(colormap, wasm.__wbindgen_export, wasm.__wbindgen_export2);
370
+ len3 = WASM_VECTOR_LEN;
371
+ ptr4 = passStringToWasm0(depth_viz, wasm.__wbindgen_export, wasm.__wbindgen_export2);
372
+ len4 = WASM_VECTOR_LEN;
373
+ ptr5 = isLikeNone(tracker) ? 0 : passStringToWasm0(tracker, wasm.__wbindgen_export, wasm.__wbindgen_export2);
374
+ len5 = WASM_VECTOR_LEN;
375
+ } catch (e) {
376
+ if (ptr5) { wasm.__wbindgen_export3(ptr5, len5 * 1, 1); }
377
+ if (ptr4) { wasm.__wbindgen_export3(ptr4, len4 * 1, 1); }
378
+ if (ptr3) { wasm.__wbindgen_export3(ptr3, len3 * 1, 1); }
379
+ if (ptr2) { wasm.__wbindgen_export3(ptr2, len2 * 4, 4); }
380
+ if (ptr1) { wasm.__wbindgen_export6(ptr1, len1); wasm.__wbindgen_export3(ptr1, len1 * 4, 4); }
381
+ if (ptr0) { wasm.__wbindgen_export6(ptr0, len0); wasm.__wbindgen_export3(ptr0, len0 * 4, 4); }
382
+ throw e;
383
+ }
384
+ wasm.yolopipeline_postprocess(retptr, this.__wbg_ptr, ptr0, len0, ptr1, len1, val7, val8, val9, ptr2, len2, ptr3, len3, ptr4, len4, ptr5, len5);
337
385
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
338
386
  var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
339
387
  var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
340
388
  if (r2) {
341
- throw takeObject(r1);
389
+ throw takeFromExternrefTable0(r1);
342
390
  }
343
- return takeObject(r0);
391
+ return takeFromExternrefTable0(r0);
344
392
  } finally {
345
393
  wasm.__wbindgen_add_to_stack_pointer(16);
346
394
  }
@@ -356,24 +404,26 @@ export class YoloPipeline {
356
404
  *
357
405
  * # Errors
358
406
  * Returns a JS error if the buffer size is not `width * height * 4`.
359
- * @param {Uint8Array} rgba
407
+ * @param {Uint8Array | number[]} rgba
360
408
  * @param {number} width
361
409
  * @param {number} height
362
410
  * @returns {Float32Array}
363
411
  */
364
412
  preprocess_rgba(rgba, width, height) {
365
413
  try {
366
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
414
+ const retptr = wasm.__wbindgen_add_to_stack_pointer(-16) >>> 0;
415
+ const val2 = +width;
416
+ const val3 = +height;
367
417
  const ptr0 = passArray8ToWasm0(rgba, wasm.__wbindgen_export);
368
418
  const len0 = WASM_VECTOR_LEN;
369
- wasm.yolopipeline_preprocess_rgba(retptr, this.__wbg_ptr, ptr0, len0, width, height);
419
+ wasm.yolopipeline_preprocess_rgba(retptr, this.__wbg_ptr, ptr0, len0, val2, val3);
370
420
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
371
421
  var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
372
422
  var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
373
423
  if (r2) {
374
- throw takeObject(r1);
424
+ throw takeFromExternrefTable0(r1);
375
425
  }
376
- return takeObject(r0);
426
+ return takeFromExternrefTable0(r0);
377
427
  } finally {
378
428
  wasm.__wbindgen_add_to_stack_pointer(16);
379
429
  }
@@ -397,7 +447,7 @@ export class YoloPipeline {
397
447
  * the engine reports. Any other rank or layout (a channels-last `[N, H, W, 3]`) and any
398
448
  * non-positive axis, which is how a dynamic dimension is reported, is ignored and leaves
399
449
  * the metadata size in place.
400
- * @param {Int32Array} shape
450
+ * @param {Int32Array | number[]} shape
401
451
  */
402
452
  setInputShape(shape) {
403
453
  const ptr0 = passArray32ToWasm0(shape, wasm.__wbindgen_export);
@@ -412,7 +462,7 @@ export class YoloPipeline {
412
462
  let deferred1_0;
413
463
  let deferred1_1;
414
464
  try {
415
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
465
+ const retptr = wasm.__wbindgen_add_to_stack_pointer(-16) >>> 0;
416
466
  wasm.yolopipeline_task(retptr, this.__wbg_ptr);
417
467
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
418
468
  var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
@@ -421,7 +471,7 @@ export class YoloPipeline {
421
471
  return getStringFromWasm0(r0, r1);
422
472
  } finally {
423
473
  wasm.__wbindgen_add_to_stack_pointer(16);
424
- wasm.__wbindgen_export4(deferred1_0, deferred1_1, 1);
474
+ wasm.__wbindgen_export3(deferred1_0, deferred1_1, 1);
425
475
  }
426
476
  }
427
477
  }
@@ -438,14 +488,14 @@ if (Symbol.dispose) YoloPipeline.prototype[Symbol.dispose] = YoloPipeline.protot
438
488
  */
439
489
  export function bidi_runs(text) {
440
490
  try {
441
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
491
+ const retptr = wasm.__wbindgen_add_to_stack_pointer(-16) >>> 0;
442
492
  const ptr0 = passStringToWasm0(text, wasm.__wbindgen_export, wasm.__wbindgen_export2);
443
493
  const len0 = WASM_VECTOR_LEN;
444
494
  wasm.bidi_runs(retptr, ptr0, len0);
445
495
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
446
496
  var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
447
497
  var v2 = getArrayJsValueFromWasm0(r0, r1);
448
- wasm.__wbindgen_export4(r0, r1 * 4, 4);
498
+ wasm.__wbindgen_export3(r0, r1 * 4, 4);
449
499
  return v2;
450
500
  } finally {
451
501
  wasm.__wbindgen_add_to_stack_pointer(16);
@@ -462,15 +512,15 @@ export function bidi_runs(text) {
462
512
  */
463
513
  export function pose_palette() {
464
514
  try {
465
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
515
+ const retptr = wasm.__wbindgen_add_to_stack_pointer(-16) >>> 0;
466
516
  wasm.pose_palette(retptr);
467
517
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
468
518
  var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
469
519
  var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
470
520
  if (r2) {
471
- throw takeObject(r1);
521
+ throw takeFromExternrefTable0(r1);
472
522
  }
473
- return takeObject(r0);
523
+ return takeFromExternrefTable0(r0);
474
524
  } finally {
475
525
  wasm.__wbindgen_add_to_stack_pointer(16);
476
526
  }
@@ -485,137 +535,137 @@ export function start() {
485
535
  function __wbg_get_imports() {
486
536
  const import0 = {
487
537
  __proto__: null,
488
- __wbg_Error_30c8987f7c2ed4e2: function(arg0, arg1) {
538
+ __wbg_Error_208446807d0d1e30: function(arg0, arg1) {
489
539
  const ret = Error(getStringFromWasm0(arg0, arg1));
490
- return addHeapObject(ret);
540
+ return ret;
491
541
  },
492
542
  __wbg_String_8564e559799eccda: function(arg0, arg1) {
493
- const ret = String(getObject(arg1));
543
+ const ret = String(arg1);
494
544
  const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_export, wasm.__wbindgen_export2);
495
545
  const len1 = WASM_VECTOR_LEN;
496
- getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
497
- getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
546
+ getDataViewMemory0().setInt32((arg0 >>> 0) + 4 * 1, len1, true);
547
+ getDataViewMemory0().setInt32((arg0 >>> 0) + 4 * 0, ptr1, true);
498
548
  },
499
- __wbg___wbindgen_bigint_get_as_i64_a2383202b9353e4c: function(arg0, arg1) {
500
- const v = getObject(arg1);
549
+ __wbg___wbindgen_bigint_get_as_i64_11da4b52cd0aedef: function(arg0, arg1) {
550
+ const v = arg1;
501
551
  const ret = typeof(v) === 'bigint' ? v : undefined;
502
- getDataViewMemory0().setBigInt64(arg0 + 8 * 1, isLikeNone(ret) ? BigInt(0) : ret, true);
503
- getDataViewMemory0().setInt32(arg0 + 4 * 0, !isLikeNone(ret), true);
552
+ getDataViewMemory0().setBigInt64((arg0 >>> 0) + 8 * 1, isLikeNone(ret) ? BigInt(0) : ret, true);
553
+ getDataViewMemory0().setInt32((arg0 >>> 0) + 4 * 0, !isLikeNone(ret), true);
504
554
  },
505
- __wbg___wbindgen_boolean_get_5b446f51afd21013: function(arg0) {
506
- const v = getObject(arg0);
555
+ __wbg___wbindgen_boolean_get_4f1baf9a00be3c74: function(arg0) {
556
+ const v = arg0;
507
557
  const ret = typeof(v) === 'boolean' ? v : undefined;
508
558
  return isLikeNone(ret) ? 0xFFFFFF : ret ? 1 : 0;
509
559
  },
510
- __wbg___wbindgen_debug_string_4687d8d8c2017d52: function(arg0, arg1) {
511
- const ret = debugString(getObject(arg1));
560
+ __wbg___wbindgen_debug_string_f249a2a76caa9a55: function(arg0, arg1) {
561
+ const ret = debugString(arg1);
512
562
  const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_export, wasm.__wbindgen_export2);
513
563
  const len1 = WASM_VECTOR_LEN;
514
- getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
515
- getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
564
+ getDataViewMemory0().setInt32((arg0 >>> 0) + 4 * 1, len1, true);
565
+ getDataViewMemory0().setInt32((arg0 >>> 0) + 4 * 0, ptr1, true);
516
566
  },
517
- __wbg___wbindgen_in_92f62ee1427d9e49: function(arg0, arg1) {
518
- const ret = getObject(arg0) in getObject(arg1);
567
+ __wbg___wbindgen_in_3f58a9d3b3a7eed2: function(arg0, arg1) {
568
+ const ret = arg0 in arg1;
519
569
  return ret;
520
570
  },
521
- __wbg___wbindgen_is_bigint_b123553bed3bb382: function(arg0) {
522
- const ret = typeof(getObject(arg0)) === 'bigint';
571
+ __wbg___wbindgen_is_bigint_5fa10641e039d3ef: function(arg0) {
572
+ const ret = typeof(arg0) === 'bigint';
523
573
  return ret;
524
574
  },
525
- __wbg___wbindgen_is_function_1f9d30630b8b1d3d: function(arg0) {
526
- const ret = typeof(getObject(arg0)) === 'function';
575
+ __wbg___wbindgen_is_function_741ff2bb612836f5: function(arg0) {
576
+ const ret = typeof(arg0) === 'function';
527
577
  return ret;
528
578
  },
529
- __wbg___wbindgen_is_object_3c45d4f2dde4e749: function(arg0) {
530
- const val = getObject(arg0);
579
+ __wbg___wbindgen_is_object_8b968c3ab8e96595: function(arg0) {
580
+ const val = arg0;
531
581
  const ret = typeof(val) === 'object' && val !== null;
532
582
  return ret;
533
583
  },
534
- __wbg___wbindgen_is_string_90b56bc79aad6f6c: function(arg0) {
535
- const ret = typeof(getObject(arg0)) === 'string';
584
+ __wbg___wbindgen_is_string_fc456fee5d3317de: function(arg0) {
585
+ const ret = typeof(arg0) === 'string';
536
586
  return ret;
537
587
  },
538
- __wbg___wbindgen_is_undefined_8865fb403f8fe9d8: function(arg0) {
539
- const ret = getObject(arg0) === undefined;
588
+ __wbg___wbindgen_is_undefined_be5b34249ff1fc15: function(arg0) {
589
+ const ret = arg0 === undefined;
540
590
  return ret;
541
591
  },
542
- __wbg___wbindgen_jsval_eq_02babf21faa37971: function(arg0, arg1) {
543
- const ret = getObject(arg0) === getObject(arg1);
592
+ __wbg___wbindgen_jsval_eq_38d7bfbe4cc84039: function(arg0, arg1) {
593
+ const ret = arg0 === arg1;
544
594
  return ret;
545
595
  },
546
- __wbg___wbindgen_jsval_loose_eq_677f21e468d6b461: function(arg0, arg1) {
547
- const ret = getObject(arg0) == getObject(arg1);
596
+ __wbg___wbindgen_jsval_loose_eq_b2f214e2e4b30e36: function(arg0, arg1) {
597
+ const ret = arg0 == arg1;
548
598
  return ret;
549
599
  },
550
- __wbg___wbindgen_number_get_2e0e7dee9f701a71: function(arg0, arg1) {
551
- const obj = getObject(arg1);
600
+ __wbg___wbindgen_number_get_934b640d0889af78: function(arg0, arg1) {
601
+ const obj = arg1;
552
602
  const ret = typeof(obj) === 'number' ? obj : undefined;
553
- getDataViewMemory0().setFloat64(arg0 + 8 * 1, isLikeNone(ret) ? 0 : ret, true);
554
- getDataViewMemory0().setInt32(arg0 + 4 * 0, !isLikeNone(ret), true);
603
+ getDataViewMemory0().setFloat64((arg0 >>> 0) + 8 * 1, isLikeNone(ret) ? 0 : ret, true);
604
+ getDataViewMemory0().setInt32((arg0 >>> 0) + 4 * 0, !isLikeNone(ret), true);
555
605
  },
556
- __wbg___wbindgen_string_get_0380ccaa2f57f0d9: function(arg0, arg1) {
557
- const obj = getObject(arg1);
606
+ __wbg___wbindgen_string_get_7ce8eee7fd327545: function(arg0, arg1) {
607
+ const obj = arg1;
558
608
  const ret = typeof(obj) === 'string' ? obj : undefined;
559
609
  var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_export, wasm.__wbindgen_export2);
560
610
  var len1 = WASM_VECTOR_LEN;
561
- getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
562
- getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
611
+ getDataViewMemory0().setInt32((arg0 >>> 0) + 4 * 1, len1, true);
612
+ getDataViewMemory0().setInt32((arg0 >>> 0) + 4 * 0, ptr1, true);
563
613
  },
564
- __wbg___wbindgen_throw_41e9ee4f547fc59a: function(arg0, arg1) {
614
+ __wbg___wbindgen_throw_4c88d8bf264fd984: function(arg0, arg1) {
565
615
  throw new Error(getStringFromWasm0(arg0, arg1));
566
616
  },
567
- __wbg__wbg_cb_unref_dcc1a90847f04c41: function(arg0) {
568
- getObject(arg0)._wbg_cb_unref();
617
+ __wbg__wbg_cb_unref_09736879a3f67559: function(arg0) {
618
+ arg0._wbg_cb_unref();
569
619
  },
570
- __wbg_buffer_56ec2905a66f58b9: function(arg0) {
571
- const ret = getObject(arg0).buffer;
572
- return addHeapObject(ret);
620
+ __wbg_buffer_aca05a93c046db1a: function(arg0) {
621
+ const ret = arg0.buffer;
622
+ return ret;
573
623
  },
574
- __wbg_byteLength_9f985b8373f1f3fe: function(arg0) {
575
- const ret = getObject(arg0).byteLength;
624
+ __wbg_byteLength_c5f3c188d5252e5b: function(arg0) {
625
+ const ret = arg0.byteLength;
576
626
  return ret;
577
627
  },
578
- __wbg_byteOffset_0bd5a6a03553639c: function(arg0) {
579
- const ret = getObject(arg0).byteOffset;
628
+ __wbg_byteOffset_63cdc7b38f33a45e: function(arg0) {
629
+ const ret = arg0.byteOffset;
580
630
  return ret;
581
631
  },
582
- __wbg_call_187d372bd5fdd4aa: function() { return handleError(function (arg0, arg1, arg2) {
583
- const ret = getObject(arg0).call(getObject(arg1), getObject(arg2));
584
- return addHeapObject(ret);
632
+ __wbg_call_40b008ba32f73991: function() { return handleError(function (arg0, arg1) {
633
+ const ret = arg0.call(arg1);
634
+ return ret;
585
635
  }, arguments); },
586
- __wbg_call_6137034ef55c9d0f: function() { return handleError(function (arg0, arg1) {
587
- const ret = getObject(arg0).call(getObject(arg1));
588
- return addHeapObject(ret);
636
+ __wbg_call_a410eb4b59ed5965: function() { return handleError(function (arg0, arg1, arg2) {
637
+ const ret = arg0.call(arg1, arg2);
638
+ return ret;
589
639
  }, arguments); },
590
- __wbg_create_07db378e252080ec: function() { return handleError(function (arg0, arg1, arg2) {
591
- const ret = ort.InferenceSession.create(getStringFromWasm0(arg0, arg1), takeObject(arg2));
592
- return addHeapObject(ret);
640
+ __wbg_create_d7666802f5ae6eeb: function() { return handleError(function (arg0, arg1, arg2) {
641
+ const ret = ort.InferenceSession.create(getStringFromWasm0(arg0, arg1), arg2);
642
+ return ret;
593
643
  }, arguments); },
594
- __wbg_create_573b47018e76ad99: function() { return handleError(function (arg0, arg1) {
595
- const ret = ort.InferenceSession.create(getObject(arg0), takeObject(arg1));
596
- return addHeapObject(ret);
644
+ __wbg_create_dc710521629ee436: function() { return handleError(function (arg0, arg1) {
645
+ const ret = ort.InferenceSession.create(arg0, arg1);
646
+ return ret;
597
647
  }, arguments); },
598
- __wbg_data_e242aa3d2f3b3ce2: function() { return handleError(function (arg0) {
599
- const ret = getObject(arg0).data;
600
- return addHeapObject(ret);
648
+ __wbg_data_a24b5aaa619be2c9: function() { return handleError(function (arg0) {
649
+ const ret = arg0.data;
650
+ return ret;
601
651
  }, arguments); },
602
- __wbg_dims_b9c966d20c2a4d79: function(arg0, arg1) {
603
- const ret = getObject(arg1).dims;
652
+ __wbg_dims_7fd35ebcec0e468d: function(arg0, arg1) {
653
+ const ret = arg1.dims;
604
654
  const ptr1 = passArrayF64ToWasm0(ret, wasm.__wbindgen_export);
605
655
  const len1 = WASM_VECTOR_LEN;
606
- getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
607
- getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
656
+ getDataViewMemory0().setInt32((arg0 >>> 0) + 4 * 1, len1, true);
657
+ getDataViewMemory0().setInt32((arg0 >>> 0) + 4 * 0, ptr1, true);
608
658
  },
609
- __wbg_dispose_17a92fe091ac456b: function() { return handleError(function (arg0) {
610
- getObject(arg0).dispose();
659
+ __wbg_dispose_1c127b4bca3ac16f: function() { return handleError(function (arg0) {
660
+ arg0.dispose();
611
661
  }, arguments); },
612
- __wbg_done_b41a1d26cdb37fb6: function(arg0) {
613
- const ret = getObject(arg0).done;
662
+ __wbg_done_57e08d0be6e30c02: function(arg0) {
663
+ const ret = arg0.done;
614
664
  return ret;
615
665
  },
616
- __wbg_entries_fb6397112b1de25f: function(arg0) {
617
- const ret = Object.entries(getObject(arg0));
618
- return addHeapObject(ret);
666
+ __wbg_entries_7bb1459bd9b5c2b9: function(arg0) {
667
+ const ret = Object.entries(arg0);
668
+ return ret;
619
669
  },
620
670
  __wbg_error_757e9472f8410341: function(arg0, arg1) {
621
671
  let deferred0_0;
@@ -625,452 +675,453 @@ function __wbg_get_imports() {
625
675
  deferred0_1 = arg1;
626
676
  console.error(getStringFromWasm0(arg0, arg1));
627
677
  } finally {
628
- wasm.__wbindgen_export4(deferred0_0, deferred0_1, 1);
678
+ wasm.__wbindgen_export3(deferred0_0, deferred0_1, 1);
629
679
  }
630
680
  },
631
- __wbg_from_296ca31f8d0f1c52: function(arg0) {
632
- const ret = Array.from(getObject(arg0));
633
- return addHeapObject(ret);
681
+ __wbg_from_eac91875c8a5ffa4: function(arg0) {
682
+ const ret = Array.from(arg0);
683
+ return ret;
634
684
  },
635
- __wbg_getData_ae0be7023598e2c2: function() { return handleError(function (arg0) {
636
- const ret = getObject(arg0).getData();
637
- return addHeapObject(ret);
685
+ __wbg_getData_7affaf0601c8d174: function() { return handleError(function (arg0) {
686
+ const ret = arg0.getData();
687
+ return ret;
638
688
  }, arguments); },
639
- __wbg_get_31af05bd4842a84f: function() { return handleError(function (arg0, arg1) {
640
- const ret = Reflect.get(getObject(arg0), getObject(arg1));
641
- return addHeapObject(ret);
689
+ __wbg_get_2080c49015e35254: function() { return handleError(function (arg0, arg1) {
690
+ const ret = Reflect.get(arg0, arg1);
691
+ return ret;
642
692
  }, arguments); },
643
- __wbg_get_658f6698067d9515: function() { return handleError(function (arg0, arg1) {
644
- const ret = Reflect.get(getObject(arg0), getObject(arg1));
645
- return addHeapObject(ret);
693
+ __wbg_get_635eea311fa1a291: function() { return handleError(function (arg0, arg1) {
694
+ const ret = Reflect.get(arg0, arg1);
695
+ return ret;
646
696
  }, arguments); },
647
- __wbg_get_6c896e0571ddae51: function(arg0, arg1) {
648
- const ret = getObject(arg0)[arg1 >>> 0];
649
- return addHeapObject(ret);
697
+ __wbg_get_d7176cfb76d71114: function(arg0, arg1) {
698
+ const ret = arg0[arg1 >>> 0];
699
+ return ret;
650
700
  },
651
- __wbg_get_unchecked_288889d017702237: function(arg0, arg1) {
652
- const ret = getObject(arg0)[arg1 >>> 0];
653
- return addHeapObject(ret);
701
+ __wbg_get_unchecked_e6325ad374eff861: function(arg0, arg1) {
702
+ const ret = arg0[arg1 >>> 0];
703
+ return ret;
654
704
  },
655
- __wbg_get_with_ref_key_6412cf3094599694: function(arg0, arg1) {
656
- const ret = getObject(arg0)[getObject(arg1)];
657
- return addHeapObject(ret);
705
+ __wbg_get_with_ref_key_fc601247060b7204: function(arg0, arg1) {
706
+ const ret = arg0[arg1];
707
+ return ret;
658
708
  },
659
- __wbg_initRuntime_cfc81535b182a89a: function() { return handleError(function (arg0, arg1) {
660
- const ret = initRuntime(arg0, takeObject(arg1));
661
- return addHeapObject(ret);
709
+ __wbg_initRuntime_2d0128e21d688a1e: function() { return handleError(function (arg0, arg1) {
710
+ const ret = initRuntime(arg0, arg1);
711
+ return ret;
662
712
  }, arguments); },
663
- __wbg_inputMetadata_b0480cebe7a00667: function(arg0, arg1) {
664
- const ret = getObject(arg1).inputMetadata;
713
+ __wbg_inputMetadata_77b0d5a106ed1eab: function(arg0, arg1) {
714
+ const ret = arg1.inputMetadata;
665
715
  const ptr1 = passArrayJsValueToWasm0(ret, wasm.__wbindgen_export);
666
716
  const len1 = WASM_VECTOR_LEN;
667
- getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
668
- getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
717
+ getDataViewMemory0().setInt32((arg0 >>> 0) + 4 * 1, len1, true);
718
+ getDataViewMemory0().setInt32((arg0 >>> 0) + 4 * 0, ptr1, true);
669
719
  },
670
- __wbg_inputNames_2897599e914f9792: function(arg0, arg1) {
671
- const ret = getObject(arg1).inputNames;
720
+ __wbg_inputNames_8f4c4f6fe930f9c3: function(arg0, arg1) {
721
+ const ret = arg1.inputNames;
672
722
  const ptr1 = passArrayJsValueToWasm0(ret, wasm.__wbindgen_export);
673
723
  const len1 = WASM_VECTOR_LEN;
674
- getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
675
- getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
724
+ getDataViewMemory0().setInt32((arg0 >>> 0) + 4 * 1, len1, true);
725
+ getDataViewMemory0().setInt32((arg0 >>> 0) + 4 * 0, ptr1, true);
676
726
  },
677
- __wbg_instanceof_ArrayBuffer_a99f175873e5d9b8: function(arg0) {
727
+ __wbg_instanceof_ArrayBuffer_12cdaa4161423e6b: function(arg0) {
678
728
  let result;
679
729
  try {
680
- result = getObject(arg0) instanceof ArrayBuffer;
730
+ result = arg0 instanceof ArrayBuffer;
681
731
  } catch (_) {
682
732
  result = false;
683
733
  }
684
734
  const ret = result;
685
735
  return ret;
686
736
  },
687
- __wbg_instanceof_Map_b2611749102d7ba3: function(arg0) {
737
+ __wbg_instanceof_Map_0b4fc8b62e73f163: function(arg0) {
688
738
  let result;
689
739
  try {
690
- result = getObject(arg0) instanceof Map;
740
+ result = arg0 instanceof Map;
691
741
  } catch (_) {
692
742
  result = false;
693
743
  }
694
744
  const ret = result;
695
745
  return ret;
696
746
  },
697
- __wbg_instanceof_Performance_cbec0dbedaa91be1: function(arg0) {
747
+ __wbg_instanceof_Performance_2b9444a94b6a603f: function(arg0) {
698
748
  let result;
699
749
  try {
700
- result = getObject(arg0) instanceof Performance;
750
+ result = arg0 instanceof Performance;
701
751
  } catch (_) {
702
752
  result = false;
703
753
  }
704
754
  const ret = result;
705
755
  return ret;
706
756
  },
707
- __wbg_instanceof_Uint8Array_828cef2aaacafc31: function(arg0) {
757
+ __wbg_instanceof_Uint8Array_d7aeb0dcb3108fea: function(arg0) {
708
758
  let result;
709
759
  try {
710
- result = getObject(arg0) instanceof Uint8Array;
760
+ result = arg0 instanceof Uint8Array;
711
761
  } catch (_) {
712
762
  result = false;
713
763
  }
714
764
  const ret = result;
715
765
  return ret;
716
766
  },
717
- __wbg_isArray_e15a2ff68ffdbef2: function(arg0) {
718
- const ret = Array.isArray(getObject(arg0));
767
+ __wbg_isArray_bcf1376d0d732d08: function(arg0) {
768
+ const ret = Array.isArray(arg0);
719
769
  return ret;
720
770
  },
721
- __wbg_isSafeInteger_717808ad6a54bd9e: function(arg0) {
722
- const ret = Number.isSafeInteger(getObject(arg0));
771
+ __wbg_isSafeInteger_1a35ba4d31e71d38: function(arg0) {
772
+ const ret = Number.isSafeInteger(arg0);
723
773
  return ret;
724
774
  },
725
- __wbg_iterator_e3c31c892080e444: function() {
775
+ __wbg_iterator_e4c5e8f68ada7b58: function() {
726
776
  const ret = Symbol.iterator;
727
- return addHeapObject(ret);
777
+ return ret;
728
778
  },
729
- __wbg_length_511b1f84719d3462: function(arg0) {
730
- const ret = getObject(arg0).length;
779
+ __wbg_length_186163212ffe79c3: function(arg0) {
780
+ const ret = arg0.length;
731
781
  return ret;
732
782
  },
733
- __wbg_length_58572db4c38f3c3e: function(arg0) {
734
- const ret = getObject(arg0).length;
783
+ __wbg_length_6e9d2869242cabf3: function(arg0) {
784
+ const ret = arg0.length;
735
785
  return ret;
736
786
  },
737
- __wbg_length_7f3c00c40364105e: function(arg0) {
738
- const ret = getObject(arg0).length;
787
+ __wbg_length_b03a0fabb109b1e9: function(arg0) {
788
+ const ret = arg0.length;
739
789
  return ret;
740
790
  },
741
- __wbg_length_d4bdea10311bd9cf: function(arg0) {
742
- const ret = getObject(arg0).length;
791
+ __wbg_length_c702d06d28b96b72: function(arg0) {
792
+ const ret = arg0.length;
743
793
  return ret;
744
794
  },
745
- __wbg_location_02e5bf0e6b80a0f5: function(arg0) {
746
- const ret = getObject(arg0).location;
795
+ __wbg_location_c11d259837414607: function(arg0) {
796
+ const ret = arg0.location;
747
797
  return (__wbindgen_enum_DataLocation.indexOf(ret) + 1 || 7) - 1;
748
798
  },
749
- __wbg_message_5f8387f0c32b90a7: function(arg0) {
750
- const ret = getObject(arg0).message;
751
- return addHeapObject(ret);
799
+ __wbg_message_43d8c8f1d543a349: function(arg0) {
800
+ const ret = arg0.message;
801
+ return ret;
752
802
  },
753
- __wbg_new_1dbf7428bba60a42: function(arg0) {
754
- const ret = new Uint8Array(getObject(arg0));
755
- return addHeapObject(ret);
803
+ __wbg_new_13de428334042d26: function(arg0) {
804
+ const ret = new Uint8Array(arg0);
805
+ return ret;
756
806
  },
757
- __wbg_new_227d7c05414eb861: function() {
758
- const ret = new Error();
759
- return addHeapObject(ret);
807
+ __wbg_new_37eb45aaf5eeb820: function() {
808
+ const ret = new Array();
809
+ return ret;
760
810
  },
761
- __wbg_new_28744009d011f847: function() {
811
+ __wbg_new_7075786089b89c5e: function() {
762
812
  const ret = new Map();
763
- return addHeapObject(ret);
813
+ return ret;
764
814
  },
765
- __wbg_new_617a8cdb8bb1130e: function() {
766
- const ret = new Object();
767
- return addHeapObject(ret);
815
+ __wbg_new_bb74001155cb8ca8: function() {
816
+ const ret = new Error();
817
+ return ret;
768
818
  },
769
- __wbg_new_ee2291f50781bf1d: function() {
770
- const ret = new Array();
771
- return addHeapObject(ret);
819
+ __wbg_new_cd4348290afae586: function() {
820
+ const ret = new Object();
821
+ return ret;
772
822
  },
773
- __wbg_new_from_buffer_raw_eb33cdffdf32a27b: function() { return handleError(function (arg0, arg1, arg2) {
774
- const ret = new ort.Tensor(__wbindgen_enum_DataType[arg0], takeObject(arg1), takeObject(arg2));
775
- return addHeapObject(ret);
823
+ __wbg_new_from_buffer_raw_965a1e692b3f72c1: function() { return handleError(function (arg0, arg1, arg2) {
824
+ const ret = new ort.Tensor(__wbindgen_enum_DataType[arg0], arg1, arg2);
825
+ return ret;
776
826
  }, arguments); },
777
- __wbg_new_from_slice_9a868026ffa4208a: function(arg0, arg1) {
778
- const ret = new Uint8Array(getArrayU8FromWasm0(arg0, arg1));
779
- return addHeapObject(ret);
780
- },
781
- __wbg_new_from_slice_ca6ad97db1f4779a: function(arg0, arg1) {
827
+ __wbg_new_from_slice_355c10c5d8f2addb: function(arg0, arg1) {
782
828
  const ret = new Float32Array(getArrayF32FromWasm0(arg0, arg1));
783
- return addHeapObject(ret);
829
+ return ret;
784
830
  },
785
- __wbg_new_typed_b01cb72a8af741a3: function(arg0, arg1) {
831
+ __wbg_new_from_slice_b8daf545a41c6aa0: function(arg0, arg1) {
832
+ const ret = new Uint8Array(getArrayU8FromWasm0(arg0, arg1));
833
+ return ret;
834
+ },
835
+ __wbg_new_typed_e09da9dae6ee5935: function(arg0, arg1) {
786
836
  try {
787
837
  var state0 = {a: arg0, b: arg1};
788
838
  var cb0 = (arg0, arg1) => {
789
839
  const a = state0.a;
790
840
  state0.a = 0;
791
841
  try {
792
- return __wasm_bindgen_func_elem_1975(a, state0.b, arg0, arg1);
842
+ return __wasm_bindgen_func_elem_1996(a, state0.b, arg0, arg1);
793
843
  } finally {
794
844
  state0.a = a;
795
845
  }
796
846
  };
797
847
  const ret = new Promise(cb0);
798
- return addHeapObject(ret);
848
+ return ret;
799
849
  } finally {
800
850
  state0.a = 0;
801
851
  }
802
852
  },
803
- __wbg_new_with_byte_offset_and_length_1dc9f6fbbe046da6: function(arg0, arg1, arg2) {
804
- const ret = new Uint16Array(getObject(arg0), arg1 >>> 0, arg2 >>> 0);
805
- return addHeapObject(ret);
853
+ __wbg_new_with_byte_offset_and_length_0ed64ba86fd30b62: function(arg0, arg1, arg2) {
854
+ const ret = new BigInt64Array(arg0, arg1 >>> 0, arg2 >>> 0);
855
+ return ret;
806
856
  },
807
- __wbg_new_with_byte_offset_and_length_2f5d7fc2a828b74d: function(arg0, arg1, arg2) {
808
- const ret = new Uint8Array(getObject(arg0), arg1 >>> 0, arg2 >>> 0);
809
- return addHeapObject(ret);
857
+ __wbg_new_with_byte_offset_and_length_1ea36b9f0c3bc55a: function(arg0, arg1, arg2) {
858
+ const ret = new Float32Array(arg0, arg1 >>> 0, arg2 >>> 0);
859
+ return ret;
810
860
  },
811
- __wbg_new_with_byte_offset_and_length_40c170286adc9005: function(arg0, arg1, arg2) {
812
- const ret = new Float32Array(getObject(arg0), arg1 >>> 0, arg2 >>> 0);
813
- return addHeapObject(ret);
861
+ __wbg_new_with_byte_offset_and_length_2d2fa37a22f87186: function(arg0, arg1, arg2) {
862
+ const ret = new Uint32Array(arg0, arg1 >>> 0, arg2 >>> 0);
863
+ return ret;
814
864
  },
815
- __wbg_new_with_byte_offset_and_length_6e8c68600a3ecb84: function(arg0, arg1, arg2) {
816
- const ret = new BigUint64Array(getObject(arg0), arg1 >>> 0, arg2 >>> 0);
817
- return addHeapObject(ret);
865
+ __wbg_new_with_byte_offset_and_length_3cd32055a417f095: function(arg0, arg1, arg2) {
866
+ const ret = new Uint8Array(arg0, arg1 >>> 0, arg2 >>> 0);
867
+ return ret;
818
868
  },
819
- __wbg_new_with_byte_offset_and_length_820ea3ecbd1a4828: function(arg0, arg1, arg2) {
820
- const ret = new Int16Array(getObject(arg0), arg1 >>> 0, arg2 >>> 0);
821
- return addHeapObject(ret);
869
+ __wbg_new_with_byte_offset_and_length_48227b70d0579fd3: function(arg0, arg1, arg2) {
870
+ const ret = new Int8Array(arg0, arg1 >>> 0, arg2 >>> 0);
871
+ return ret;
822
872
  },
823
- __wbg_new_with_byte_offset_and_length_915c5de4270ab7e5: function(arg0, arg1, arg2) {
824
- const ret = new Int8Array(getObject(arg0), arg1 >>> 0, arg2 >>> 0);
825
- return addHeapObject(ret);
873
+ __wbg_new_with_byte_offset_and_length_a867c16cdba43308: function(arg0, arg1, arg2) {
874
+ const ret = new BigUint64Array(arg0, arg1 >>> 0, arg2 >>> 0);
875
+ return ret;
826
876
  },
827
- __wbg_new_with_byte_offset_and_length_b93e61c4e9440336: function(arg0, arg1, arg2) {
828
- const ret = new Int32Array(getObject(arg0), arg1 >>> 0, arg2 >>> 0);
829
- return addHeapObject(ret);
877
+ __wbg_new_with_byte_offset_and_length_c42676f2f088d709: function(arg0, arg1, arg2) {
878
+ const ret = new Float64Array(arg0, arg1 >>> 0, arg2 >>> 0);
879
+ return ret;
830
880
  },
831
- __wbg_new_with_byte_offset_and_length_bf3e693fe2fffb6f: function(arg0, arg1, arg2) {
832
- const ret = new Uint32Array(getObject(arg0), arg1 >>> 0, arg2 >>> 0);
833
- return addHeapObject(ret);
881
+ __wbg_new_with_byte_offset_and_length_c71f41284ed576da: function(arg0, arg1, arg2) {
882
+ const ret = new Uint16Array(arg0, arg1 >>> 0, arg2 >>> 0);
883
+ return ret;
834
884
  },
835
- __wbg_new_with_byte_offset_and_length_c14d867a5878f875: function(arg0, arg1, arg2) {
836
- const ret = new BigInt64Array(getObject(arg0), arg1 >>> 0, arg2 >>> 0);
837
- return addHeapObject(ret);
885
+ __wbg_new_with_byte_offset_and_length_d462c70bf9b35a75: function(arg0, arg1, arg2) {
886
+ const ret = new Int32Array(arg0, arg1 >>> 0, arg2 >>> 0);
887
+ return ret;
838
888
  },
839
- __wbg_new_with_byte_offset_and_length_edf873b0b3173456: function(arg0, arg1, arg2) {
840
- const ret = new Float64Array(getObject(arg0), arg1 >>> 0, arg2 >>> 0);
841
- return addHeapObject(ret);
889
+ __wbg_new_with_byte_offset_and_length_d8c50823dc14d76f: function(arg0, arg1, arg2) {
890
+ const ret = new Int16Array(arg0, arg1 >>> 0, arg2 >>> 0);
891
+ return ret;
842
892
  },
843
- __wbg_next_33784799010f1bbe: function(arg0) {
844
- const ret = getObject(arg0).next;
845
- return addHeapObject(ret);
893
+ __wbg_next_178c1651c11432b3: function(arg0) {
894
+ const ret = arg0.next;
895
+ return ret;
846
896
  },
847
- __wbg_next_f4aac29c42af995c: function() { return handleError(function (arg0) {
848
- const ret = getObject(arg0).next();
849
- return addHeapObject(ret);
897
+ __wbg_next_af5ac6a08bb0a717: function() { return handleError(function (arg0) {
898
+ const ret = arg0.next();
899
+ return ret;
850
900
  }, arguments); },
851
- __wbg_now_d0b7f4bea9f38490: function(arg0) {
852
- const ret = getObject(arg0).now();
901
+ __wbg_now_043d245551b22f9c: function(arg0) {
902
+ const ret = arg0.now();
853
903
  return ret;
854
904
  },
855
- __wbg_outputMetadata_d74fba311b0cce30: function(arg0, arg1) {
856
- const ret = getObject(arg1).outputMetadata;
905
+ __wbg_outputMetadata_0bac175f09361817: function(arg0, arg1) {
906
+ const ret = arg1.outputMetadata;
857
907
  const ptr1 = passArrayJsValueToWasm0(ret, wasm.__wbindgen_export);
858
908
  const len1 = WASM_VECTOR_LEN;
859
- getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
860
- getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
909
+ getDataViewMemory0().setInt32((arg0 >>> 0) + 4 * 1, len1, true);
910
+ getDataViewMemory0().setInt32((arg0 >>> 0) + 4 * 0, ptr1, true);
861
911
  },
862
- __wbg_outputNames_26deb7d052bac410: function(arg0, arg1) {
863
- const ret = getObject(arg1).outputNames;
912
+ __wbg_outputNames_0840e8d28f5268b9: function(arg0, arg1) {
913
+ const ret = arg1.outputNames;
864
914
  const ptr1 = passArrayJsValueToWasm0(ret, wasm.__wbindgen_export);
865
915
  const len1 = WASM_VECTOR_LEN;
866
- getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
867
- getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
916
+ getDataViewMemory0().setInt32((arg0 >>> 0) + 4 * 1, len1, true);
917
+ getDataViewMemory0().setInt32((arg0 >>> 0) + 4 * 0, ptr1, true);
868
918
  },
869
- __wbg_ownKeys_7f46b96dc7311fe8: function() { return handleError(function (arg0) {
870
- const ret = Reflect.ownKeys(getObject(arg0));
871
- return addHeapObject(ret);
919
+ __wbg_ownKeys_c9890d5405932253: function() { return handleError(function (arg0) {
920
+ const ret = Reflect.ownKeys(arg0);
921
+ return ret;
872
922
  }, arguments); },
873
- __wbg_prototypesetcall_06eb15da165dee8f: function(arg0, arg1, arg2) {
874
- Uint32Array.prototype.set.call(getArrayU32FromWasm0(arg0, arg1), getObject(arg2));
923
+ __wbg_prototypesetcall_13162965d1fe7aa3: function(arg0, arg1, arg2) {
924
+ Uint8Array.prototype.set.call(getArrayU8FromWasm0(arg0, arg1), arg2);
875
925
  },
876
- __wbg_prototypesetcall_8b03c01e2c0f8066: function(arg0, arg1, arg2) {
877
- Float32Array.prototype.set.call(getArrayF32FromWasm0(arg0, arg1), getObject(arg2));
926
+ __wbg_prototypesetcall_22b1bb88c4ec5c5a: function(arg0, arg1, arg2) {
927
+ Float32Array.prototype.set.call(getArrayF32FromWasm0(arg0, arg1), arg2);
878
928
  },
879
- __wbg_prototypesetcall_bc27214492979395: function(arg0, arg1, arg2) {
880
- Uint8Array.prototype.set.call(getArrayU8FromWasm0(arg0, arg1), getObject(arg2));
929
+ __wbg_prototypesetcall_4aea6470234c8414: function(arg0, arg1, arg2) {
930
+ Uint32Array.prototype.set.call(getArrayU32FromWasm0(arg0, arg1), arg2);
881
931
  },
882
- __wbg_push_2baf45db356cf468: function(arg0, arg1) {
883
- const ret = getObject(arg0).push(getObject(arg1));
932
+ __wbg_push_c9f4893fc209f768: function(arg0, arg1) {
933
+ const ret = arg0.push(arg1);
884
934
  return ret;
885
935
  },
886
- __wbg_queueMicrotask_9833f9a49df95a49: function(arg0) {
887
- const ret = getObject(arg0).queueMicrotask;
888
- return addHeapObject(ret);
936
+ __wbg_queueMicrotask_1e8503a8a690f0a3: function(arg0) {
937
+ const ret = arg0.queueMicrotask;
938
+ return ret;
889
939
  },
890
- __wbg_queueMicrotask_a72f977e97f23c5f: function(arg0) {
891
- queueMicrotask(getObject(arg0));
940
+ __wbg_queueMicrotask_4a1a4d8dd332373b: function(arg0) {
941
+ queueMicrotask(arg0);
892
942
  },
893
- __wbg_release_0dd02e33b7cd324c: function() { return handleError(function (arg0) {
894
- const ret = getObject(arg0).release();
895
- return addHeapObject(ret);
943
+ __wbg_release_0c2bb01f2bc48732: function() { return handleError(function (arg0) {
944
+ const ret = arg0.release();
945
+ return ret;
896
946
  }, arguments); },
897
- __wbg_resolve_0076e10020304ede: function(arg0) {
898
- const ret = Promise.resolve(getObject(arg0));
899
- return addHeapObject(ret);
947
+ __wbg_resolve_dbf78ab4942478b0: function(arg0) {
948
+ const ret = Promise.resolve(arg0);
949
+ return ret;
900
950
  },
901
- __wbg_run_2893666784c8891d: function() { return handleError(function (arg0, arg1, arg2, arg3) {
902
- const ret = getObject(arg0).run(takeObject(arg1), takeObject(arg2), takeObject(arg3));
903
- return addHeapObject(ret);
904
- }, arguments); },
905
- __wbg_set_145a351398b48c65: function() { return handleError(function (arg0, arg1, arg2) {
906
- const ret = Reflect.set(getObject(arg0), getObject(arg1), getObject(arg2));
951
+ __wbg_run_1e8a187576bdf206: function() { return handleError(function (arg0, arg1, arg2, arg3) {
952
+ const ret = arg0.run(arg1, arg2, arg3);
907
953
  return ret;
908
954
  }, arguments); },
909
- __wbg_set_34d08fd992d43d61: function(arg0, arg1, arg2) {
910
- getObject(arg0).set(getObject(arg1), arg2 >>> 0);
955
+ __wbg_set_118fefd528ab0a79: function(arg0, arg1, arg2) {
956
+ arg0.set(arg1, arg2 >>> 0);
911
957
  },
912
- __wbg_set_575d3ddb70fe831d: function(arg0, arg1, arg2) {
913
- getObject(arg0).set(getArrayU8FromWasm0(arg1, arg2));
958
+ __wbg_set_2793479888329cb6: function() { return handleError(function (arg0, arg1, arg2) {
959
+ const ret = Reflect.set(arg0, arg1, arg2);
960
+ return ret;
961
+ }, arguments); },
962
+ __wbg_set_8282f7e0d2d01336: function(arg0, arg1, arg2) {
963
+ const ret = arg0.set(arg1, arg2);
964
+ return ret;
914
965
  },
915
- __wbg_set_6ae97e73113c4f0b: function(arg0, arg1, arg2) {
916
- const ret = getObject(arg0).set(getObject(arg1), getObject(arg2));
917
- return addHeapObject(ret);
966
+ __wbg_set_d2d33b52458e984a: function(arg0, arg1, arg2) {
967
+ arg0[arg1 >>> 0] = arg2;
918
968
  },
919
- __wbg_set_6be42768c690e380: function(arg0, arg1, arg2) {
920
- getObject(arg0)[takeObject(arg1)] = takeObject(arg2);
969
+ __wbg_set_e4b9a833d288759a: function(arg0, arg1, arg2) {
970
+ arg0[arg1] = arg2;
921
971
  },
922
- __wbg_set_bea140a88be9b277: function(arg0, arg1, arg2) {
923
- getObject(arg0)[arg1 >>> 0] = takeObject(arg2);
972
+ __wbg_set_feb3714f475485ba: function(arg0, arg1, arg2) {
973
+ arg0.set(getArrayU8FromWasm0(arg1, arg2));
924
974
  },
925
- __wbg_slice_6da4cdc5d543fcd0: function(arg0, arg1) {
926
- const ret = getObject(arg1).slice();
975
+ __wbg_slice_984d22ab53865879: function(arg0, arg1) {
976
+ const ret = arg1.slice();
927
977
  const ptr1 = passArrayJsValueToWasm0(ret, wasm.__wbindgen_export);
928
978
  const len1 = WASM_VECTOR_LEN;
929
- getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
930
- getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
979
+ getDataViewMemory0().setInt32((arg0 >>> 0) + 4 * 1, len1, true);
980
+ getDataViewMemory0().setInt32((arg0 >>> 0) + 4 * 0, ptr1, true);
931
981
  },
932
- __wbg_stack_3b0d974bbf31e44f: function(arg0, arg1) {
933
- const ret = getObject(arg1).stack;
982
+ __wbg_stack_575c4e0918581b9c: function(arg0, arg1) {
983
+ const ret = arg1.stack;
934
984
  const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_export, wasm.__wbindgen_export2);
935
985
  const len1 = WASM_VECTOR_LEN;
936
- getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
937
- getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
986
+ getDataViewMemory0().setInt32((arg0 >>> 0) + 4 * 1, len1, true);
987
+ getDataViewMemory0().setInt32((arg0 >>> 0) + 4 * 0, ptr1, true);
938
988
  },
939
- __wbg_static_accessor_GLOBAL_266715b9d96ba635: function() {
940
- const ret = typeof global === 'undefined' ? null : global;
941
- return isLikeNone(ret) ? 0 : addHeapObject(ret);
989
+ __wbg_static_accessor_GLOBAL_THIS_003ee833af9699fc: function() {
990
+ const ret = typeof globalThis === 'undefined' ? undefined : globalThis;
991
+ return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
942
992
  },
943
- __wbg_static_accessor_GLOBAL_THIS_10fb7dc1ae063179: function() {
944
- const ret = typeof globalThis === 'undefined' ? null : globalThis;
945
- return isLikeNone(ret) ? 0 : addHeapObject(ret);
993
+ __wbg_static_accessor_GLOBAL_e4293fb22cbe77da: function() {
994
+ const ret = typeof global === 'undefined' ? undefined : global;
995
+ return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
946
996
  },
947
- __wbg_static_accessor_SELF_0b583911f537483a: function() {
948
- const ret = typeof self === 'undefined' ? null : self;
949
- return isLikeNone(ret) ? 0 : addHeapObject(ret);
997
+ __wbg_static_accessor_SELF_53bb20457401453d: function() {
998
+ const ret = typeof self === 'undefined' ? undefined : self;
999
+ return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
950
1000
  },
951
- __wbg_static_accessor_WINDOW_d7f903d1508cbdc4: function() {
952
- const ret = typeof window === 'undefined' ? null : window;
953
- return isLikeNone(ret) ? 0 : addHeapObject(ret);
1001
+ __wbg_static_accessor_WINDOW_b5e0810bfecb7feb: function() {
1002
+ const ret = typeof window === 'undefined' ? undefined : window;
1003
+ return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
954
1004
  },
955
- __wbg_then_c949d5a25a4e78f8: function(arg0, arg1, arg2) {
956
- const ret = getObject(arg0).then(getObject(arg1), getObject(arg2));
957
- return addHeapObject(ret);
1005
+ __wbg_then_656f253a5dd7d8ea: function(arg0, arg1, arg2) {
1006
+ const ret = arg0.then(arg1, arg2);
1007
+ return ret;
958
1008
  },
959
- __wbg_then_e71170d78fcf8954: function(arg0, arg1) {
960
- const ret = getObject(arg0).then(getObject(arg1));
961
- return addHeapObject(ret);
1009
+ __wbg_then_e3f7f2d365708be8: function(arg0, arg1) {
1010
+ const ret = arg0.then(arg1);
1011
+ return ret;
962
1012
  },
963
- __wbg_toString_c58c5795e09f80e1: function(arg0) {
964
- const ret = getObject(arg0).toString();
965
- return addHeapObject(ret);
1013
+ __wbg_toString_f4b4edcadc38f18a: function(arg0) {
1014
+ const ret = arg0.toString();
1015
+ return ret;
966
1016
  },
967
- __wbg_trackSessionInit_b37a6598a5541f10: function() { return handleError(function (arg0, arg1) {
1017
+ __wbg_trackSessionInit_f0d12f5bbc56f15c: function() { return handleError(function (arg0, arg1) {
968
1018
  const ret = trackSessionInit(getStringFromWasm0(arg0, arg1));
969
- return addHeapObject(ret);
1019
+ return ret;
970
1020
  }, arguments); },
971
- __wbg_type_e1fd5cc29b264a06: function(arg0) {
972
- const ret = getObject(arg0).type;
1021
+ __wbg_type_a992828c4d47b9b1: function(arg0) {
1022
+ const ret = arg0.type;
973
1023
  return (__wbindgen_enum_DataType.indexOf(ret) + 1 || 16) - 1;
974
1024
  },
975
- __wbg_value_f3c585ee8f5ba40c: function(arg0) {
976
- const ret = getObject(arg0).value;
977
- return addHeapObject(ret);
1025
+ __wbg_value_e0f328965e184931: function(arg0) {
1026
+ const ret = arg0.value;
1027
+ return ret;
978
1028
  },
979
1029
  __wbg_yolomodel_new: function(arg0) {
980
1030
  const ret = YoloModel.__wrap(arg0);
981
- return addHeapObject(ret);
1031
+ return ret;
982
1032
  },
983
1033
  __wbindgen_generic_0000000000000001: function(arg0, arg1) {
984
1034
  // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [Externref], shim_idx: 377, ret: Result(Unit), inner_ret: Some(Result(Unit)) }, mutable: true }) -> Externref`.
985
- const ret = makeMutClosure(arg0, arg1, __wasm_bindgen_func_elem_1320);
986
- return addHeapObject(ret);
1035
+ const ret = makeMutClosure(arg0, arg1, __wasm_bindgen_func_elem_1334);
1036
+ return ret;
987
1037
  },
988
1038
  __wbindgen_generic_0000000000000002: function(arg0, arg1) {
989
1039
  // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [Externref], shim_idx: 661, ret: Result(Unit), inner_ret: Some(Result(Unit)) }, mutable: true }) -> Externref`.
990
- const ret = makeMutClosure(arg0, arg1, __wasm_bindgen_func_elem_1951);
991
- return addHeapObject(ret);
1040
+ const ret = makeMutClosure(arg0, arg1, __wasm_bindgen_func_elem_1970);
1041
+ return ret;
992
1042
  },
993
1043
  __wbindgen_generic_0000000000000003: function(arg0, arg1) {
994
1044
  // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("boolean")], shim_idx: 21, ret: Result(Unit), inner_ret: Some(Result(Unit)) }, mutable: true }) -> Externref`.
995
- const ret = makeMutClosure(arg0, arg1, __wasm_bindgen_func_elem_390);
996
- return addHeapObject(ret);
1045
+ const ret = makeMutClosure(arg0, arg1, __wasm_bindgen_func_elem_397);
1046
+ return ret;
997
1047
  },
998
1048
  __wbindgen_generic_0000000000000004: function(arg0) {
999
1049
  // Cast intrinsic for `F64 -> Externref`.
1000
1050
  const ret = arg0;
1001
- return addHeapObject(ret);
1051
+ return ret;
1002
1052
  },
1003
1053
  __wbindgen_generic_0000000000000005: function(arg0) {
1004
1054
  // Cast intrinsic for `I64 -> Externref`.
1005
1055
  const ret = arg0;
1006
- return addHeapObject(ret);
1056
+ return ret;
1007
1057
  },
1008
1058
  __wbindgen_generic_0000000000000006: function(arg0, arg1) {
1009
1059
  // Cast intrinsic for `Ref(Slice(F32)) -> NamedExternref("Float32Array")`.
1010
1060
  const ret = getArrayF32FromWasm0(arg0, arg1);
1011
- return addHeapObject(ret);
1061
+ return ret;
1012
1062
  },
1013
1063
  __wbindgen_generic_0000000000000007: function(arg0, arg1) {
1014
1064
  // Cast intrinsic for `Ref(Slice(F64)) -> NamedExternref("Float64Array")`.
1015
1065
  const ret = getArrayF64FromWasm0(arg0, arg1);
1016
- return addHeapObject(ret);
1066
+ return ret;
1017
1067
  },
1018
1068
  __wbindgen_generic_0000000000000008: function(arg0, arg1) {
1019
1069
  // Cast intrinsic for `Ref(Slice(I16)) -> NamedExternref("Int16Array")`.
1020
1070
  const ret = getArrayI16FromWasm0(arg0, arg1);
1021
- return addHeapObject(ret);
1071
+ return ret;
1022
1072
  },
1023
1073
  __wbindgen_generic_0000000000000009: function(arg0, arg1) {
1024
1074
  // Cast intrinsic for `Ref(Slice(I32)) -> NamedExternref("Int32Array")`.
1025
1075
  const ret = getArrayI32FromWasm0(arg0, arg1);
1026
- return addHeapObject(ret);
1076
+ return ret;
1027
1077
  },
1028
1078
  __wbindgen_generic_000000000000000a: function(arg0, arg1) {
1029
1079
  // Cast intrinsic for `Ref(Slice(I64)) -> NamedExternref("BigInt64Array")`.
1030
1080
  const ret = getArrayI64FromWasm0(arg0, arg1);
1031
- return addHeapObject(ret);
1081
+ return ret;
1032
1082
  },
1033
1083
  __wbindgen_generic_000000000000000b: function(arg0, arg1) {
1034
1084
  // Cast intrinsic for `Ref(Slice(I8)) -> NamedExternref("Int8Array")`.
1035
1085
  const ret = getArrayI8FromWasm0(arg0, arg1);
1036
- return addHeapObject(ret);
1086
+ return ret;
1037
1087
  },
1038
1088
  __wbindgen_generic_000000000000000c: function(arg0, arg1) {
1039
1089
  // Cast intrinsic for `Ref(Slice(U16)) -> NamedExternref("Uint16Array")`.
1040
1090
  const ret = getArrayU16FromWasm0(arg0, arg1);
1041
- return addHeapObject(ret);
1091
+ return ret;
1042
1092
  },
1043
1093
  __wbindgen_generic_000000000000000d: function(arg0, arg1) {
1044
1094
  // Cast intrinsic for `Ref(Slice(U32)) -> NamedExternref("Uint32Array")`.
1045
1095
  const ret = getArrayU32FromWasm0(arg0, arg1);
1046
- return addHeapObject(ret);
1096
+ return ret;
1047
1097
  },
1048
1098
  __wbindgen_generic_000000000000000e: function(arg0, arg1) {
1049
1099
  // Cast intrinsic for `Ref(Slice(U64)) -> NamedExternref("BigUint64Array")`.
1050
1100
  const ret = getArrayU64FromWasm0(arg0, arg1);
1051
- return addHeapObject(ret);
1101
+ return ret;
1052
1102
  },
1053
1103
  __wbindgen_generic_000000000000000f: function(arg0, arg1) {
1054
1104
  // Cast intrinsic for `Ref(Slice(U8)) -> NamedExternref("Uint8Array")`.
1055
1105
  const ret = getArrayU8FromWasm0(arg0, arg1);
1056
- return addHeapObject(ret);
1106
+ return ret;
1057
1107
  },
1058
1108
  __wbindgen_generic_0000000000000010: function(arg0, arg1) {
1059
1109
  // Cast intrinsic for `Ref(String) -> Externref`.
1060
1110
  const ret = getStringFromWasm0(arg0, arg1);
1061
- return addHeapObject(ret);
1111
+ return ret;
1062
1112
  },
1063
1113
  __wbindgen_generic_0000000000000011: function(arg0) {
1064
1114
  // Cast intrinsic for `U64 -> Externref`.
1065
1115
  const ret = BigInt.asUintN(64, arg0);
1066
- return addHeapObject(ret);
1067
- },
1068
- __wbindgen_object_clone_ref: function(arg0) {
1069
- const ret = getObject(arg0);
1070
- return addHeapObject(ret);
1116
+ return ret;
1071
1117
  },
1072
- __wbindgen_object_drop_ref: function(arg0) {
1073
- takeObject(arg0);
1118
+ __wbindgen_init_externref_table: function() {
1119
+ const table = wasm.__wbindgen_externrefs;
1120
+ table.set(0, undefined);
1121
+ table.set(1024, undefined);
1122
+ table.set(1025, null);
1123
+ table.set(1026, true);
1124
+ table.set(1027, false);
1074
1125
  },
1075
1126
  };
1076
1127
  return {
@@ -1079,46 +1130,46 @@ function __wbg_get_imports() {
1079
1130
  };
1080
1131
  }
1081
1132
 
1082
- function __wasm_bindgen_func_elem_1975(arg0, arg1, arg2, arg3) {
1083
- wasm.__wasm_bindgen_func_elem_1975(arg0, arg1, addHeapObject(arg2), addHeapObject(arg3));
1133
+ function __wasm_bindgen_func_elem_1996(arg0, arg1, arg2, arg3) {
1134
+ wasm.__wasm_bindgen_func_elem_1996(arg0, arg1, arg2, arg3);
1084
1135
  }
1085
1136
 
1086
- function __wasm_bindgen_func_elem_1320(arg0, arg1, arg2) {
1137
+ function __wasm_bindgen_func_elem_1334(arg0, arg1, arg2) {
1087
1138
  try {
1088
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
1089
- wasm.__wasm_bindgen_func_elem_1320(retptr, arg0, arg1, addHeapObject(arg2));
1139
+ const retptr = wasm.__wbindgen_add_to_stack_pointer(-16) >>> 0;
1140
+ wasm.__wasm_bindgen_func_elem_1334(retptr, arg0, arg1, arg2);
1090
1141
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
1091
1142
  var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
1092
1143
  if (r1) {
1093
- throw takeObject(r0);
1144
+ throw takeFromExternrefTable0(r0);
1094
1145
  }
1095
1146
  } finally {
1096
1147
  wasm.__wbindgen_add_to_stack_pointer(16);
1097
1148
  }
1098
1149
  }
1099
1150
 
1100
- function __wasm_bindgen_func_elem_1951(arg0, arg1, arg2) {
1151
+ function __wasm_bindgen_func_elem_1970(arg0, arg1, arg2) {
1101
1152
  try {
1102
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
1103
- wasm.__wasm_bindgen_func_elem_1951(retptr, arg0, arg1, addHeapObject(arg2));
1153
+ const retptr = wasm.__wbindgen_add_to_stack_pointer(-16) >>> 0;
1154
+ wasm.__wasm_bindgen_func_elem_1970(retptr, arg0, arg1, arg2);
1104
1155
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
1105
1156
  var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
1106
1157
  if (r1) {
1107
- throw takeObject(r0);
1158
+ throw takeFromExternrefTable0(r0);
1108
1159
  }
1109
1160
  } finally {
1110
1161
  wasm.__wbindgen_add_to_stack_pointer(16);
1111
1162
  }
1112
1163
  }
1113
1164
 
1114
- function __wasm_bindgen_func_elem_390(arg0, arg1, arg2) {
1165
+ function __wasm_bindgen_func_elem_397(arg0, arg1, arg2) {
1115
1166
  try {
1116
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
1117
- wasm.__wasm_bindgen_func_elem_390(retptr, arg0, arg1, addHeapObject(arg2));
1167
+ const retptr = wasm.__wbindgen_add_to_stack_pointer(-16) >>> 0;
1168
+ wasm.__wasm_bindgen_func_elem_397(retptr, arg0, arg1, arg2);
1118
1169
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
1119
1170
  var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
1120
1171
  if (r1) {
1121
- throw takeObject(r0);
1172
+ throw takeFromExternrefTable0(r0);
1122
1173
  }
1123
1174
  } finally {
1124
1175
  wasm.__wbindgen_add_to_stack_pointer(16);
@@ -1137,88 +1188,72 @@ const YoloPipelineFinalization = (typeof FinalizationRegistry === 'undefined')
1137
1188
  ? { register: () => {}, unregister: () => {} }
1138
1189
  : new FinalizationRegistry(ptr => wasm.__wbg_yolopipeline_free(ptr, 1));
1139
1190
 
1140
- function addHeapObject(obj) {
1141
- if (heap_next === heap.length) heap.push(heap.length + 1);
1142
- const idx = heap_next;
1143
- heap_next = heap[idx];
1144
-
1145
- heap[idx] = obj;
1191
+ function addToExternrefTable0(obj) {
1192
+ const idx = wasm.__wbindgen_export5();
1193
+ wasm.__wbindgen_externrefs.set(idx, obj);
1146
1194
  return idx;
1147
1195
  }
1148
1196
 
1149
1197
  const CLOSURE_DTORS = (typeof FinalizationRegistry === 'undefined')
1150
1198
  ? { register: () => {}, unregister: () => {} }
1151
- : new FinalizationRegistry(state => wasm.__wbindgen_export5(state.a, state.b));
1199
+ : new FinalizationRegistry(state => wasm.__wbindgen_export7(state.a, state.b));
1152
1200
 
1153
1201
  function debugString(val) {
1154
- // primitive types
1155
- const type = typeof val;
1156
- if (type == 'number' || type == 'boolean' || val == null) {
1157
- return `${val}`;
1158
- }
1159
- if (type == 'string') {
1160
- return `"${val}"`;
1161
- }
1162
- if (type == 'symbol') {
1163
- const description = val.description;
1164
- if (description == null) {
1165
- return 'Symbol';
1166
- } else {
1167
- return `Symbol(${description})`;
1168
- }
1169
- }
1170
- if (type == 'function') {
1171
- const name = val.name;
1172
- if (typeof name == 'string' && name.length > 0) {
1173
- return `Function(${name})`;
1174
- } else {
1175
- return 'Function';
1176
- }
1177
- }
1178
- // objects
1179
- if (Array.isArray(val)) {
1180
- const length = val.length;
1181
- let debug = '[';
1182
- if (length > 0) {
1183
- debug += debugString(val[0]);
1184
- }
1185
- for(let i = 1; i < length; i++) {
1186
- debug += ', ' + debugString(val[i]);
1187
- }
1188
- debug += ']';
1189
- return debug;
1190
- }
1191
- // Test for built-in
1192
- const builtInMatches = /\[object ([^\]]+)\]/.exec(toString.call(val));
1193
- let className;
1194
- if (builtInMatches && builtInMatches.length > 1) {
1195
- className = builtInMatches[1];
1196
- } else {
1197
- // Failed to match the standard '[object ClassName]'
1198
- return toString.call(val);
1199
- }
1200
- if (className == 'Object') {
1201
- // we're a user defined class or Object
1202
- // JSON.stringify avoids problems with cycles, and is generally much
1203
- // easier than looping through ownProperties of `val`.
1204
- try {
1205
- return 'Object(' + JSON.stringify(val) + ')';
1206
- } catch (_) {
1207
- return 'Object';
1202
+ switch (typeof val) {
1203
+ // primitive types
1204
+ case 'number':
1205
+ case 'boolean':
1206
+ case 'undefined':
1207
+ return `${val}`;
1208
+ case 'string':
1209
+ return JSON.stringify(val);
1210
+ case 'bigint':
1211
+ return `${val}n`;
1212
+ case 'symbol':
1213
+ return val.description !== undefined
1214
+ ? `Symbol(${val.description})`
1215
+ : 'Symbol';
1216
+ case 'function':
1217
+ return typeof val.name === 'string' && val.name !== ''
1218
+ ? `Function(${val.name})`
1219
+ : 'Function';
1220
+ case 'object': {
1221
+ if (val === null) {
1222
+ return 'null';
1223
+ }
1224
+ // objects
1225
+ if (Array.isArray(val)) {
1226
+ return '[' + Array.from(val, debugString).join(', ') + ']';
1227
+ }
1228
+ // errors
1229
+ if (val instanceof Error) {
1230
+ return `${val.name}: ${val.message}\n${val.stack}`;
1231
+ }
1232
+
1233
+ const toStringOutput = toString.call(val);
1234
+ // Test for built-in
1235
+ const className = /\[object ([^\]]+)\]/.exec(toStringOutput)?.[1];
1236
+
1237
+ // Failed to match the standard '[object ClassName]'
1238
+ if (className === undefined) {
1239
+ return toStringOutput;
1240
+ }
1241
+ if (className === 'Object') {
1242
+ // we're a user defined class or Object
1243
+ // JSON.stringify avoids problems with cycles, and is generally much
1244
+ // easier than looping through ownProperties of `val`.
1245
+ try {
1246
+ return 'Object(' + JSON.stringify(val) + ')';
1247
+ } catch (_) {
1248
+ return 'Object';
1249
+ }
1250
+ }
1251
+ // TODO we could test for more things here, like `Set`s and `Map`s.
1252
+ return className;
1208
1253
  }
1254
+ // Per MDN: 'This list of values is exhaustive.'
1255
+ // https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/typeof#description
1209
1256
  }
1210
- // errors
1211
- if (val instanceof Error) {
1212
- return `${val.name}: ${val.message}\n${val.stack}`;
1213
- }
1214
- // TODO we could test for more things here, like `Set`s and `Map`s.
1215
- return className;
1216
- }
1217
-
1218
- function dropObject(idx) {
1219
- if (idx < 1028) return;
1220
- heap[idx] = heap_next;
1221
- heap_next = idx;
1222
1257
  }
1223
1258
 
1224
1259
  function getArrayF32FromWasm0(ptr, len) {
@@ -1256,8 +1291,9 @@ function getArrayJsValueFromWasm0(ptr, len) {
1256
1291
  const mem = getDataViewMemory0();
1257
1292
  const result = [];
1258
1293
  for (let i = ptr; i < ptr + 4 * len; i += 4) {
1259
- result.push(takeObject(mem.getUint32(i, true)));
1294
+ result.push(wasm.__wbindgen_externrefs.get(mem.getUint32(i, true)));
1260
1295
  }
1296
+ wasm.__wbindgen_export6(ptr, len);
1261
1297
  return result;
1262
1298
  }
1263
1299
 
@@ -1346,7 +1382,8 @@ function getInt8ArrayMemory0() {
1346
1382
  }
1347
1383
 
1348
1384
  function getStringFromWasm0(ptr, len) {
1349
- return decodeText(ptr >>> 0, len);
1385
+ ptr = ptr >>> 0;
1386
+ return decodeText(getUint8ArrayMemory0().subarray(ptr, ptr + len));
1350
1387
  }
1351
1388
 
1352
1389
  let cachedUint16ArrayMemory0 = null;
@@ -1373,21 +1410,15 @@ function getUint8ArrayMemory0() {
1373
1410
  return cachedUint8ArrayMemory0;
1374
1411
  }
1375
1412
 
1376
- function getObject(idx) { return heap[idx]; }
1377
-
1378
1413
  function handleError(f, args) {
1379
1414
  try {
1380
1415
  return f.apply(this, args);
1381
1416
  } catch (e) {
1382
- wasm.__wbindgen_export3(addHeapObject(e));
1417
+ const idx = addToExternrefTable0(e);
1418
+ wasm.__wbindgen_export4(idx);
1383
1419
  }
1384
1420
  }
1385
1421
 
1386
- let heap = new Array(1024).fill(undefined);
1387
- heap.push(undefined, null, true, false);
1388
-
1389
- let heap_next = heap.length;
1390
-
1391
1422
  function isLikeNone(x) {
1392
1423
  return x === undefined || x === null;
1393
1424
  }
@@ -1411,7 +1442,7 @@ function makeMutClosure(arg0, arg1, f) {
1411
1442
  };
1412
1443
  real._wbg_cb_unref = () => {
1413
1444
  if (--state.cnt === 0) {
1414
- wasm.__wbindgen_export5(state.a, state.b);
1445
+ wasm.__wbindgen_export7(state.a, state.b);
1415
1446
  state.a = 0;
1416
1447
  CLOSURE_DTORS.unregister(state);
1417
1448
  }
@@ -1443,9 +1474,9 @@ function passArrayF64ToWasm0(arg, malloc) {
1443
1474
 
1444
1475
  function passArrayJsValueToWasm0(array, malloc) {
1445
1476
  const ptr = malloc(array.length * 4, 4) >>> 0;
1446
- const mem = getDataViewMemory0();
1447
1477
  for (let i = 0; i < array.length; i++) {
1448
- mem.setUint32(ptr + 4 * i, addHeapObject(array[i]), true);
1478
+ const add = addToExternrefTable0(array[i]);
1479
+ getDataViewMemory0().setUint32(ptr + 4 * i, add, true);
1449
1480
  }
1450
1481
  WASM_VECTOR_LEN = array.length;
1451
1482
  return ptr;
@@ -1488,24 +1519,24 @@ function passStringToWasm0(arg, malloc, realloc) {
1488
1519
  return ptr;
1489
1520
  }
1490
1521
 
1491
- function takeObject(idx) {
1492
- const ret = getObject(idx);
1493
- dropObject(idx);
1494
- return ret;
1522
+ function takeFromExternrefTable0(idx) {
1523
+ const value = wasm.__wbindgen_externrefs.get(idx);
1524
+ wasm.__wbindgen_export8(idx);
1525
+ return value;
1495
1526
  }
1496
1527
 
1497
- let cachedTextDecoder = new TextDecoder('utf-8', { ignoreBOM: true, fatal: true });
1528
+ let cachedTextDecoder = new TextDecoder('utf-8', { ignoreBOM: true });
1498
1529
  cachedTextDecoder.decode();
1499
1530
  const MAX_SAFARI_DECODE_BYTES = 2146435072;
1500
1531
  let numBytesDecoded = 0;
1501
- function decodeText(ptr, len) {
1502
- numBytesDecoded += len;
1532
+ function decodeText(bytes) {
1533
+ numBytesDecoded += bytes.length;
1503
1534
  if (numBytesDecoded >= MAX_SAFARI_DECODE_BYTES) {
1504
- cachedTextDecoder = new TextDecoder('utf-8', { ignoreBOM: true, fatal: true });
1535
+ cachedTextDecoder = new TextDecoder('utf-8', { ignoreBOM: true });
1505
1536
  cachedTextDecoder.decode();
1506
- numBytesDecoded = len;
1537
+ numBytesDecoded = bytes.length;
1507
1538
  }
1508
- return cachedTextDecoder.decode(getUint8ArrayMemory0().subarray(ptr, ptr + len));
1539
+ return cachedTextDecoder.decode(bytes);
1509
1540
  }
1510
1541
 
1511
1542
  const cachedTextEncoder = new TextEncoder();
@@ -1602,9 +1633,17 @@ function initSync(module) {
1602
1633
  return __wbg_finalize_init(instance, module);
1603
1634
  }
1604
1635
 
1636
+ let __wbg_init_promise;
1605
1637
  async function __wbg_init(module_or_path) {
1606
1638
  if (wasm !== undefined) return wasm;
1639
+ if (__wbg_init_promise === undefined) {
1640
+ __wbg_init_promise = __wbg_init_once(module_or_path);
1641
+ __wbg_init_promise.catch(() => { __wbg_init_promise = undefined; });
1642
+ }
1643
+ return __wbg_init_promise;
1644
+ }
1607
1645
 
1646
+ async function __wbg_init_once(module_or_path) {
1608
1647
 
1609
1648
  if (module_or_path !== undefined) {
1610
1649
  if (Object.getPrototypeOf(module_or_path) === Object.prototype) {