This shows you the differences between two versions of the page.
| Both sides previous revision Previous revision Next revision | Previous revision | ||
|
products:sbc:vim4:npu:demos:vgg16 [2024/10/28 21:11] louis |
products:sbc:vim4:npu:demos:vgg16 [2026/04/02 02:46] (current) nick |
||
|---|---|---|---|
| Line 1: | Line 1: | ||
| ~~tag> | ~~tag> | ||
| + | |||
| + | **Doc for version ddk-3.4.7.7** | ||
| ====== VGG16 TensorFlow Keras VIM4 Demo 4 ====== | ====== VGG16 TensorFlow Keras VIM4 Demo 4 ====== | ||
| {{indexmenu_n> | {{indexmenu_n> | ||
| + | |||
| + | ===== Introduction ===== | ||
| + | |||
| + | VGG16 is a classification model. It can assign a single label to an entire image. | ||
| + | |||
| + | Image and inference results on VIM4. | ||
| + | |||
| + | {{: | ||
| + | |||
| + | {{: | ||
| [[https:// | [[https:// | ||
| Line 28: | Line 40: | ||
| ``` | ``` | ||
| - | ===== Get Convert Tool ===== | + | ==== Get convert tool ==== |
| + | |||
| + | You can find the SDK here: [[dl> | ||
| ```shell | ```shell | ||
| - | $ git lfs install | + | $ wget https://dl.khadas.com/products/ |
| - | $ git lfs clone https://gitlab.com/khadas/ | + | $ tar xvzf vim4_npu_sdk-ddk-3.4.7.7-250508.tgz |
| - | $ cd vim4_npu_sdk | + | $ cd vim4_npu_sdk-ddk-3.4.7.7-250508 |
| $ ls | $ ls | ||
| - | adla-toolkit-binary | + | adla-toolkit-binary |
| ``` | ``` | ||
| - | * '' | + | * '' |
| * '' | * '' | ||
| * '' | * '' | ||
| + | * '' | ||
| - | ==== Get convert tool ==== | + | <WRAP important> |
| - | + | If your kernel is older than 241129, please use branch npu-ddk-1.7.5.5. | |
| - | Download Tool from [[gl> | + | </WRAP> |
| - | + | ||
| - | ```shell | + | |
| - | $ git clone https:// | + | |
| - | ``` | + | |
| ==== Convert ==== | ==== Convert ==== | ||
| Line 82: | Line 93: | ||
| --quantize-dtype int8 --outdir tensorflow_output \ | --quantize-dtype int8 --outdir tensorflow_output \ | ||
| --channel-mean-value " | --channel-mean-value " | ||
| + | --inference-input-type " | ||
| + | --inference-output-type " | ||
| --source-file vgg16_dataset.txt \ | --source-file vgg16_dataset.txt \ | ||
| --iterations 500 \ | --iterations 500 \ | ||
| Line 103: | Line 116: | ||
| $ git clone https:// | $ git clone https:// | ||
| ``` | ``` | ||
| + | |||
| + | <WRAP important> | ||
| + | If your kernel is older than 241129, please use version before tag ddk-3.4.7.7. | ||
| + | </ | ||
| ==== Install dependencies ==== | ==== Install dependencies ==== | ||
| Line 126: | Line 143: | ||
| # Run | # Run | ||
| - | $ sudo ./vgg16 -m ../ | + | $ ./vgg16 -m ../ |
| ``` | ``` | ||