diff options
| author | skal <pascal.massimino@gmail.com> | 2026-02-13 14:50:09 +0100 |
|---|---|---|
| committer | skal <pascal.massimino@gmail.com> | 2026-02-13 14:50:09 +0100 |
| commit | 4d1df90124418a57cb9ed62eab25497d53a47c8c (patch) | |
| tree | 1f7ccd9a3cea593cbb39c53d839cdd8be97c050f /doc/CNN_V2.md | |
| parent | c01f3e6b676134fe01036aabbd063b690c9fd1ed (diff) | |
CNN v2 web tool: Fix layer naming and visualization bugs
- Align layer naming with codebase: Layer 0/1/2 (not Layer 1/2/3)
- Split static features: Static 0-3 (p0-p3) and Static 4-7 (uv,sin,bias)
- Fix Layer 2 not appearing: removed isOutput filter from layerOutputs
- Fix canvas context switching: force clear before recreation
- Disable static buttons in weights mode
- Add ASCII pipeline diagram to CNN_V2.md
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Diffstat (limited to 'doc/CNN_V2.md')
| -rw-r--r-- | doc/CNN_V2.md | 54 |
1 files changed, 54 insertions, 0 deletions
diff --git a/doc/CNN_V2.md b/doc/CNN_V2.md index b0aa24c..e56b022 100644 --- a/doc/CNN_V2.md +++ b/doc/CNN_V2.md @@ -32,6 +32,60 @@ Input RGBD → Static Features Compute → CNN Layers → Output RGBA └─ computed once/frame ─┘ └─ multi-pass ─┘ ``` +**Detailed Data Flow:** + +``` + ┌─────────────────────────────────────────┐ + │ Static Features (computed once) │ + │ 8D: p0,p1,p2,p3,uv_x,uv_y,sin10x,bias │ + └──────────────┬──────────────────────────┘ + │ + │ 8D (broadcast to all layers) + ├───────────────────────────┐ + │ │ + ┌──────────────┐ │ │ + │ Input RGBD │──────────────┤ │ + │ 4D │ 4D │ │ + └──────────────┘ │ │ + ▼ │ + ┌────────────┐ │ + │ Layer 0 │ (12D input) │ + │ (CNN) │ = 4D + 8D │ + │ 12D → 4D │ │ + └─────┬──────┘ │ + │ 4D output │ + │ │ + ├───────────────────────────┘ + │ │ + ▼ │ + ┌────────────┐ │ + │ Layer 1 │ (12D input) │ + │ (CNN) │ = 4D + 8D │ + │ 12D → 4D │ │ + └─────┬──────┘ │ + │ 4D output │ + │ │ + ├───────────────────────────┘ + ▼ │ + ... │ + │ │ + ▼ │ + ┌────────────┐ │ + │ Layer N │ (12D input) │ + │ (output) │◄──────────────────┘ + │ 12D → 4D │ + └─────┬──────┘ + │ 4D (RGBA) + ▼ + Output +``` + +**Key Points:** +- Static features computed once, broadcast to all CNN layers +- Each layer: previous 4D output + 8D static → 12D input → 4D output +- Ping-pong buffering between layers +- Layer 0 special case: uses input RGBD instead of previous layer output + **Static Features Texture:** - Name: `static_features` - Format: `texture_storage_2d<rgba32uint, write>` (4×u32) |
