提交 e87bb3c6 编写于 作者: F FlyingQianMM

Merge branch 'develop' of https://github.com/PaddlePaddle/PaddleX into develop_qh

...@@ -12,17 +12,17 @@ PaddleX是基于飞桨核心框架、开发套件和工具组件的深度学习 ...@@ -12,17 +12,17 @@ PaddleX是基于飞桨核心框架、开发套件和工具组件的深度学习
## 特点 ## 特点
- **全流程打通** - **全流程打通**
- 数据准备:支持LabelMe,精灵标注等主流数据标注工具协议,同时无缝集成[EasyData智能数据服务平台](https://ai.baidu.com/easydata/), 助力开发者高效获取AI开发所需高质量数据。 - **数据准备**:支持[EasyData智能数据服务平台](https://ai.baidu.com/easydata/)数据协议,通过平台便捷完成智能标注,低质数据清洗工作, 同时兼容主流标注工具协议, 助力开发者更快完成数据准备工作。
- 模型训练:基于飞桨核心框架集成[PaddleClas](https://github.com/PaddlePaddle/PaddleClas), [PaddleDetection](https://github.com/PaddlePaddle/PaddleDetection), [PaddleSeg](https://github.com/PaddlePaddle/PaddleSeg)视觉开发套件,[VisualDL](https://github.com/PaddlePaddle/VisualDL)可视化分析组件,高效完成模型训练。 - **模型训练**:集成[PaddleClas](https://github.com/PaddlePaddle/PaddleClas), [PaddleDetection](https://github.com/PaddlePaddle/PaddleDetection), [PaddleSeg](https://github.com/PaddlePaddle/PaddleSeg)视觉开发套件,丰富的高质量预训练模型,更快实现工业级模型效果。
- 多端部署:内置[PaddleSlim](https://github.com/PaddlePaddle/PaddleSlim)模型压缩工具和AES模型加密SDK,结合Paddle Inference和[Paddle Lite](https://github.com/PaddlePaddle/Paddle-Lite)便捷完成高性能且可靠的多端部署。 - **模型调优**:内置模型可解释性模块、[VisualDL](https://github.com/PaddlePaddle/VisualDL)可视化分析组件, 提供丰富的信息更好地理解模型,优化模型。
- **多端安全部署**:内置[PaddleSlim](https://github.com/PaddlePaddle/PaddleSlim)模型压缩工具和**模型加密部署模块**,结合Paddle Inference或[Paddle Lite](https://github.com/PaddlePaddle/Paddle-Lite)便捷完成高性能的多端安全部署。
- **融合产业实践** - **融合产业实践**
- 精选飞桨产业实践的成熟模型结构,开放案例实践教程,加速开发者产业落地。 - 精选飞桨产业实践的成熟模型结构,开放案例实践教程,加速开发者产业落地。
- 通过[PaddleHub](https://github.com/PaddlePaddle/Paddle)内置丰富的飞桨高质量预训练模型,助力开发者高效实现飞桨Master模式。
- **易用易集成** - **易用易集成**
- PadldeX提供简洁易用的全流程API,几行代码即可实现上百种数据增强、模型可解释性、C++模型部署等功能 - 统一易用的全流程API,5步完成模型训练,10行代码实现Python/C++高性能部署
- 提供以PaddleX API为核心集成的跨平台GUI界面,降低深度学习全流程应用门槛 - 提供以PaddleX为核心集成的跨平台可视化工具PaddleX-GUI,快速体验飞桨深度学习全流程
## 安装 ## 安装
...@@ -31,7 +31,7 @@ PaddleX提供两种开发模式,满足不同场景和用户需求: ...@@ -31,7 +31,7 @@ PaddleX提供两种开发模式,满足不同场景和用户需求:
- **Python开发模式:** 通过Python API方式完成全流程使用或集成,该模型提供全面、灵活、开放的深度学习功能,有更高的定制化空间。 - **Python开发模式:** 通过Python API方式完成全流程使用或集成,该模型提供全面、灵活、开放的深度学习功能,有更高的定制化空间。
- **GUI开发模式:** 以PaddleX API为核心集成的跨平台GUI客户端,支持`Python开发模式`下的常用功能,以更低门槛的方式快速完成产业验证的模型训练。 - **Padlde-GUI模式:** PaddleX-GUI支持`Python开发模式`下的常用功能,以更低门槛的方式快速完成产业验证的模型训练。
开发者可根据自身需要按需选择不同的模式进行安装使用。 开发者可根据自身需要按需选择不同的模式进行安装使用。
...@@ -48,20 +48,19 @@ PaddleX提供两种开发模式,满足不同场景和用户需求: ...@@ -48,20 +48,19 @@ PaddleX提供两种开发模式,满足不同场景和用户需求:
pip install paddlex -i https://mirror.baidu.com/pypi/simple pip install paddlex -i https://mirror.baidu.com/pypi/simple
``` ```
### GUI开发模式安装 ### PaddleX-GUI安装
进入PaddleX官网[下载使用](https://www.paddlepaddle.org.cn/paddle/paddlex),申请下载绿色安装包,开箱即用。 进入PaddleX官网[下载使用](https://www.paddlepaddle.org.cn/paddle/paddlex),申请下载绿色安装包,开箱即用。
GUI模式的使用教程可参考[PaddleX GUI模式使用教程](https://paddlex.readthedocs.io/zh_CN/latest/paddlex_gui/index.html) Paddle-GUI的使用教程可参考[PaddleX-GUI模式使用教程](https://paddlex.readthedocs.io/zh_CN/latest/paddlex_gui/index.html)
## 使用文档 ## 使用文档
推荐访问[PaddleX在线使用文档](https://paddlex.readthedocs.io/zh_CN/latest/index.html),快速查阅读使用教程和API文档说明。 推荐访问[PaddleX在线使用文档](https://paddlex.readthedocs.io/zh_CN/latest/index.html),快速查阅读使用教程和API文档说明。
- [10分钟快速上手](https://paddlex.readthedocs.io/zh_CN/latest/quick_start.html) - [10分钟快速上手使用](https://paddlex.readthedocs.io/zh_CN/latest/quick_start.html)
- [PaddleX模型训练](https://paddlex.readthedocs.io/zh_CN/latest/tutorials/train/index.html#id1) - [PaddleX全流程开发教程](https://paddlex.readthedocs.io/zh_CN/latest/tutorials/index.html)
- [PaddleX模型压缩](https://paddlex.readthedocs.io/zh_CN/latest/slim/index.html#id1) - [PaddleX视觉方案介绍](https://paddlex.readthedocs.io/zh_CN/latest/cv_solutions.html)
- [PaddleX模型库](https://paddlex.readthedocs.io/zh_CN/latest/model_zoo.html#id1) - [PaddleX API参考文档](https://paddlex.readthedocs.io/zh_CN/latest/apis/index.html)
- [PaddleX多端部署](docs/deploy.md)
## 在线教程 ## 在线教程
...@@ -74,12 +73,16 @@ GUI模式的使用教程可参考[PaddleX GUI模式使用教程](https://paddlex ...@@ -74,12 +73,16 @@ GUI模式的使用教程可参考[PaddleX GUI模式使用教程](https://paddlex
## 交流与反馈 ## 交流与反馈
- 项目官网: https://www.paddlepaddle.org.cn/paddle/paddlex - 项目官网: https://www.paddlepaddle.org.cn/paddle/paddlex
- PaddleX用户QQ群: 1045148026 (手机QQ扫描如下二维码快速加入) - PaddleX用户交流群: 1045148026 (手机QQ扫描如下二维码快速加入)
<img src="./docs/images/QQGroup.jpeg" width="195" height="300" alt="QQGroup" align="center" /> <img src="./docs/images/QQGroup.jpeg" width="195" height="300" alt="QQGroup" align="center" />
## FAQ ## FAQ
## 更新日志 ## 更新日志
* 2020.05.20
**`v1.0.0`**
* 初始版本发布。
## 贡献代码 ## 贡献代码
......
...@@ -3,19 +3,18 @@ ...@@ -3,19 +3,18 @@
PaddleX是基于飞桨核心框架、开发套件和工具组件的深度学习全流程开发工具。具备 **全流程打通** 、**融合产业实践** 、**易用易集成** 三大特点。 PaddleX是基于飞桨核心框架、开发套件和工具组件的深度学习全流程开发工具。具备 **全流程打通** 、**融合产业实践** 、**易用易集成** 三大特点。
全流程打通 全流程打通
| - **数据准备**: 支持LabelMe,精灵标注等主流数据标注工具协议,同时无缝集成 `EasyData智能数据服务平台 <https://ai.baidu.com/easydata/>`_ ,助力开发者高效获取AI开发所需高质量数据。 | - **数据准备**: 支持 `EasyData智能数据服务平台数据协议 <https://ai.baidu.com/easydata/>`_ ,通过平台便捷完成智能标注,低质数据清洗工作;同时兼容主流标注工具协议, 助力开发者更快完成数据准备工作。
| - **模型训练**: 基于飞桨核心框架集成 `PaddleClas <https://github.com/PaddlePaddle/PaddleClas>`_ ,`PaddleDetection <https://github.com/PaddlePaddle/PaddleDetection>`_ ,`PaddleSeg <https://github.com/PaddlePaddle/PaddleSeg>`_ 视觉开发套件 ,`VisualDL <https://github.com/PaddlePaddle/VisualDL>`_ 可视化分析组件,高效完成模型训练。 | - **模型训练**: 基于飞桨核心框架集成 `PaddleClas <https://github.com/PaddlePaddle/PaddleClas>`_ ,`PaddleDetection <https://github.com/PaddlePaddle/PaddleDetection>`_ ,`PaddleSeg <https://github.com/PaddlePaddle/PaddleSeg>`_ 视觉开发套件,丰富的高质量预训练模型,更快实现工业级模型训练。
| _ **多端部署**: 内置 `PaddleSlim <https://github.com/PaddlePaddle/PaddleSlim>`_ 模型压缩工具和AES模型加密SDK,结合Paddle Inference和 `Paddle Lite <https://github.com/PaddlePaddle/Paddle-Lite>`_ 便捷完成高性能且可靠的多端部署。 | - **模型调优**: 内置模型可解释性模块、`VisualDL <https://github.com/PaddlePaddle/VisualDL>`_ 可视化分析组件,提供丰富的信息更好地理解模型,优化模型。
| - **多端安全部署**: 内置 `PaddleSlim <https://github.com/PaddlePaddle/PaddleSlim>`_ 模型压缩工具和AES模型加密SDK,结合Paddle Inference和 `Paddle Lite <https://github.com/PaddlePaddle/Paddle-Lite>`_ 便捷完成高性能的多端安全部署。
融合产业实践 融合产业实践
| - 精选飞桨产业实践的成熟模型结构,开放案例实践教程,加速开发者产业落地。 | - 精选飞桨产业实践的成熟模型结构,开放案例实践教程,加速开发者产业落地。
| - 通过 `PaddleHub <https://github.com/PaddlePaddle/PaddleHub>`_ 内置丰富的飞桨高质量预训练模型,助力开发者高效实现飞桨Master模式。
易用易集成 易用易集成
| - PadldeX提供简洁易用的全流程API,几行代码即可实现上百种数据增强、模型可解释性、C++模型部署等功能 | - 统一易用的全流程API,5步完成模型训练,10行代码实现Python/C++高性能部署
| - 提供以PaddleX API为核心集成的跨平台GUI界面,降低深度学习全流程应用门槛 | - 提供以PaddleX为核心集成的跨平台可视化开发工具PaddleX-GUI,更低门槛快速体验飞桨深度学习全流程
.. toctree:: .. toctree::
:maxdepth: 2 :maxdepth: 2
...@@ -31,7 +30,7 @@ PaddleX是基于飞桨核心框架、开发套件和工具组件的深度学习 ...@@ -31,7 +30,7 @@ PaddleX是基于飞桨核心框架、开发套件和工具组件的深度学习
FAQ.md FAQ.md
appendix/index.rst appendix/index.rst
* PaddleX版本: v0.1.7 * PaddleX版本: v1.0.0
* 项目官网: http://www.paddlepaddle.org.cn/paddle/paddlex * 项目官网: http://www.paddlepaddle.org.cn/paddle/paddlex
* 项目GitHub: https://github.com/PaddlePaddle/PaddleX/tree/develop * 项目GitHub: https://github.com/PaddlePaddle/PaddleX/tree/develop
* 官方QQ用户群: 1045148026 * 官方QQ用户群: 1045148026
......
# PaddleX使用教程
- [模型训练](./train)
- [模型裁剪](./compress)
# copyright (c) 2020 PaddlePaddle Authors. All Rights Reserve. # Copyright (c) 2020 PaddlePaddle Authors. All Rights Reserve.
# #
# Licensed under the Apache License, Version 2.0 (the "License"); # Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License. # you may not use this file except in compliance with the License.
......
# Copyright (c) 2020 PaddlePaddle Authors. All Rights Reserve.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
from six import text_type as _text_type from six import text_type as _text_type
import argparse import argparse
import sys import sys
......
#copyright (c) 2020 PaddlePaddle Authors. All Rights Reserve. # Copyright (c) 2020 PaddlePaddle Authors. All Rights Reserve.
# #
#Licensed under the Apache License, Version 2.0 (the "License"); # Licensed under the Apache License, Version 2.0 (the "License");
#you may not use this file except in compliance with the License. # you may not use this file except in compliance with the License.
#You may obtain a copy of the License at # You may obtain a copy of the License at
# #
# http://www.apache.org/licenses/LICENSE-2.0 # http://www.apache.org/licenses/LICENSE-2.0
# #
#Unless required by applicable law or agreed to in writing, software # Unless required by applicable law or agreed to in writing, software
#distributed under the License is distributed on an "AS IS" BASIS, # distributed under the License is distributed on an "AS IS" BASIS,
#WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
#See the License for the specific language governing permissions and # See the License for the specific language governing permissions and
#limitations under the License. # limitations under the License.
from __future__ import absolute_import from __future__ import absolute_import
import paddle.fluid as fluid import paddle.fluid as fluid
......
import paddlex import paddlex
#import paddlehub as hub import paddlehub as hub
import os import os
import os.path as osp import os.path as osp
...@@ -85,53 +85,49 @@ def get_pretrain_weights(flag, model_type, backbone, save_dir): ...@@ -85,53 +85,49 @@ def get_pretrain_weights(flag, model_type, backbone, save_dir):
backbone = 'DetResNet50' backbone = 'DetResNet50'
assert backbone in image_pretrain, "There is not ImageNet pretrain weights for {}, you may try COCO.".format( assert backbone in image_pretrain, "There is not ImageNet pretrain weights for {}, you may try COCO.".format(
backbone) backbone)
url = image_pretrain[backbone] # url = image_pretrain[backbone]
fname = osp.split(url)[-1].split('.')[0] # fname = osp.split(url)[-1].split('.')[0]
paddlex.utils.download_and_decompress(url, path=new_save_dir) # paddlex.utils.download_and_decompress(url, path=new_save_dir)
return osp.join(new_save_dir, fname) # return osp.join(new_save_dir, fname)
# try: try:
# hub.download(backbone, save_path=new_save_dir) hub.download(backbone, save_path=new_save_dir)
# except Exception as e: except Exception as e:
# if isinstance(e, hub.ResourceNotFoundError): if isinstance(e, hub.ResourceNotFoundError):
# raise Exception( raise Exception("Resource for backbone {} not found".format(
# "Resource for backbone {} not found".format(backbone)) backbone))
# elif isinstance(e, hub.ServerConnectionError): elif isinstance(e, hub.ServerConnectionError):
# raise Exception( raise Exception(
# "Cannot get reource for backbone {}, please check your internet connecgtion" "Cannot get reource for backbone {}, please check your internet connecgtion"
# .format(backbone)) .format(backbone))
# else: else:
# raise Exception( raise Exception(
# "Unexpected error, please make sure paddlehub >= 1.6.2") "Unexpected error, please make sure paddlehub >= 1.6.2")
# return osp.join(new_save_dir, backbone) return osp.join(new_save_dir, backbone)
elif flag == 'COCO': elif flag == 'COCO':
new_save_dir = save_dir new_save_dir = save_dir
if hasattr(paddlex, 'pretrain_dir'): if hasattr(paddlex, 'pretrain_dir'):
new_save_dir = paddlex.pretrain_dir new_save_dir = paddlex.pretrain_dir
url = coco_pretrain[backbone] url = coco_pretrain[backbone]
fname = osp.split(url)[-1].split('.')[0] fname = osp.split(url)[-1].split('.')[0]
paddlex.utils.download_and_decompress(url, path=new_save_dir) # paddlex.utils.download_and_decompress(url, path=new_save_dir)
return osp.join(new_save_dir, fname) # return osp.join(new_save_dir, fname)
# new_save_dir = save_dir assert backbone in coco_pretrain, "There is not COCO pretrain weights for {}, you may try ImageNet.".format(
# if hasattr(paddlex, 'pretrain_dir'): backbone)
# new_save_dir = paddlex.pretrain_dir try:
# assert backbone in coco_pretrain, "There is not COCO pretrain weights for {}, you may try ImageNet.".format( hub.download(backbone, save_path=new_save_dir)
# backbone) except Exception as e:
# try: if isinstance(hub.ResourceNotFoundError):
# hub.download(backbone, save_path=new_save_dir) raise Exception("Resource for backbone {} not found".format(
# except Exception as e: backbone))
# if isinstance(hub.ResourceNotFoundError): elif isinstance(hub.ServerConnectionError):
# raise Exception( raise Exception(
# "Resource for backbone {} not found".format(backbone)) "Cannot get reource for backbone {}, please check your internet connecgtion"
# elif isinstance(hub.ServerConnectionError): .format(backbone))
# raise Exception( else:
# "Cannot get reource for backbone {}, please check your internet connecgtion" raise Exception(
# .format(backbone)) "Unexpected error, please make sure paddlehub >= 1.6.2")
# else: return osp.join(new_save_dir, backbone)
# raise Exception(
# "Unexpected error, please make sure paddlehub >= 1.6.2")
# return osp.join(new_save_dir, backbone)
else: else:
raise Exception( raise Exception(
"pretrain_weights need to be defined as directory path or `IMAGENET` or 'COCO' (download pretrain weights automatically)." "pretrain_weights need to be defined as directory path or `IMAGENET` or 'COCO' (download pretrain weights automatically)."
......
#copyright (c) 2020 PaddlePaddle Authors. All Rights Reserve. # Copyright (c) 2020 PaddlePaddle Authors. All Rights Reserve.
# #
#Licensed under the Apache License, Version 2.0 (the "License"); # Licensed under the Apache License, Version 2.0 (the "License");
#you may not use this file except in compliance with the License. # you may not use this file except in compliance with the License.
#You may obtain a copy of the License at # You may obtain a copy of the License at
# #
# http://www.apache.org/licenses/LICENSE-2.0 # http://www.apache.org/licenses/LICENSE-2.0
# #
#Unless required by applicable law or agreed to in writing, software # Unless required by applicable law or agreed to in writing, software
#distributed under the License is distributed on an "AS IS" BASIS, # distributed under the License is distributed on an "AS IS" BASIS,
#WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
#See the License for the specific language governing permissions and # See the License for the specific language governing permissions and
#limitations under the License. # limitations under the License.
import argparse import argparse
import os import os
......
#copyright (c) 2020 PaddlePaddle Authors. All Rights Reserve. # Copyright (c) 2020 PaddlePaddle Authors. All Rights Reserve.
# #
#Licensed under the Apache License, Version 2.0 (the "License"); # Licensed under the Apache License, Version 2.0 (the "License");
#you may not use this file except in compliance with the License. # you may not use this file except in compliance with the License.
#You may obtain a copy of the License at # You may obtain a copy of the License at
# #
# http://www.apache.org/licenses/LICENSE-2.0 # http://www.apache.org/licenses/LICENSE-2.0
# #
#Unless required by applicable law or agreed to in writing, software # Unless required by applicable law or agreed to in writing, software
#distributed under the License is distributed on an "AS IS" BASIS, # distributed under the License is distributed on an "AS IS" BASIS,
#WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
#See the License for the specific language governing permissions and # See the License for the specific language governing permissions and
#limitations under the License. # limitations under the License.
import argparse import argparse
import os import os
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册