Skip to content

Add object detection, tracking, mobile notifications, and search to any security camera.

use setstate on global settings

Rory Clear78ec687c704c
diff --git a/clearcam.py b/clearcam.py
index e46fba9..cb4e74a 100644
--- a/clearcam.py
+++ b/clearcam.py
@@ -1398,6 +1398,11 @@ class GlobalSettings:
self.qwen_size = qwen_size
self.qwen_prompt = qwen_prompt
+ # add any new properties here
+ def __setstate__(self, state):
+ self.__dict__.update(state)
+ if not hasattr(self, "qwen_prompt"): self.qwen_prompt = "What has been detected on my CCTV camera? Write in one short sentence"
+
def secret_settings(settings):
return GlobalSettings(
use_clip=settings.use_clip,