Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
model: luxonis/scrfd-person-detection:25g-640x640
platform: RVC4
2 changes: 2 additions & 0 deletions apps/focused-vision/backend/src/depthai_models/yunet.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
model: luxonis/yunet:320x240
platform: RVC4
13 changes: 10 additions & 3 deletions apps/focused-vision/backend/src/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,8 @@
from arguments import initialize_argparser
from depthai_nodes.node.extended_neural_network import ExtendedNeuralNetwork
from depthai_nodes.node.stage_2_neural_network import Stage2NeuralNetwork

import os
from pathlib import Path

logger = logging.getLogger(__name__)

Expand All @@ -17,8 +18,14 @@
frame_type = dai.ImgFrame.Type.BGR888i
HIGH_RES_WIDTH, HIGH_RES_HEIGHT = 2000, 2000
LOW_RES_WIDTH, LOW_RES_HEIGHT = 640, 640
PEOPLE_DETECTION_MODEL = "luxonis/scrfd-person-detection:25g-640x640"
FACE_DETECTION_MODEL = "luxonis/yunet:320x240"
SCRIPT_DIR = Path(os.path.dirname(os.path.abspath(__file__)))
DEPTHAI_MODELS_DIR = SCRIPT_DIR / "depthai_models"
PEOPLE_DETECTION_MODEL = dai.NNModelDescription.fromYamlFile(
DEPTHAI_MODELS_DIR / "scrfd-person-detection.yaml"
)
FACE_DETECTION_MODEL = dai.NNModelDescription.fromYamlFile(
DEPTHAI_MODELS_DIR / "yunet.yaml"
)
if not args.fps_limit:
args.fps_limit = 13

Expand Down
4 changes: 3 additions & 1 deletion apps/focused-vision/oakapp.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@ build_steps = [
"chmod +x /etc/service/backend/run",
]

depthai_models = { yaml_path = "./backend/src/depthai_models" }

[static_frontend]
dist_path = "./frontend/dist"

Expand All @@ -28,4 +30,4 @@ oauth_url = "https://auth.docker.io/token"
auth_type = "repository"
auth_name = "luxonis/oakapp-base"
image_name = "luxonis/oakapp-base"
image_tag = "1.2.6"
image_tag = "1.2.6"