Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
MindSpore
community
提交
07fdf4f2
C
community
项目概览
MindSpore
/
community
通知
0
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
C
community
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
提交
07fdf4f2
编写于
8月 18, 2020
作者:
L
lz
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
change name
上级
a570bd4b
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
17 addition
and
18 deletion
+17
-18
design/meps/MEP-MSLITE.md
design/meps/MEP-MSLITE.md
+16
-17
sigs/mslite/README.md
sigs/mslite/README.md
+1
-1
未找到文件。
design/meps/MEP-MSLITE.md
浏览文件 @
07fdf4f2
...
@@ -27,7 +27,7 @@
...
@@ -27,7 +27,7 @@
<!-- /toc -->
<!-- /toc -->
## Summary
## Summary
MindSpore(MS)
l
ite is an extremely light-weight deep learning inference framework,
MindSpore(MS)
L
ite is an extremely light-weight deep learning inference framework,
and designed for smart-phones and embedded devices, such as watches, headsets, and various IoT devices.
and designed for smart-phones and embedded devices, such as watches, headsets, and various IoT devices.
It supports Android and iOS, as well as Harmony os, and has industry leading performance.
It supports Android and iOS, as well as Harmony os, and has industry leading performance.
...
@@ -39,12 +39,12 @@ On-device AI can dramatically reduce latency, conserve bandwidth,
...
@@ -39,12 +39,12 @@ On-device AI can dramatically reduce latency, conserve bandwidth,
improve privacy and enable smarter applications.
improve privacy and enable smarter applications.
### Goals
### Goals
-
Compatibility: supports MindSpore model, as well as mainstream third-party models, such as TensorFlow
l
ite, Caffe 1.0 and ONNX.
-
Compatibility: supports MindSpore model, as well as mainstream third-party models, such as TensorFlow
L
ite, Caffe 1.0 and ONNX.
-
High-performance:
-
High-performance:
generates small, low power consumption and fast inference target model for various hardware backends.
generates small, low power consumption and fast inference target model for various hardware backends.
-
Versatility: supports Harmony, Android and iOS os.
-
Versatility: supports Harmony, Android and iOS os.
-
Light-weight: small shared library size, should be less than 1
MB, and could be easily deployed on
-
Light-weight: small shared library size, should be less than 1MB, and could be easily deployed on
resource limited devices.
resource limited devices.
### Non-Goals
### Non-Goals
...
@@ -52,7 +52,7 @@ resource limited devices.
...
@@ -52,7 +52,7 @@ resource limited devices.
## Proposal
## Proposal
MS
l
ite consists of converter and a runtime library.
MS
L
ite consists of converter and a runtime library.
The converter is an offline tool can handle most of the model translation work.
The converter is an offline tool can handle most of the model translation work.
The runtime library deploys to device and executes online,
The runtime library deploys to device and executes online,
it has Lite RT and Lite Micro two modes.
it has Lite RT and Lite Micro two modes.
...
@@ -71,8 +71,7 @@ while Lite Micro is for extremely resource limited devices, such as watches, hea
...
@@ -71,8 +71,7 @@ while Lite Micro is for extremely resource limited devices, such as watches, hea
Graph optimizations, such as operator fusion and constant folding, make model more compact.
Graph optimizations, such as operator fusion and constant folding, make model more compact.
Post training quantization transfers fp32 model into fix-point int8 model.
Post training quantization transfers fp32 model into fix-point int8 model.
It brings nearly 4x smaller model size, low latency and low consumption for inference process.
It brings nearly 4x smaller model size, low latency and low consumption for inference process.
MS Lite also applies a variety of optimization schemes to NN operations, including using Winograd
MS lite also applies a variety of optimization schemes to NN operations, including using Winograd
algorithm in convolution and deconvolution, Strassen algorithm in matrix multiplication.
algorithm in convolution and deconvolution, Strassen algorithm in matrix multiplication.
Operations support fp64, fp32, fp16 and int8, and are highly optimized with acceleration by
Operations support fp64, fp32, fp16 and int8, and are highly optimized with acceleration by
neon instructions, hand-written assemble, multi-thread, memory reuse, heterogeneous computing, etc.
neon instructions, hand-written assemble, multi-thread, memory reuse, heterogeneous computing, etc.
...
@@ -83,20 +82,20 @@ neon instructions, hand-written assemble, multi-thread, memory reuse, heterogene
...
@@ -83,20 +82,20 @@ neon instructions, hand-written assemble, multi-thread, memory reuse, heterogene
-
Light weight
-
Light weight
MS
l
ite is highly Optimized under GHLO and GLLO. It has small foot-print,
MS
L
ite is highly Optimized under GHLO and GLLO. It has small foot-print,
MS
l
ite runtime is about 800 kB, and MS Micro is less than 200 KB.
MS
L
ite runtime is about 800 kB, and MS Micro is less than 200 KB.
It is flexible and can easily deploy to mobile and a variety of embedded devices.
It is flexible and can easily deploy to mobile and a variety of embedded devices.
### User Stories
### User Stories
#### Generate a compact target model and low latency and low consumption runtime
#### Generate a compact target model and low latency and low consumption runtime
Since devices has limited resource with few ROM, RAM, and power, how to deploy AI model to
Since devices has limited resource with few ROM, RAM, and power, how to deploy AI model to
device is very challenge. MS
l
ite aims to solve the challenge for users, and provides user-friendly,
device is very challenge. MS
L
ite aims to solve the challenge for users, and provides user-friendly,
flexible tool to help users to make their own models more slim and more efficiency.
flexible tool to help users to make their own models more slim and more efficiency.
## Design Details
## Design Details
MS
l
ite consists of converter and runtime.
MS
L
ite consists of converter and runtime.
The converter is an offline tool has three parts, frontend, IR, and backend.
The converter is an offline tool has three parts, frontend, IR, and backend.
Runtime deploys to device and executes online.
Runtime deploys to device and executes online.
...
@@ -115,12 +114,12 @@ Runtime deploys to device and executes online.
...
@@ -115,12 +114,12 @@ Runtime deploys to device and executes online.
### Test Plan
### Test Plan
MS
l
ite employed pytests and nosetest to launch the testing process,
MS
L
ite employed pytests and nosetest to launch the testing process,
and there are two types of testing strategies in MS
l
ite:
and there are two types of testing strategies in MS
L
ite:
-
**Unit Test.**
Every operation, optimization or pass in MS has its own unitest.
-
**Unit Test.**
Every operation, optimization or pass in MS has its own unitest.
-
**System test**
. The ms
l
ite module has its own component testing.
-
**System test**
. The ms
L
ite module has its own component testing.
Basically we classify the testing into compilation verification,
Basically we classify the testing into compilation verification,
function verification and performance testing.
function verification and performance testing.
...
@@ -131,13 +130,13 @@ function verification and performance testing.
...
@@ -131,13 +130,13 @@ function verification and performance testing.
-
Support fp64, fp32, fp16, int8 operations.
-
Support fp64, fp32, fp16, int8 operations.
## Drawbacks
## Drawbacks
-
MS
l
ite does not support on-device training yet, it is coming soon...
-
MS
L
ite does not support on-device training yet, it is coming soon...
## Alternatives
## Alternatives
-
MNN[1], TF
l
ite[2] and TNN[3] are outstanding on-device AI frameworks.
-
MNN[1], TF
L
ite[2] and TNN[3] are outstanding on-device AI frameworks.
MS
l
ite is for on-device AI, and MS cloud is for on-cloud AI,
MS
L
ite is for on-device AI, and MS cloud is for on-cloud AI,
both of them are in scope of Huawei's MindSpore AI framework.
both of them are in scope of Huawei's MindSpore AI framework.
They share same IR, and optimization passes. MS
l
ite is more flexible.
They share same IR, and optimization passes. MS
L
ite is more flexible.
## References
## References
-
[1] https://github.com/alibaba/MNN
-
[1] https://github.com/alibaba/MNN
...
...
sigs/mslite/README.md
浏览文件 @
07fdf4f2
...
@@ -6,7 +6,7 @@ This is the working repo for the mslite Special Interest Group (SIG). This repo
...
@@ -6,7 +6,7 @@ This is the working repo for the mslite Special Interest Group (SIG). This repo
# SIG Leads
# SIG Leads
*
Zh
eng L
i (Huawei)
*
Zh
iqiang Zha
i (Huawei)
# Logistics
# Logistics
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录