From 71ff356ef03b5d07bcd7a36b79cf95df1206717b Mon Sep 17 00:00:00 2001 From: skal Date: Sat, 14 Feb 2026 00:00:26 +0100 Subject: cnn_test: --weights now overrides layer config from .bin file When using --weights option: - Layer count and kernel sizes loaded from binary header - Warnings shown if --layers or --cnn-version specified - Help text clarifies precedence order - Binary weights always take precedence over CLI args Updated documentation: - doc/CNN_TEST_TOOL.md: Usage examples with --weights - doc/HOWTO.md: Runtime weight loading example handoff(Claude): cnn_test --weights config override --- doc/HOWTO.md | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'doc/HOWTO.md') diff --git a/doc/HOWTO.md b/doc/HOWTO.md index 85ce801..3746d65 100644 --- a/doc/HOWTO.md +++ b/doc/HOWTO.md @@ -268,6 +268,9 @@ See `doc/ASSET_SYSTEM.md` and `doc/WORKSPACE_SYSTEM.md`. # CNN v2 (recommended, fully functional) ./build/cnn_test input.png output.png --cnn-version 2 +# CNN v2 with runtime weight loading (loads layer config from .bin) +./build/cnn_test input.png output.png --weights checkpoints/checkpoint_epoch_100.pth.bin + # CNN v1 (produces incorrect output, debug only) ./build/cnn_test input.png output.png --cnn-version 1 @@ -282,6 +285,8 @@ See `doc/ASSET_SYSTEM.md` and `doc/WORKSPACE_SYSTEM.md`. - **CNN v2:** ✅ Fully functional, matches CNNv2Effect - **CNN v1:** ⚠️ Produces incorrect output, use CNNEffect in demo for validation +**Note:** `--weights` loads layer count and kernel sizes from the binary file, overriding `--layers` and forcing CNN v2. + See `doc/CNN_TEST_TOOL.md` for full documentation. --- -- cgit v1.2.3