ver0.1
This commit is contained in:
@@ -14,6 +14,8 @@ from __future__ import annotations
|
||||
|
||||
import time
|
||||
|
||||
from app.services.voice_terminal_hub import VoiceTerminalHub
|
||||
|
||||
from app.baked import pipeline as bp
|
||||
from app.services.consumable_vision_algorithm import (
|
||||
PredictionCandidate,
|
||||
@@ -56,8 +58,13 @@ class VisionClassificationHandler:
|
||||
self,
|
||||
*,
|
||||
registry: SurgerySessionRegistry,
|
||||
voice_terminal_hub: VoiceTerminalHub | None = None,
|
||||
) -> None:
|
||||
self._registry = registry
|
||||
self._voice_hub = voice_terminal_hub
|
||||
|
||||
def attach_voice_terminal_hub(self, hub: VoiceTerminalHub | None) -> None:
|
||||
self._voice_hub = hub
|
||||
|
||||
def _append_vision_consumption_window_if_ready(
|
||||
self,
|
||||
@@ -212,3 +219,7 @@ class VisionClassificationHandler:
|
||||
confirmation_id=cid,
|
||||
doctor_id=bp.VIDEO_RESULT_DOCTOR_ID,
|
||||
)
|
||||
hub = self._voice_hub
|
||||
vtid = (state.voice_terminal_id or "").strip()
|
||||
if hub is not None and vtid and surgery_id:
|
||||
hub.schedule_notify_pending_head(vtid, surgery_id)
|
||||
|
||||
Reference in New Issue
Block a user