Add README.md
Browse files
README.md
ADDED
|
@@ -0,0 +1,71 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
license: other
|
| 3 |
+
tags:
|
| 4 |
+
- heal
|
| 5 |
+
- horizon
|
| 6 |
+
---
|
| 7 |
+
|
| 8 |
+
# FCOS (EfficientNet-b3)
|
| 9 |
+
|
| 10 |
+
FCOS eliminates anchors and predicts classification scores, centerness, and distances to box edges per pixel; `BiFPN` performs bidirectional feature fusion across 5 scales to improve small-object detection; training jointly supervises classification, centerness, and regression losses.
|
| 11 |
+
|
| 12 |
+
---
|
| 13 |
+
|
| 14 |
+
## Deployment Metrics
|
| 15 |
+
|
| 16 |
+
### Model Parameters
|
| 17 |
+
|
| 18 |
+
| Model | Model Input | Backbone | Neck | Model Output |
|
| 19 |
+
|---|---|---|---|---|
|
| 20 |
+
| FCOS | Single image `1x3x896x896` | EfficientNet-b3 | `BiFPN` | Detection boxes `(B,N,cls+reg)` |
|
| 21 |
+
|
| 22 |
+
### Accuracy Metrics
|
| 23 |
+
|
| 24 |
+
| March | Metric | float | calibration | qat | hbm |
|
| 25 |
+
| --- | --- | --- | --- | --- | --- |
|
| 26 |
+
| J6M | mAP | 0.4802 | 0.4634 | 0.4773 | 0.4772 |
|
| 27 |
+
|
| 28 |
+
> Results are based on `march = March.NASH_M` (J6M) configuration.
|
| 29 |
+
>
|
| 30 |
+
> HEAL version: heal 0.0.2 / hbdk4-compiler 4.11.11 / horizon_plugin_pytorch 3.3.10.
|
| 31 |
+
|
| 32 |
+
### Performance Metrics
|
| 33 |
+
|
| 34 |
+
> **Performance measurement**: FPS is measured with single-core eight-thread; Latency is measured with single-core single-thread; Memory is peak DDR usage.
|
| 35 |
+
|
| 36 |
+
| March | latency (ms) | fps | Memory Usage |
|
| 37 |
+
|---|---|---|---|
|
| 38 |
+
| J6M | 3.90 | 276.48 | 30.90 |
|
| 39 |
+
| J6P | 2.98 | 1439.97 | 35.10 |
|
| 40 |
+
| J6B | - | - | - |
|
| 41 |
+
|
| 42 |
+
J6B performance is not available for this model.
|
| 43 |
+
|
| 44 |
+
---
|
| 45 |
+
|
| 46 |
+
## Model Overview
|
| 47 |
+
|
| 48 |
+
### Core Design
|
| 49 |
+
|
| 50 |
+
FCOS eliminates anchors and predicts classification scores, centerness, and distances to box edges per pixel; `BiFPN` performs bidirectional feature fusion across 5 scales to improve small-object detection; training jointly supervises classification, centerness, and regression losses.
|
| 51 |
+
|
| 52 |
+
- **Task type**: 2D object detection (2D Object Detection).
|
| 53 |
+
- **backbone**: EfficientNet-b3 (`efficientnet`, `model_type=b3`, `include_top=False` removes classification head, `use_se_block=False`, ReLU activation).
|
| 54 |
+
- **neck**: `BiFPN` (`out_channels=120`, `stack=6`, input stride `[2,4,8,16,32]` → output stride `[8,16,32,64,128]`, `bifpn_sum` fusion).
|
| 55 |
+
- **Detection head**: `FCOSHead` (`feat_channels=120`, `stacked_convs=4`, 5 feature layers stride `[8,16,32,64,128]`, `dequant_output=True`).
|
| 56 |
+
- **Target assignment**: `DynamicFcosTarget` (`topK=10`, classification `FocalLoss`, regression `GIoULoss`).
|
| 57 |
+
- **Post-processing**: `FCOSDecoder` (`score_thr=0.05`, `nms_pre=1000`, NMS `iou_threshold=0.6`, `max_per_img=100`, uses centerness).
|
| 58 |
+
- **Loss**: Classification `FocalLoss` (`alpha=0.25, gamma=2.0`) + centerness `CrossEntropyLoss` (sigmoid) + regression `GIoULoss`.
|
| 59 |
+
- **Model input**: Single image, size `896 × 896`.
|
| 60 |
+
- **Model output**: 80-class detection boxes + confidence scores.
|
| 61 |
+
|
| 62 |
+
### Official Repo and Paper
|
| 63 |
+
|
| 64 |
+
Official repo: https://github.com/tianzhi0549/FCOS
|
| 65 |
+
Paper: https://arxiv.org/abs/1904.01355
|
| 66 |
+
|
| 67 |
+
Note: backbone is EfficientNet-b3; official repo uses a different backbone.
|
| 68 |
+
|
| 69 |
+
### Reference
|
| 70 |
+
|
| 71 |
+
For more J6 chip deployment details, see https://developer.horizon.auto/forum/11335
|