Instructions to use litert-community/efficientnet_b0 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- LiteRT
How to use litert-community/efficientnet_b0 with LiteRT:
# No code snippets available yet for this library. # To use this model, check the repository files and the library's documentation. # Want to help? PRs adding snippets are welcome at: # https://github.com/huggingface/huggingface.js
- Notebooks
- Google Colab
- Kaggle
Replace dynamic-range int8 with weight-only int8
#3
by mlboydaisuke - opened
README.md
CHANGED
|
@@ -28,12 +28,6 @@ model-index:
|
|
| 28 |
- name: Top 5 Accuracy (Full Precision)
|
| 29 |
type: accuracy
|
| 30 |
value: 0.9353
|
| 31 |
-
- name: Top 1 Accuracy (Dynamic Quantized wi8 afp32)
|
| 32 |
-
type: accuracy
|
| 33 |
-
value: 0.7047
|
| 34 |
-
- name: Top 5 Accuracy (Dynamic Quantized wi8 afp32)
|
| 35 |
-
type: accuracy
|
| 36 |
-
value: 0.8950
|
| 37 |
---
|
| 38 |
|
| 39 |
# EfficientNet B0
|
|
@@ -53,6 +47,16 @@ acc@1 (on ImageNet-1K): 77.692%
|
|
| 53 |
acc@5 (on ImageNet-1K): 93.532%
|
| 54 |
num_params: 5,288,548
|
| 55 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 56 |
## How to Use
|
| 57 |
|
| 58 |
**1. Install Dependencies** Ensure your Python environment is set up with the required libraries. Run the following command in your terminal:
|
|
|
|
| 28 |
- name: Top 5 Accuracy (Full Precision)
|
| 29 |
type: accuracy
|
| 30 |
value: 0.9353
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 31 |
---
|
| 32 |
|
| 33 |
# EfficientNet B0
|
|
|
|
| 47 |
acc@5 (on ImageNet-1K): 93.532%
|
| 48 |
num_params: 5,288,548
|
| 49 |
|
| 50 |
+
### Quantized variant
|
| 51 |
+
|
| 52 |
+
`efficientnet_b0_weight_only_wi8_afp32.tflite` is a weight-only int8
|
| 53 |
+
quantization of the same weights (about 3.5x smaller than float32).
|
| 54 |
+
Weight-only quantization is used instead of dynamic-range quantization
|
| 55 |
+
because EfficientNet's SE and SiLU layers are sensitive to activation
|
| 56 |
+
quantization; in a spot check against the float model the weight-only
|
| 57 |
+
file keeps the top-1 predictions on real photos with a minimum logit
|
| 58 |
+
correlation of 0.996.
|
| 59 |
+
|
| 60 |
## How to Use
|
| 61 |
|
| 62 |
**1. Install Dependencies** Ensure your Python environment is set up with the required libraries. Run the following command in your terminal:
|
efficientnet_b0_dynamic_wi8_afp32.tflite → efficientnet_b0_weight_only_wi8_afp32.tflite
RENAMED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
-
size
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:16bc1c4fa541cef382b37f204458882862468638c7ccae7f8cb6b249e4788394
|
| 3 |
+
size 6032208
|