Khadas Docs

Amazing Khadas, always amazes you!

User Tools

Site Tools


products:sbc:vim4:npu:demos:densenet

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
products:sbc:vim4:npu:demos:densenet [2023/09/18 01:42]
sravan [Compile and run]
products:sbc:vim4:npu:demos:densenet [2024/01/04 21:23] (current)
louis old revision restored (2023/09/20 01:13)
Line 5: Line 5:
 ===== Get the source code ===== ===== Get the source code =====
  
-We will use a densenet model based on [[gh>YCG09/chinese_ocr]]+We will use a DenseNet model based on [[gh>YCG09/chinese_ocr]]
  
 ```shell ```shell
Line 17: Line 17:
 Follow Docker official documentation to install Docker: [[https://docs.docker.com/engine/install/ubuntu/|Install Docker Engine on Ubuntu]]. Follow Docker official documentation to install Docker: [[https://docs.docker.com/engine/install/ubuntu/|Install Docker Engine on Ubuntu]].
  
-Then fetch the prebuilt NPU Docker Container and run it.+Then fetch the prebuilt NPU Docker container and run it.
  
 ```shell ```shell
Line 35: Line 35:
 ``` ```
  
-After training the model, run the scripts as follows to modify net input and output and convert model to ONNX.+After training the model, run the scripts as follows to modify net input and output and convert the model to ONNX.
  
 <WRAP tip > <WRAP tip >
Line 62: Line 62:
 ``` ```
  
-Enter ''vim4_npu_sdk/demo'' and modify ''convert_adla.sh'' as follows. We should quantize the model to **int16**because it is very inaccurate with **int8**.+Enter ''vim4_npu_sdk/demo'' and modify ''convert_adla.sh'' as follows. We should quantize the model to **int16** because it is very inaccurate with **int8**.
  
 ```bash convert_adla.sh ```bash convert_adla.sh
Line 91: Line 91:
 ``` ```
  
-Run ''convert_adla.sh'' to generate VIM4 model. The converted model is ''xxx.adla'' in ''onnx_output''.+Run ''convert_adla.sh'' to generate the VIM4 model. The converted model is ''xxx.adla'' in ''onnx_output''.
  
 ```shell ```shell
Line 133: Line 133:
  
 <WRAP tip > <WRAP tip >
-If your **DenseNet_ctc** model classes is not the same, please change ''data/class_str.txt'' and the ''OBJ_CLASS_NUM'' in ''include/postprocess.h''.+If your ''densenet_ctc''**DenseNet-CTC** model classes are not the same, please change ''data/class_str.txt'' and the ''OBJ_CLASS_NUM'' in ''include/postprocess.h''.
 </WRAP> </WRAP>
  
Last modified: 2023/09/18 01:42 by sravan