changes some cases

This commit is contained in:
yoni13
2025-01-17 19:25:01 +08:00
parent 9882b83cd4
commit f32d991131
4 changed files with 13 additions and 13 deletions

View File

@@ -138,7 +138,7 @@ def ann_session() -> Iterator[mock.Mock]:
@pytest.fixture(scope="function")
def rknn_session() -> Iterator[mock.Mock]:
with mock.patch("app.sessions.rknn.rknnPoolExecutor") as mocked:
with mock.patch("app.sessions.rknn.RknnPoolExecutor") as mocked:
yield mocked

View File

@@ -8,7 +8,7 @@ import onnxruntime as ort
from numpy.typing import NDArray
from app.schemas import SessionNode
from rknn.rknnpool import rknnPoolExecutor, soc_name
from rknn.rknnpool import RknnPoolExecutor, soc_name
from ..config import log, settings
@@ -32,7 +32,7 @@ class RknnSession:
self.tpe = settings.rknn_facial_detection_threads
log.info(f"Loading RKNN model from {self.model_path} with {self.tpe} threads.")
self.rknnpool = rknnPoolExecutor(rknnModel=self.model_path.as_posix(), TPEs=self.tpe, func=runInfrence)
self.rknnpool = RknnPoolExecutor(rknnModel=self.model_path.as_posix(), TPEs=self.tpe, func=runInfrence)
log.info(f"Loaded RKNN model from {self.model_path} with {self.tpe} threads.")
def __del__(self) -> None: