@camera.ui/camera-ui-coreml 0.0.8 → 0.0.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -6,7 +6,7 @@
6
6
  "description": "Model to use for object detection",
7
7
  "required": true,
8
8
  "store": true,
9
- "defaultValue": "yolov9m_320",
9
+ "defaultValue": "yolov10n_320",
10
10
  "enum": [
11
11
  "yolo3-tinyu",
12
12
  "yolo3-tinyu_320",
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "displayName": "CoreML",
3
3
  "name": "@camera.ui/camera-ui-coreml",
4
- "version": "0.0.8",
4
+ "version": "0.0.10",
5
5
  "description": "camera.ui coreml plugin",
6
6
  "author": "seydx (https://github.com/seydx/camera.ui)",
7
7
  "main": "./src/main.py",
@@ -21,7 +21,7 @@
21
21
  "url": "https://github.com/seydx/camera.ui/issues"
22
22
  },
23
23
  "engines": {
24
- "camera.ui": ">=0.0.1",
24
+ "camera.ui": ">=0.0.17",
25
25
  "node": ">=18.12.0"
26
26
  },
27
27
  "homepage": "https://github.com/seydx/camera.ui#readme",
package/requirements.txt CHANGED
@@ -1,4 +1,4 @@
1
1
  coremltools==7.2
2
- camera-ui-python-types==0.1.81
2
+ camera-ui-python-types==0.1.82
3
3
  requests==2.32.3
4
4
  Pillow==10.4.0
@@ -86,6 +86,9 @@ class CameraDetector:
86
86
  while not self.closed:
87
87
  try:
88
88
  async for frame in self.camera.get_motion_frames():
89
+ if self.closed:
90
+ break
91
+
89
92
  frame_image = await frame.to_image(
90
93
  {
91
94
  "format": {"to": "rgb"},
@@ -118,7 +121,7 @@ class CameraDetector:
118
121
 
119
122
  await self.camera.update_state("object", {"detections": detections})
120
123
  except asyncio.CancelledError:
121
- pass
124
+ break
122
125
  except Exception as error:
123
126
  self.logger.error(self.camera.name, "Error generating motion frames", error)
124
127
  self.logger.log(self.camera.name, "Restarting object detection in 5 seconds...")
@@ -19,12 +19,14 @@ available_models = [
19
19
  "yolov9m_320",
20
20
  "yolov9c",
21
21
  "yolov9c_320",
22
- # "yolov10n",
23
- # "yolov10n_320",
24
- # "yolov10s",
25
- # "yolov10s_320",
26
- # "yolov10m",
27
- # "yolov10m_320",
22
+ "yolov10n",
23
+ "yolov10n_320",
24
+ "yolov10s",
25
+ "yolov10s_320",
26
+ "yolov10m",
27
+ "yolov10m_320",
28
+ "yolov10l",
29
+ "yolov10l_320",
28
30
  ]
29
31
 
30
32
  available_precision = ["INT8", "FP16"]
package/src/main.py CHANGED
@@ -88,7 +88,7 @@ class CoreML(ObjectDetectionPlugin):
88
88
  "title": "Model",
89
89
  "description": "Model to use for object detection",
90
90
  "required": True,
91
- "defaultValue": "yolov9m_320",
91
+ "defaultValue": "yolov10n_320",
92
92
  "enum": available_models,
93
93
  },
94
94
  "precision": {