Conversation
|
fengshuai03 seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account. You have signed the CLA already but the status is still pending? Let us recheck it. |
| @@ -0,0 +1 @@ | |||
| ./build/clas_system ./tools/config.txt /work/Docs/models/tutorials/mobilenetv3_prod/Step6/images/demo.jpg | |||
|
|
||
| # cls config | ||
| cls_model_path /work/PaddleClas/deploy/cpp/mobilenet_v3_small_infer/inference.pdmodel | ||
| cls_params_path /work/PaddleClas/deploy/cpp/mobilenet_v3_small_infer/inference.pdiparams |
There was a problem hiding this comment.
这里路径建议都修改为相对路径哈,方便开发者在没有该绝对路径的情况下也可以复现
| @@ -0,0 +1,21 @@ | |||
| OPENCV_DIR=/work/PaddleClas/deploy/cpp/opencv-3.4.7/opencv3/ | |||
There was a problem hiding this comment.
这里建议写一个注释,修改为自己opencv库所在的绝对路径
|
|
||
| #include <include/preprocess_op.h> | ||
|
|
||
| namespace PaddleClas { |
There was a problem hiding this comment.
namespace由PaddleClas修改为MobileNetV3吧~下面同理
|
|
||
| ### 1.1 编译opencv库 | ||
|
|
||
| * 首先需要从opencv官网上下载在Linux环境下源码编译的包,以3.4.7版本为例,下载及解压缩命令如下: |
There was a problem hiding this comment.
首先需要从opencv官网上下载Linux环境下的源码
| export install_path=${root_path}/opencv3 | ||
| ``` | ||
|
|
||
| * 然后在opencv源码路径下,按照下面的方式进行编译。 |
| git clone https://github.com/PaddlePaddle/Paddle.git | ||
| ``` | ||
|
|
||
| * 进入Paddle目录后,使用如下方法编译。 |
| 以opencv3.4.7版本为例,最终在安装路径下的文件结构如下所示。**注意**:不同的opencv版本,下述的文件结构可能不同。 | ||
|
|
||
| ``` | ||
| opencv3/ |
| @@ -0,0 +1,21 @@ | |||
| OPENCV_DIR=/work/PaddleClas/deploy/cpp/opencv-3.4.7/opencv3/ | |||
There was a problem hiding this comment.
这里使用和readme里一样的相对路径,然后后面备注需要更改为自己的路径
| @@ -0,0 +1 @@ | |||
| ./build/clas_system ./tools/config.txt /work/Docs/models/tutorials/mobilenetv3_prod/Step6/images/demo.jpg | |||
| use_fp16 0 | ||
|
|
||
| # cls config | ||
| cls_model_path /work/PaddleClas/deploy/cpp/mobilenet_v3_small_infer/inference.pdmodel |
|
|
||
|
|
||
| 最终会在当前的文件夹中生成`paddle_inference/`的子文件夹。 | ||
|
|
There was a problem hiding this comment.
这里补充一下paddle_inference 文件夹的格式吧
| <img src="../../images/demo.jpg" width=300"> | ||
| </div> | ||
|
|
||
| * 最终屏幕上会输出结果,如下图所示 |
There was a problem hiding this comment.
下面没有图,改为如下所示,下面的输出用``````包裹一下
| @@ -0,0 +1,241 @@ | |||
| # 服务器端C++预测 | |||
There was a problem hiding this comment.
这个文档也需要添加,tutorials/tipc/infer_cpp/infer_cpp.md
paddle_infer_cpp