Spaces:
Running
Running
Update index.js
Browse files
index.js
CHANGED
@@ -50,6 +50,7 @@ async function detect(img) {
|
|
50 |
const { pixel_values } = await processor(image);
|
51 |
const { output0 } = await model({ images: pixel_values });
|
52 |
const predictions = output0.tolist()[0];
|
|
|
53 |
const threshold = 0.5;
|
54 |
for (const [xmin, ymin, xmax, ymax, score, id] of predictions) {
|
55 |
if (score < threshold) continue;
|
|
|
50 |
const { pixel_values } = await processor(image);
|
51 |
const { output0 } = await model({ images: pixel_values });
|
52 |
const predictions = output0.tolist()[0];
|
53 |
+
console.log(predictions);
|
54 |
const threshold = 0.5;
|
55 |
for (const [xmin, ymin, xmax, ymax, score, id] of predictions) {
|
56 |
if (score < threshold) continue;
|