mirror of
http://git.xinwangdao.com/cnnc-embedded-parts-detect/detect-gui.git
synced 2025-06-24 13:14:11 +08:00
1、image framework
This commit is contained in:
parent
d51db0bf36
commit
60494c38b1
@ -200,11 +200,6 @@ class ImageFramework(EdgeComponent):
|
||||
|
||||
def configure(self, setting: Settings) -> None:
|
||||
self.init_image_framework_sdk()
|
||||
self.location_thread = threading.Thread(target=self._location_processing_thread)
|
||||
self.location_thread.daemon = True
|
||||
self.process_thread = threading.Thread(target=self._main_processing_thread)
|
||||
self.process_thread.daemon = True
|
||||
|
||||
self.logger.info(f"Image framework configure done.")
|
||||
|
||||
def init_image_framework_sdk(self):
|
||||
@ -281,6 +276,10 @@ class ImageFramework(EdgeComponent):
|
||||
@service()
|
||||
def start_location(self):
|
||||
self.thread_running = True
|
||||
self.location_thread = threading.Thread(target=self._location_processing_thread)
|
||||
self.location_thread.daemon = True
|
||||
self.process_thread = threading.Thread(target=self._main_processing_thread)
|
||||
self.process_thread.daemon = True
|
||||
self.location_thread.start()
|
||||
self.process_thread.start()
|
||||
|
||||
@ -289,8 +288,10 @@ class ImageFramework(EdgeComponent):
|
||||
self.thread_running = False
|
||||
if self.location_thread is not None:
|
||||
self.location_thread.join()
|
||||
self.location_thread = None
|
||||
if self.process_thread is not None:
|
||||
self.process_thread.join()
|
||||
self.process_thread = None
|
||||
|
||||
@service()
|
||||
def start_detect(self):
|
||||
|
Loading…
Reference in New Issue
Block a user