Upload README.md with huggingface_hub
Browse files
README.md
CHANGED
@@ -14,7 +14,7 @@ tags:
|
|
14 |
|
15 |
Light-weight model that segments a person from the background in square or landscape selfie and video conference imagery.
|
16 |
|
17 |
-
This model is an implementation of MediaPipe-Selfie-Segmentation found [here](
|
18 |
This repository provides scripts to run MediaPipe-Selfie-Segmentation on Qualcomm® devices.
|
19 |
More details on model performance across various devices, can be found
|
20 |
[here](https://aihub.qualcomm.com/models/mediapipe_selfie).
|
@@ -31,15 +31,32 @@ More details on model performance across various devices, can be found
|
|
31 |
- Model size: 454 KB
|
32 |
- Number of output classes: 6
|
33 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
34 |
|
35 |
|
36 |
|
37 |
-
| Device | Chipset | Target Runtime | Inference Time (ms) | Peak Memory Range (MB) | Precision | Primary Compute Unit | Target Model
|
38 |
-
| ---|---|---|---|---|---|---|---|
|
39 |
-
| Samsung Galaxy S23 Ultra (Android 13) | Snapdragon® 8 Gen 2 | TFLite | 0.699 ms | 0 - 2 MB | FP16 | NPU | [MediaPipe-Selfie-Segmentation.tflite](https://huggingface.co/qualcomm/MediaPipe-Selfie-Segmentation/blob/main/MediaPipe-Selfie-Segmentation.tflite)
|
40 |
-
| Samsung Galaxy S23 Ultra (Android 13) | Snapdragon® 8 Gen 2 | QNN Model Library | 0.775 ms | 1 - 4 MB | FP16 | NPU | [MediaPipe-Selfie-Segmentation.so](https://huggingface.co/qualcomm/MediaPipe-Selfie-Segmentation/blob/main/MediaPipe-Selfie-Segmentation.so)
|
41 |
-
|
42 |
-
|
43 |
|
44 |
## Installation
|
45 |
|
@@ -95,16 +112,16 @@ device. This script does the following:
|
|
95 |
```bash
|
96 |
python -m qai_hub_models.models.mediapipe_selfie.export
|
97 |
```
|
98 |
-
|
99 |
```
|
100 |
-
|
101 |
-
|
102 |
-
|
103 |
-
|
104 |
-
|
105 |
-
|
106 |
-
|
107 |
-
|
|
|
108 |
```
|
109 |
|
110 |
|
@@ -203,15 +220,19 @@ provides instructions on how to use the `.so` shared library in an Android appl
|
|
203 |
Get more details on MediaPipe-Selfie-Segmentation's performance across various devices [here](https://aihub.qualcomm.com/models/mediapipe_selfie).
|
204 |
Explore all available models on [Qualcomm® AI Hub](https://aihub.qualcomm.com/)
|
205 |
|
|
|
206 |
## License
|
207 |
-
|
208 |
-
|
209 |
-
|
|
|
210 |
|
211 |
## References
|
212 |
* [Image segmentation guide](https://developers.google.com/mediapipe/solutions/vision/image_segmenter/)
|
213 |
* [Source Model Implementation](https://github.com/google/mediapipe/tree/master/mediapipe/modules/selfie_segmentation)
|
214 |
|
|
|
|
|
215 |
## Community
|
216 |
* Join [our AI Hub Slack community](https://aihub.qualcomm.com/community/slack) to collaborate, post questions and learn more about on-device AI.
|
217 |
* For questions or feedback please [reach out to us](mailto:ai-hub-support@qti.qualcomm.com).
|
|
|
14 |
|
15 |
Light-weight model that segments a person from the background in square or landscape selfie and video conference imagery.
|
16 |
|
17 |
+
This model is an implementation of MediaPipe-Selfie-Segmentation found [here]({source_repo}).
|
18 |
This repository provides scripts to run MediaPipe-Selfie-Segmentation on Qualcomm® devices.
|
19 |
More details on model performance across various devices, can be found
|
20 |
[here](https://aihub.qualcomm.com/models/mediapipe_selfie).
|
|
|
31 |
- Model size: 454 KB
|
32 |
- Number of output classes: 6
|
33 |
|
34 |
+
| Model | Device | Chipset | Target Runtime | Inference Time (ms) | Peak Memory Range (MB) | Precision | Primary Compute Unit | Target Model
|
35 |
+
|---|---|---|---|---|---|---|---|---|
|
36 |
+
| MediaPipe-Selfie-Segmentation | Samsung Galaxy S23 | Snapdragon® 8 Gen 2 | TFLITE | 0.698 ms | 0 - 2 MB | FP16 | NPU | [MediaPipe-Selfie-Segmentation.tflite](https://huggingface.co/qualcomm/MediaPipe-Selfie-Segmentation/blob/main/MediaPipe-Selfie-Segmentation.tflite) |
|
37 |
+
| MediaPipe-Selfie-Segmentation | Samsung Galaxy S23 | Snapdragon® 8 Gen 2 | QNN | 0.774 ms | 1 - 25 MB | FP16 | NPU | [MediaPipe-Selfie-Segmentation.so](https://huggingface.co/qualcomm/MediaPipe-Selfie-Segmentation/blob/main/MediaPipe-Selfie-Segmentation.so) |
|
38 |
+
| MediaPipe-Selfie-Segmentation | Samsung Galaxy S23 | Snapdragon® 8 Gen 2 | ONNX | 1.32 ms | 0 - 3 MB | FP16 | NPU | [MediaPipe-Selfie-Segmentation.onnx](https://huggingface.co/qualcomm/MediaPipe-Selfie-Segmentation/blob/main/MediaPipe-Selfie-Segmentation.onnx) |
|
39 |
+
| MediaPipe-Selfie-Segmentation | Samsung Galaxy S24 | Snapdragon® 8 Gen 3 | TFLITE | 0.472 ms | 0 - 29 MB | FP16 | NPU | [MediaPipe-Selfie-Segmentation.tflite](https://huggingface.co/qualcomm/MediaPipe-Selfie-Segmentation/blob/main/MediaPipe-Selfie-Segmentation.tflite) |
|
40 |
+
| MediaPipe-Selfie-Segmentation | Samsung Galaxy S24 | Snapdragon® 8 Gen 3 | QNN | 0.525 ms | 0 - 13 MB | FP16 | NPU | [MediaPipe-Selfie-Segmentation.so](https://huggingface.co/qualcomm/MediaPipe-Selfie-Segmentation/blob/main/MediaPipe-Selfie-Segmentation.so) |
|
41 |
+
| MediaPipe-Selfie-Segmentation | Samsung Galaxy S24 | Snapdragon® 8 Gen 3 | ONNX | 0.899 ms | 0 - 32 MB | FP16 | NPU | [MediaPipe-Selfie-Segmentation.onnx](https://huggingface.co/qualcomm/MediaPipe-Selfie-Segmentation/blob/main/MediaPipe-Selfie-Segmentation.onnx) |
|
42 |
+
| MediaPipe-Selfie-Segmentation | QCS8550 (Proxy) | QCS8550 Proxy | TFLITE | 0.696 ms | 0 - 1 MB | FP16 | NPU | [MediaPipe-Selfie-Segmentation.tflite](https://huggingface.co/qualcomm/MediaPipe-Selfie-Segmentation/blob/main/MediaPipe-Selfie-Segmentation.tflite) |
|
43 |
+
| MediaPipe-Selfie-Segmentation | QCS8550 (Proxy) | QCS8550 Proxy | QNN | 0.756 ms | 1 - 2 MB | FP16 | NPU | Use Export Script |
|
44 |
+
| MediaPipe-Selfie-Segmentation | SA8255 (Proxy) | SA8255P Proxy | TFLITE | 0.698 ms | 0 - 2 MB | FP16 | NPU | [MediaPipe-Selfie-Segmentation.tflite](https://huggingface.co/qualcomm/MediaPipe-Selfie-Segmentation/blob/main/MediaPipe-Selfie-Segmentation.tflite) |
|
45 |
+
| MediaPipe-Selfie-Segmentation | SA8255 (Proxy) | SA8255P Proxy | QNN | 0.755 ms | 1 - 2 MB | FP16 | NPU | Use Export Script |
|
46 |
+
| MediaPipe-Selfie-Segmentation | SA8775 (Proxy) | SA8775P Proxy | TFLITE | 0.697 ms | 0 - 68 MB | FP16 | NPU | [MediaPipe-Selfie-Segmentation.tflite](https://huggingface.co/qualcomm/MediaPipe-Selfie-Segmentation/blob/main/MediaPipe-Selfie-Segmentation.tflite) |
|
47 |
+
| MediaPipe-Selfie-Segmentation | SA8775 (Proxy) | SA8775P Proxy | QNN | 0.76 ms | 1 - 2 MB | FP16 | NPU | Use Export Script |
|
48 |
+
| MediaPipe-Selfie-Segmentation | SA8650 (Proxy) | SA8650P Proxy | TFLITE | 0.704 ms | 0 - 2 MB | FP16 | NPU | [MediaPipe-Selfie-Segmentation.tflite](https://huggingface.co/qualcomm/MediaPipe-Selfie-Segmentation/blob/main/MediaPipe-Selfie-Segmentation.tflite) |
|
49 |
+
| MediaPipe-Selfie-Segmentation | SA8650 (Proxy) | SA8650P Proxy | QNN | 0.763 ms | 1 - 2 MB | FP16 | NPU | Use Export Script |
|
50 |
+
| MediaPipe-Selfie-Segmentation | QCS8450 (Proxy) | QCS8450 Proxy | TFLITE | 0.934 ms | 0 - 28 MB | FP16 | NPU | [MediaPipe-Selfie-Segmentation.tflite](https://huggingface.co/qualcomm/MediaPipe-Selfie-Segmentation/blob/main/MediaPipe-Selfie-Segmentation.tflite) |
|
51 |
+
| MediaPipe-Selfie-Segmentation | QCS8450 (Proxy) | QCS8450 Proxy | QNN | 0.995 ms | 1 - 16 MB | FP16 | NPU | Use Export Script |
|
52 |
+
| MediaPipe-Selfie-Segmentation | Snapdragon 8 Elite QRD | Snapdragon® 8 Elite | TFLITE | 0.367 ms | 0 - 18 MB | FP16 | NPU | [MediaPipe-Selfie-Segmentation.tflite](https://huggingface.co/qualcomm/MediaPipe-Selfie-Segmentation/blob/main/MediaPipe-Selfie-Segmentation.tflite) |
|
53 |
+
| MediaPipe-Selfie-Segmentation | Snapdragon 8 Elite QRD | Snapdragon® 8 Elite | QNN | 0.518 ms | 0 - 10 MB | FP16 | NPU | Use Export Script |
|
54 |
+
| MediaPipe-Selfie-Segmentation | Snapdragon 8 Elite QRD | Snapdragon® 8 Elite | ONNX | 0.871 ms | 0 - 23 MB | FP16 | NPU | [MediaPipe-Selfie-Segmentation.onnx](https://huggingface.co/qualcomm/MediaPipe-Selfie-Segmentation/blob/main/MediaPipe-Selfie-Segmentation.onnx) |
|
55 |
+
| MediaPipe-Selfie-Segmentation | Snapdragon X Elite CRD | Snapdragon® X Elite | QNN | 0.908 ms | 1 - 1 MB | FP16 | NPU | Use Export Script |
|
56 |
+
| MediaPipe-Selfie-Segmentation | Snapdragon X Elite CRD | Snapdragon® X Elite | ONNX | 1.367 ms | 2 - 2 MB | FP16 | NPU | [MediaPipe-Selfie-Segmentation.onnx](https://huggingface.co/qualcomm/MediaPipe-Selfie-Segmentation/blob/main/MediaPipe-Selfie-Segmentation.onnx) |
|
57 |
|
58 |
|
59 |
|
|
|
|
|
|
|
|
|
|
|
|
|
60 |
|
61 |
## Installation
|
62 |
|
|
|
112 |
```bash
|
113 |
python -m qai_hub_models.models.mediapipe_selfie.export
|
114 |
```
|
|
|
115 |
```
|
116 |
+
Profiling Results
|
117 |
+
------------------------------------------------------------
|
118 |
+
MediaPipe-Selfie-Segmentation
|
119 |
+
Device : Samsung Galaxy S23 (13)
|
120 |
+
Runtime : TFLITE
|
121 |
+
Estimated inference time (ms) : 0.7
|
122 |
+
Estimated peak memory usage (MB): [0, 2]
|
123 |
+
Total # Ops : 118
|
124 |
+
Compute Unit(s) : NPU (118 ops)
|
125 |
```
|
126 |
|
127 |
|
|
|
220 |
Get more details on MediaPipe-Selfie-Segmentation's performance across various devices [here](https://aihub.qualcomm.com/models/mediapipe_selfie).
|
221 |
Explore all available models on [Qualcomm® AI Hub](https://aihub.qualcomm.com/)
|
222 |
|
223 |
+
|
224 |
## License
|
225 |
+
* The license for the original implementation of MediaPipe-Selfie-Segmentation can be found [here](https://github.com/google/mediapipe/blob/master/LICENSE).
|
226 |
+
* The license for the compiled assets for on-device deployment can be found [here](https://qaihub-public-assets.s3.us-west-2.amazonaws.com/qai-hub-models/Qualcomm+AI+Hub+Proprietary+License.pdf)
|
227 |
+
|
228 |
+
|
229 |
|
230 |
## References
|
231 |
* [Image segmentation guide](https://developers.google.com/mediapipe/solutions/vision/image_segmenter/)
|
232 |
* [Source Model Implementation](https://github.com/google/mediapipe/tree/master/mediapipe/modules/selfie_segmentation)
|
233 |
|
234 |
+
|
235 |
+
|
236 |
## Community
|
237 |
* Join [our AI Hub Slack community](https://aihub.qualcomm.com/community/slack) to collaborate, post questions and learn more about on-device AI.
|
238 |
* For questions or feedback please [reach out to us](mailto:ai-hub-support@qti.qualcomm.com).
|