mirror of
https://github.com/koush/scrypted.git
synced 2026-02-03 06:03:27 +00:00
diagnostics: relax person detect for new models
This commit is contained in:
4
plugins/diagnostics/package-lock.json
generated
4
plugins/diagnostics/package-lock.json
generated
@@ -1,12 +1,12 @@
|
||||
{
|
||||
"name": "@scrypted/diagnostics",
|
||||
"version": "0.0.28",
|
||||
"version": "0.0.29",
|
||||
"lockfileVersion": 2,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "@scrypted/diagnostics",
|
||||
"version": "0.0.28",
|
||||
"version": "0.0.29",
|
||||
"dependencies": {
|
||||
"@scrypted/common": "file:../../common",
|
||||
"@scrypted/sdk": "file:../../sdk",
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@scrypted/diagnostics",
|
||||
"version": "0.0.28",
|
||||
"version": "0.0.29",
|
||||
"scripts": {
|
||||
"scrypted-setup-project": "scrypted-setup-project",
|
||||
"prescrypted-setup-project": "scrypted-package-json",
|
||||
|
||||
@@ -137,7 +137,7 @@ class DiagnosticsPlugin extends ScryptedDeviceBase implements Settings {
|
||||
|
||||
const zidane = await sdk.mediaManager.createMediaObjectFromUrl('https://docs.scrypted.app/img/scrypted-nvr/troubleshooting/zidane.jpg');
|
||||
const detected = await plugin.detectObjects(zidane);
|
||||
const personFound = detected.detections!.find(d => d.className === 'person' && d.score > .9);
|
||||
const personFound = detected.detections!.find(d => d.className === 'person' && d.score > .8);
|
||||
if (!personFound) {
|
||||
throw new Error('Person not detected in test image.');
|
||||
}
|
||||
@@ -714,7 +714,7 @@ class DiagnosticsPlugin extends ScryptedDeviceBase implements Settings {
|
||||
if (image.width !== 320)
|
||||
throw new Error('Unexpected image with from GPU transform.')
|
||||
const detected = await openvinoPlugin.detectObjects(zidane);
|
||||
const personFound = detected.detections!.find(d => d.className === 'person' && d.score > .9);
|
||||
const personFound = detected.detections!.find(d => d.className === 'person' && d.score > .8);
|
||||
if (!personFound)
|
||||
throw new Error('Person not detected in test image.');
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user