Skip to content

Commit af6156d

Browse files
authored
Removed unnecessary FIFO in cats-vs-dogs for MAX78002 (#235)
1 parent 73382ed commit af6156d

File tree

3 files changed

+54
-2
lines changed

3 files changed

+54
-2
lines changed

gen-demos-max78002.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ python ai8xize.py --test-dir $TARGET --prefix cifar-100-residual --checkpoint-fi
1313
python ai8xize.py --test-dir $TARGET --prefix kws20_v3_1 --checkpoint-file trained/ai87-kws20_v3-qat8-q.pth.tar --config-file networks/ai87-kws20-v3-hwc.yaml --softmax $COMMON_ARGS "$@"
1414
python ai8xize.py --test-dir $TARGET --prefix kws20_v2_1 --checkpoint-file trained/ai87-kws20_v2-qat8-q.pth.tar --config-file networks/ai87-kws20-v2-hwc.yaml --softmax $COMMON_ARGS "$@"
1515
python ai8xize.py --test-dir $TARGET --prefix faceid --checkpoint-file trained/ai85-faceid-qat8-q.pth.tar --config-file networks/faceid.yaml --fifo $COMMON_ARGS "$@"
16-
python ai8xize.py --test-dir $TARGET --prefix cats-dogs --checkpoint-file trained/ai85-catsdogs-qat8-q.pth.tar --config-file networks/cats-dogs-hwc.yaml --fifo --softmax $COMMON_ARGS "$@"
16+
python ai8xize.py --test-dir $TARGET --prefix cats-dogs --checkpoint-file trained/ai85-catsdogs-qat8-q.pth.tar --config-file networks/cats-dogs-hwc-no-fifo.yaml --softmax $COMMON_ARGS "$@"
1717
python ai8xize.py --test-dir $TARGET --prefix camvid_unet --checkpoint-file trained/ai85-camvid-unet-large-fakept-q.pth.tar --config-file networks/camvid-unet-large-fakept.yaml $COMMON_ARGS --overlap-data --mlator --no-unload --max-checklines 8192 "$@"
1818
python ai8xize.py --test-dir $TARGET --prefix aisegment_unet --checkpoint-file trained/ai85-aisegment-unet-large-fakept-q.pth.tar --config-file networks/aisegment-unet-large-fakept.yaml $COMMON_ARGS --overlap-data --mlator --no-unload --max-checklines 8192 "$@"
1919
python ai8xize.py --test-dir $TARGET --prefix cifar-100-effnet2 --checkpoint-file trained/ai87-cifar100-effnet2-qat8-q.pth.tar --config-file networks/ai87-cifar100-effnet2.yaml --softmax $COMMON_ARGS "$@"

networks/cats-dogs-hwc-no-fifo.yaml

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
---
2+
# HWC (big data) configuration for Cats and Dogs image classification
3+
4+
arch: ai85cdnet
5+
dataset: cats_vs_dogs
6+
7+
# Define layer parameters in order of the layer sequence
8+
layers:
9+
- pad: 1
10+
activate: ReLU
11+
out_offset: 0x1000
12+
processors: 0x0000000000000007
13+
data_format: HWC
14+
operation: Conv2d
15+
- max_pool: 2
16+
pool_stride: 2
17+
pad: 1
18+
activate: ReLU
19+
out_offset: 0x2000
20+
processors: 0x000ffff000000000
21+
operation: Conv2d
22+
- max_pool: 2
23+
pool_stride: 2
24+
pad: 1
25+
activate: ReLU
26+
out_offset: 0x0000
27+
processors: 0x00000000ffffffff
28+
operation: Conv2d
29+
- max_pool: 2
30+
pool_stride: 2
31+
pad: 1
32+
activate: ReLU
33+
out_offset: 0x2000
34+
processors: 0xffffffffffffffff
35+
operation: Conv2d
36+
- max_pool: 2
37+
pool_stride: 2
38+
pad: 1
39+
activate: ReLU
40+
out_offset: 0x0000
41+
processors: 0x00000000ffffffff
42+
operation: Conv2d
43+
- pad: 1
44+
activate: ReLU
45+
out_offset: 0x2000
46+
processors: 0xffffffff00000000
47+
operation: Conv2d
48+
- op: mlp
49+
flatten: true
50+
out_offset: 0x1000
51+
output_width: 32
52+
processors: 0x000000000000ffff

scripts/gen_catsdogs_max78002.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,4 @@ DEVICE="MAX78002"
33
TARGET="sdk/Examples/$DEVICE/CNN"
44
COMMON_ARGS="--device $DEVICE --compact-data --mexpress --timer 0 --display-checkpoint --verbose"
55

6-
python ai8xize.py --test-dir $TARGET --prefix cats-dogs --checkpoint-file trained/ai85-catsdogs-qat8-q.pth.tar --config-file networks/cats-dogs-hwc.yaml --fifo --softmax $COMMON_ARGS "$@"
6+
python ai8xize.py --test-dir $TARGET --prefix cats-dogs --checkpoint-file trained/ai85-catsdogs-qat8-q.pth.tar --config-file networks/cats-dogs-hwc-no-fifo.yaml --softmax $COMMON_ARGS "$@"

0 commit comments

Comments
 (0)