Set queue max sizes equal to one another

I don't know why but this seems to make the app freezing significantly less frequent when changing tabs.
This commit is contained in:
Rames The Generic 2024-01-05 17:23:04 -05:00
parent 61a97cd80b
commit 60e20e8f2e
2 changed files with 5 additions and 6 deletions

View File

@ -56,10 +56,10 @@ class CameraWidget:
# Set the event until start is called, otherwise we can block if shutdown is called.
self.cancellation_event.set()
self.capture_event = Event()
self.capture_queue = Queue(maxsize=1)
self.roi_queue = Queue(maxsize=1)
self.capture_queue = Queue(maxsize=2)
self.roi_queue = Queue(maxsize=2)
self.image_queue = Queue(maxsize=1)
self.image_queue = Queue(maxsize=2)
self.ransac = EyeProcessor(
self.config,

View File

@ -88,8 +88,8 @@ class EyeProcessor:
baseconfig: "EyetrackConfig",
cancellation_event: "threading.Event",
capture_event: "threading.Event",
capture_queue_incoming: "queue.Queue",
image_queue_outgoing: "queue.Queue",
capture_queue_incoming: "queue.Queue(maxsize=2)",
image_queue_outgoing: "queue.Queue(maxsize=2)",
eye_id,
):
self.main_config = EyeTrackSettingsConfig
@ -466,7 +466,6 @@ class EyeProcessor:
self.current_algorithm = EyeInfoOrigin.HSRAC
def HSFM(self):
print("ee")
if self.eye_id in [EyeId.LEFT] and self.settings.gui_circular_crop_left:
self.current_image_gray, self.cct = circle_crop(
self.current_image_gray, self.xc, self.yc, self.cc_radius, self.cct