ruisv commited on
Commit
615a4a9
Β·
verified Β·
1 Parent(s): 3d58eee

Compiled BPU models for RDK S100/S100P

Browse files
Files changed (4) hide show
  1. .gitattributes +2 -0
  2. README.md +86 -0
  3. las2_m_crop_nashm.hbm +3 -0
  4. las2_m_int16_nashm.hbm +3 -0
.gitattributes CHANGED
@@ -33,3 +33,5 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
33
  *.zip filter=lfs diff=lfs merge=lfs -text
34
  *.zst filter=lfs diff=lfs merge=lfs -text
35
  *tfevents* filter=lfs diff=lfs merge=lfs -text
 
 
 
33
  *.zip filter=lfs diff=lfs merge=lfs -text
34
  *.zst filter=lfs diff=lfs merge=lfs -text
35
  *tfevents* filter=lfs diff=lfs merge=lfs -text
36
+ las2_m_crop_nashm.hbm filter=lfs diff=lfs merge=lfs -text
37
+ las2_m_int16_nashm.hbm filter=lfs diff=lfs merge=lfs -text
README.md ADDED
@@ -0,0 +1,86 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: mit
3
+ library_name: bcdl
4
+ tags:
5
+ - rdk-s100
6
+ - rdk-s100p
7
+ - d-robotics
8
+ - bpu
9
+ - hbm
10
+ - depth-estimation
11
+ - stereo
12
+ ---
13
+
14
+ # Lite Any Stereo V2 for RDK S100/S100P β€” zero-shot stereo disparity
15
+
16
+ Compiled BPU models (`.hbm`) for the **D-Robotics RDK S100 / S100P**, ready to
17
+ load β€” no ONNX export, no calibration, no `hb_compile`. Built and measured with
18
+ [**BCDL**](https://github.com/ruisv/bcdl), a C++17 inference and media library
19
+ for the RDK S-series with Python bindings.
20
+
21
+ Upstream: [Lite Any Stereo V2](https://github.com/Tinker-Twins/LiteAnyStereo) (M)
22
+
23
+ > [!TIP]
24
+ > **Redistributable, including commercially.** The licence chain was checked on
25
+ > the code, the pretrained weights it started from, and the data it was trained
26
+ > on β€” all three, because a permissive repository badge does not by itself say
27
+ > anything about the weights. See [Licence](#licence).
28
+
29
+ ## Files
30
+
31
+ | file | what it is |
32
+ |---|---|
33
+ | `las2_m_crop_nashm.hbm` | centre-crop-fit calibration, 640x480 β€” 38.8 MB |
34
+ | `las2_m_int16_nashm.hbm` | resize-fit calibration, 640x480 β€” 39.3 MB |
35
+
36
+ ## Measured on an S100P
37
+
38
+ | stage | latency | throughput |
39
+ |---|---|---|
40
+ | either build | 13.70 ms | 73 FPS |
41
+
42
+ `hrt_model_exec perf`, one thread, minimum of three runs, on a board first gated
43
+ against its own previously recorded numbers. **BPU time only** β€” CPU
44
+ pre/post-processing is on top and is listed per task in BCDL's
45
+ [benchmark results](https://github.com/ruisv/bcdl/blob/main/benchmarks/RESULTS.md).
46
+
47
+ ## Use it
48
+
49
+ ```bash
50
+ conda install -c https://mirrors.ruis.ai/conda -c conda-forge bcdl
51
+ ```
52
+
53
+ ```python
54
+ import bcdl
55
+ engine = bcdl.Engine("las2_m_crop_nashm.hbm")
56
+ print(engine.input_shape(0), engine.output_shape(0))
57
+ ```
58
+
59
+ Each task has a decoder in BCDL that turns those raw outputs into boxes,
60
+ keypoints, masks, disparity or text β€” see the
61
+ [Python API](https://github.com/ruisv/bcdl/blob/main/docs/API.md)
62
+ ([δΈ­ζ–‡](https://github.com/ruisv/bcdl/blob/main/docs/API.zh.md)).
63
+
64
+ ## What to know before deploying
65
+
66
+ **Two calibration modes, and you must match the one you letterbox with.** `_crop`
67
+ was calibrated on centre-cropped pairs and `_int16` on resize-fitted ones; feed a
68
+ build the geometry it was not calibrated for and the disparity degrades quietly
69
+ rather than failing.
70
+
71
+ All-2D and feed-forward β€” no 3-D cost volume β€” which is exactly why it runs at
72
+ 73 FPS here. Cost-volume stereo of comparable quality took ~40 s/frame on this
73
+ part and was abandoned.
74
+
75
+ ## Licence
76
+
77
+ MIT on the code and the weights. One thing worth knowing rather than a term passed down: the release was distilled from FoundationStereo, whose NVIDIA licence is research-only. That is upstream's compliance question, but look at it before a commercial build.
78
+
79
+ **BCDL itself is Apache-2.0 and is unrelated to these terms** β€” it is a
80
+ general-purpose runtime that loads any `.hbm`. The licence above constrains
81
+ *these weights and this compiled artefact*.
82
+
83
+ The conversion recipe β€” ONNX export, calibration, `hb_compile` config and the
84
+ acceptance numbers β€” is public in
85
+ [**bcdl-model-zoo**](https://github.com/ruisv/bcdl-model-zoo), so this build can
86
+ be reproduced or retargeted rather than taken on trust.
las2_m_crop_nashm.hbm ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:323f567365f70ab1ea59e42364560293a8b8a2eb057df52e02fa8d67d1b7d06d
3
+ size 40700800
las2_m_int16_nashm.hbm ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:78caecfa9d31a954dbd77c45fd2acd06e98fa5efe779e2a064634ba4e01e7908
3
+ size 41197264