提交 a20e2eb1 编写于 作者: L liuxiao78

fix deploy and converter

上级 92408c16
......@@ -81,9 +81,11 @@ Generally, the compiled output files include the following types. The architectu
| third_party | Header file and library of the third-party library | Yes | Yes |
Take the 0.7.0-beta version and CPU as an example. The contents of `third party` and `lib` vary depending on the architecture as follows:
- `mindspore-lite-0.7.0-converter-ubuntu`: include `protobuf` (Protobuf dynamic library).
- `mindspore-lite-0.7.0-runtime-x86-cpu`: include `flatbuffers` (FlatBuffers header file).
TODO: Add document content.
- `mindspore-lite-0.7.0-converter-ubuntu`: `third party`include `protobuf` (Protobuf dynamic library).
- `mindspore-lite-0.7.0-runtime-x86-cpu`: `third party`include `flatbuffers` (FlatBuffers header file), `lib`include`libmindspore-lite.so`(Dynamic library of MindSpore Lite inference framework).
- `mindspore-lite-0.7.0-runtime-arm64-cpu`: `third party`include `flatbuffers` (FlatBuffers header file), `lib`include`libmindspore-lite.so`(Dynamic library of MindSpore Lite inference framework) and `liboptimize.so`(Dynamic library of MindSpore Lite advanced operators).
> `liboptimize.so` only exits in runtime-arm64 outputs, and only can be used in the CPU which supports armv8.2 and fp16.
> Before running the tools in the `converter`, `benchmark`, or `time_profiler` directory, you need to configure environment variables and set the paths of the dynamic libraries of MindSpore Lite and Protobuf to the paths of the system dynamic libraries. The following uses the 0.7.0-beta version as an example: `export LD_LIBRARY_PATH=./mindspore-lite-0.7.0/lib:./mindspore-lite-0.7.0/third_party/protobuf/lib:${LD_LIBRARY_PATH}`.
......
......@@ -6,7 +6,6 @@
- [Overview](#overview)
- [Environment Preparation](#environment-preparation)
- [Parameter Description](#parameter-description)
- [Model Visualization](#model-visualization)
- [Example](#example)
<!-- /TOC -->
......@@ -15,7 +14,7 @@
## Overview
MindSpore Lite provides a tool for offline model conversion. It supports conversion of multiple types of models and visualization of converted models. The converted models can be used for inference. The command line parameters contain multiple personalized options, providing a convenient conversion method for users.
MindSpore Lite provides a tool for offline model conversion. It supports conversion of multiple types of models. The converted models can be used for inference. The command line parameters contain multiple personalized options, providing a convenient conversion method for users.
Currently, the following input formats are supported: MindSpore, TensorFlow Lite, Caffe, and ONNX.
......@@ -47,11 +46,6 @@ The following describes the parameters in detail.
> - The parameter name and parameter value are separated by an equal sign (=) and no space is allowed between them.
> - The Caffe model is divided into two files: model structure `*.prototxt`, corresponding to the `--modelFile` parameter; model weight `*.caffemodel`, corresponding to the `--weightFile` parameter
## Model Visualization
The model visualization tool provides a method for checking the model conversion result. You can run the JSON command to generate a `*.json` file and compare it with the original model to determine the conversion effect.
TODO: This function is under development now.
## Example
......@@ -103,6 +97,4 @@ The following describes how to use the conversion command by using several commo
```
INFO [converter/converter.cc:190] Runconverter] CONVERTER RESULT: SUCCESS!
```
You can use the model visualization tool to visually check the converted MindSpore Lite model. This function is under development.
\ No newline at end of file
\ No newline at end of file
......@@ -89,10 +89,11 @@ tar -xvf mindspore-lite-{version}-{function}-{OS}.tar.gz
以0.7.0-beta版本,CPU编译为例,不同包名下,`third party``lib`的内容不同:
- `mindspore-lite-0.7.0-converter-ubuntu`:包含`protobuf`(Protobuf的动态库)。
- `mindspore-lite-0.7.0-runtime-x86-cpu``third party`包含`flatbuffers`(FlatBuffers头文件),`lib`包含`libmindspore-lite.so`(MindSpore Lite的动态库)。
- `mindspore-lite-0.7.0-runtime-arm64-cpu``third party`包含`flatbuffers`(FlatBuffers头文件),`lib`包含`libmindspore-lite.so`(MindSpore Lite的动态库)和`liboptimize.so`
TODO:补全文件内容
- `mindspore-lite-0.7.0-converter-ubuntu``third party`包含`protobuf`(Protobuf的动态库)。
- `mindspore-lite-0.7.0-runtime-x86-cpu``third party`包含`flatbuffers`(FlatBuffers头文件),`lib`包含`libmindspore-lite.so`(MindSpore Lite推理框架的动态库)。
- `mindspore-lite-0.7.0-runtime-arm64-cpu``third party`包含`flatbuffers`(FlatBuffers头文件),`lib`包含`libmindspore-lite.so`(MindSpore Lite推理框架的动态库)和`liboptimize.so`(MindSpore Lite算子性能优化库)。
> `liboptimize.so`仅在runtime-arm64的输出包中存在,仅在armv8.2和支持fp16特性的CPU上使用。
> 运行converter、benchmark或time_profiler目录下的工具前,都需配置环境变量,将MindSpore Lite和Protobuf的动态库所在的路径配置到系统搜索动态库的路径中。以0.7.0-beta版本为例:`export LD_LIBRARY_PATH=./mindspore-lite-0.7.0/lib:./mindspore-lite-0.7.0/third_party/protobuf/lib:${LD_LIBRARY_PATH}`。
......
......@@ -7,12 +7,10 @@
- [Linux环境使用说明](#linux环境使用说明)
- [环境准备](#环境准备)
- [参数说明](#参数说明)
- [模型可视化](#模型可视化)
- [使用示例](#使用示例)
- [Windows环境使用说明](#windows环境使用说明)
- [环境准备](#环境准备-1)
- [参数说明](#参数说明-1)
- [模型可视化](#模型可视化-1)
- [使用示例](#使用示例-1)
<!-- /TOC -->
......@@ -21,7 +19,7 @@
## 概述
MindSpore Lite提供离线转换模型功能的工具,支持多种类型的模型转换,同时提供转化后模型可视化的功能,转换后的模型可用于推理。命令行参数包含多种个性化选项,为用户提供方便的转换途径。
MindSpore Lite提供离线转换模型功能的工具,支持多种类型的模型转换,转换后的模型可用于推理。命令行参数包含多种个性化选项,为用户提供方便的转换途径。
目前支持的输入格式有:MindSpore、TensorFlow Lite、Caffe和ONNX。
......@@ -54,11 +52,6 @@ MindSpore Lite提供离线转换模型功能的工具,支持多种类型的模
> - 参数名和参数值之间用等号连接,中间不能有空格。
> - Caffe模型一般分为两个文件:`*.prototxt`模型结构,对应`--modelFile`参数;`*.caffemodel`模型权值,对应`--weightFile`参数。
### 模型可视化
模型可视化工具提供了一种查验模型转换结果的方法。用户可使用Json命令生成`*.json`文件,与原模型相对比,确定转化效果。
TODO: 此功能还在开发中。
### 使用示例
......@@ -110,8 +103,7 @@ bash build.sh -I x86_64
```
INFO [converter/converter.cc:190] Runconverter] CONVERTER RESULT: SUCCESS!
```
你可以选择使用模型打印工具,可视化查验上述转化后生成的MindSpore Lite模型。本部分功能开发中。
## Windows环境使用说明
......@@ -127,9 +119,6 @@ bash build.sh -I x86_64
参考Linux环境模型转换工具的[参数说明](https://www.mindspore.cn/lite/docs/zh-CN/master/converter_tool.html#id4)
### 模型可视化
参考Linux环境模型转换工具的[模型可视化](https://www.mindspore.cn/lite/docs/zh-CN/master/converter_tool.html#id5)
### 使用示例
......@@ -186,4 +175,3 @@ set MSLOG=INFO
INFO [converter/converter.cc:190] Runconverter] CONVERTER RESULT: SUCCESS!
```
你可以选择使用模型打印工具,可视化查验上述转化后生成的MindSpore Lite模型。本部分功能开发中。
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册