summaryrefslogtreecommitdiff
path: root/cnn_v3/README.md
blob: bd54e50ec0fcc3e7a0e45dde9d6304b80d59ea14 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
# CNN v3

Enhanced CNN post-processing with next-generation features.

## Directory Structure

```
cnn_v3/
├── docs/           # Documentation and design notes
├── scripts/        # Training and build automation scripts
├── shaders/        # WGSL compute shaders
├── src/            # C++ implementation
├── tools/          # Testing and validation tools
├── training/       # Training pipeline
│   ├── input/      # Source images for training
│   ├── target_1/   # Style 1 target images
│   └── target_2/   # Style 2 target images
└── weights/        # Trained model weights (binary format)
```

## Training Data

Training images are tracked in the repository:
- `training/input/` - Original input images
- `training/target_1/` - First style transformation targets
- `training/target_2/` - Second style transformation targets

Multiple target directories allow training different stylistic transformations from the same input set.

Add images directly to these directories and commit them.

## Status

**Phases 1–9 complete.** 38/38 tests pass. Training bugs fixed (2026-03-27).

| Phase | Status |
|-------|--------|
| 1 — G-buffer (raster + pack) | ✅ |
| 2 — Training infrastructure | ✅ |
| 3 — WGSL U-Net shaders | ✅ |
| 4 — C++ CNNv3Effect + FiLM | ✅ |
| 5 — Parity validation | ✅ max_err=4.88e-4 |
| 6 — Training script | ✅ train_cnn_v3.py |
| 7 — Validation tools | ✅ GBufViewEffect + web sample loader |
| 8 — Architecture upgrade [8,16] | ✅ enc_channels=[8,16], 16ch split into lo/hi pairs |
| 9 — Training bug fixes | ✅ dec0 ReLU removed, FiLM MLP loaded from .bin |

See `cnn_v3/docs/HOWTO.md` for the practical playbook (§9 covers validation tools).
See `cnn_v3/docs/CNN_V3.md` for full design.
See `cnn_v2/` for reference implementation.