Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
PaddlePaddle
models
提交
346e1343
M
models
项目概览
PaddlePaddle
/
models
1 年多 前同步成功
通知
226
Star
6828
Fork
2962
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
602
列表
看板
标记
里程碑
合并请求
255
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
M
models
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
602
Issue
602
列表
看板
标记
里程碑
合并请求
255
合并请求
255
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
未验证
提交
346e1343
编写于
8月 29, 2019
作者:
W
wangguanzhong
提交者:
GitHub
8月 29, 2019
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
add group norm doc (#3221)
* add gn doc
上级
e99b607e
变更
5
隐藏空白更改
内联
并排
Showing
5 changed file
with
46 addition
and
22 deletion
+46
-22
PaddleCV/PaddleDetection/docs/DATA.md
PaddleCV/PaddleDetection/docs/DATA.md
+2
-2
PaddleCV/PaddleDetection/docs/DATA_cn.md
PaddleCV/PaddleDetection/docs/DATA_cn.md
+2
-2
PaddleCV/PaddleDetection/docs/MODEL_ZOO.md
PaddleCV/PaddleDetection/docs/MODEL_ZOO.md
+10
-0
PaddleCV/PaddleDetection/docs/MODEL_ZOO_cn.md
PaddleCV/PaddleDetection/docs/MODEL_ZOO_cn.md
+10
-0
PaddleCV/PaddleDetection/ppdet/utils/download.py
PaddleCV/PaddleDetection/ppdet/utils/download.py
+22
-18
未找到文件。
PaddleCV/PaddleDetection/docs/DATA.md
浏览文件 @
346e1343
...
...
@@ -100,7 +100,7 @@ like dataset, run this command:
# --annotation: the path of file, which contains the name of annotation files
# --save-dir: the save path
# --samples: the number of samples (default is -1, which mean all datas in dataset)
python ./tools/generate_data_for_training.py
python ./
ppdet/data/
tools/generate_data_for_training.py
--type
=
json
\
--annotation
=
./annotations/instances_val2017.json
\
--save-dir
=
./roidb
\
...
...
@@ -181,7 +181,7 @@ whole data pipeline is fully customizable through the yaml configuration files.
```
sh
# a small utility (`tools/labelme2coco.py`) is provided to convert
# Labelme-annotated dataset to COCO format.
python ./tools/labelme2coco.py
--json_input_dir
./labelme_annos/
python ./
ppdet/data/
tools/labelme2coco.py
--json_input_dir
./labelme_annos/
--image_input_dir
./labelme_imgs/
--output_dir
./cocome/
--train_proportion
0.8
...
...
PaddleCV/PaddleDetection/docs/DATA_cn.md
浏览文件 @
346e1343
...
...
@@ -90,7 +90,7 @@
# --annotation: 一个包含所需标注文件名的文件的路径
# --save-dir: 保存路径
# --samples: sample的个数(默认是-1,代表使用所有sample)
python ./tools/generate_data_for_training.py
python ./
ppdet/data/
tools/generate_data_for_training.py
--type=json \
--annotation=./annotations/instances_val2017.json \
--save-dir=./roidb \
...
...
@@ -168,7 +168,7 @@ coco = Reader(ccfg.DATA, ccfg.TRANSFORM, maxiter=-1)
-
选择1:将数据集转换为VOC格式或者COCO格式。
```
# 在./tools/中提供了labelme2coco.py用于将labelme标注的数据集转换为COCO数据集
python ./tools/labelme2coco.py --json_input_dir ./labelme_annos/
python ./
ppdet/data/
tools/labelme2coco.py --json_input_dir ./labelme_annos/
--image_input_dir ./labelme_imgs/
--output_dir ./cocome/
--train_proportion 0.8
...
...
PaddleCV/PaddleDetection/docs/MODEL_ZOO.md
浏览文件 @
346e1343
...
...
@@ -80,6 +80,16 @@ The backbone models pretrained on ImageNet are available. All backbone models ar
-
`c3-c5`
means adding
`dcn`
in resnet stage 3 to 5.
-
Detailed configuration file in
[
configs/dcn
](
https://github.com/PaddlePaddle/models/tree/develop/PaddleCV/PaddleDetection/configs/dcn
)
### Group Normalization
| Backbone | Type | Image/gpu | Lr schd | Box AP | Mask AP | Download |
| :------------------- | :------------- | :-----: | :-----: | :----: | :-----: | :----------------------------------------------------------: |
| ResNet50-FPN | Faster | 2 | 2x | 39.7 | - |
[
model
](
https://paddlemodels.bj.bcebos.com/object_detection/faster_rcnn_r50_fpn_gn_2x.tar
)
|
| ResNet50-FPN | Mask | 1 | 2x | 40.1 | 35.8 |
[
model
](
https://paddlemodels.bj.bcebos.com/object_detection/mask_rcnn_r50_fpn_gn_2x.tar
)
|
#### Notes:
-
Group Normalization reference from
[
Group Normalization
](
https://arxiv.org/abs/1803.08494
)
.
-
Detailed configuration file in
[
configs/gn
](
https://github.com/PaddlePaddle/models/tree/develop/PaddleCV/PaddleDetection/configs/gn
)
### Yolo v3
| Backbone | Size | Image/gpu | Lr schd | Box AP | Download |
...
...
PaddleCV/PaddleDetection/docs/MODEL_ZOO_cn.md
浏览文件 @
346e1343
...
...
@@ -80,6 +80,16 @@ Paddle提供基于ImageNet的骨架网络预训练模型。所有预训练模型
-
`c3-c5`
意思是在resnet模块的3到5阶段增加
`dcn`
.
-
详细的配置文件在
[
configs/dcn
](
https://github.com/PaddlePaddle/models/tree/develop/PaddleCV/PaddleDetection/configs/dcn
)
### Group Normalization
| 骨架网络 | 网络类型 | 每张GPU图片个数 | 学习率策略 | Box AP | Mask AP | 下载 |
| :------------------- | :------------- |:--------: | :-----: | :----: | :-----: | :----------------------------------------------------------: |
| ResNet50-FPN | Faster | 2 | 2x | 39.7 | - |
[
下载链接
](
https://paddlemodels.bj.bcebos.com/object_detection/faster_rcnn_r50_fpn_gn_2x.tar
)
|
| ResNet50-FPN | Mask | 1 | 2x | 40.1 | 35.8 |
[
下载链接
](
https://paddlemodels.bj.bcebos.com/object_detection/mask_rcnn_r50_fpn_gn_2x.tar
)
|
#### 注意事项:
-
Group Normalization参考论文
[
Group Normalization
](
https://arxiv.org/abs/1803.08494
)
.
-
详细的配置文件在
[
configs/gn
](
https://github.com/PaddlePaddle/models/tree/develop/PaddleCV/PaddleDetection/configs/gn
)
### Yolo v3
| 骨架网络 | 输入尺寸 | 每张GPU图片个数 | 学习率策略 | Box AP | 下载 |
...
...
PaddleCV/PaddleDetection/ppdet/utils/download.py
浏览文件 @
346e1343
...
...
@@ -16,7 +16,6 @@ from __future__ import absolute_import
from
__future__
import
division
from
__future__
import
print_function
import
os
import
os.path
as
osp
import
shutil
...
...
@@ -40,20 +39,26 @@ DATASET_HOME = osp.expanduser("~/.cache/paddle/dataset")
# download info: (url, md5sum)
DATASETS
=
{
'coco'
:
([
(
'http://images.cocodataset.org/zips/train2017.zip'
,
'cced6f7f71b7629ddf16f17bbcfab6b2'
,
),
(
'http://images.cocodataset.org/zips/val2017.zip'
,
'442b8da7639aecaf257c1dceb8ba8c80'
,
),
(
'http://images.cocodataset.org/annotations/annotations_trainval2017.zip'
,
'f4bbac642086de4f52a3fdda2de5fa2c'
,
),
(
'http://images.cocodataset.org/zips/train2017.zip'
,
'cced6f7f71b7629ddf16f17bbcfab6b2'
,
),
(
'http://images.cocodataset.org/zips/val2017.zip'
,
'442b8da7639aecaf257c1dceb8ba8c80'
,
),
(
'http://images.cocodataset.org/annotations/annotations_trainval2017.zip'
,
'f4bbac642086de4f52a3fdda2de5fa2c'
,
),
],
[
"annotations"
,
"train2017"
,
"val2017"
]),
'voc'
:
([
(
'http://host.robots.ox.ac.uk/pascal/VOC/voc2012/VOCtrainval_11-May-2012.tar'
,
'6cd6e144f989b92b3379bac3b3de84fd'
,
),
(
'http://host.robots.ox.ac.uk/pascal/VOC/voc2007/VOCtrainval_06-Nov-2007.tar'
,
'c52e279531787c972589f7e41ab4ae64'
,
),
(
'http://host.robots.ox.ac.uk/pascal/VOC/voc2007/VOCtest_06-Nov-2007.tar'
,
'b6e924de25625d8de591ea690078ad9f'
,
),
(
'http://host.robots.ox.ac.uk/pascal/VOC/voc2012/VOCtrainval_11-May-2012.tar'
,
'6cd6e144f989b92b3379bac3b3de84fd'
,
),
(
'http://host.robots.ox.ac.uk/pascal/VOC/voc2007/VOCtrainval_06-Nov-2007.tar'
,
'c52e279531787c972589f7e41ab4ae64'
,
),
(
'http://host.robots.ox.ac.uk/pascal/VOC/voc2007/VOCtest_06-Nov-2007.tar'
,
'b6e924de25625d8de591ea690078ad9f'
,
),
],
[
"VOCdevkit/VOC_all"
]),
}
...
...
@@ -112,8 +117,7 @@ def get_dataset_path(path, annotation, image_dir):
# dataset, VOC default label list should be used,
# do not generate label_list.txt here. For default
# label, see ../data/source/voc_loader.py
merge_and_create_list
(
devkit_dir
,
years
,
output_tmp_dir
)
merge_and_create_list
(
devkit_dir
,
years
,
output_tmp_dir
)
shutil
.
move
(
output_tmp_dir
,
output_dir
)
# remove source directory VOC2007 and VOC2012
shutil
.
rmtree
(
osp
.
join
(
devkit_dir
,
"VOC2007"
))
...
...
@@ -121,7 +125,7 @@ def get_dataset_path(path, annotation, image_dir):
return
data_dir
# not match any dataset in DATASETS
raise
ValueError
(
"{} not exists
and
unknow dataset type"
.
format
(
path
))
raise
ValueError
(
"{} not exists
or
unknow dataset type"
.
format
(
path
))
def
get_path
(
url
,
root_dir
,
md5sum
=
None
):
...
...
@@ -174,13 +178,13 @@ def _dataset_exists(path, annotation, image_dir):
annotation_path
=
osp
.
join
(
path
,
annotation
)
if
not
osp
.
isfile
(
annotation_path
):
logger
.
info
(
"Config annotation {} is not a "
"file"
.
format
(
annotation_path
))
"file"
.
format
(
annotation_path
))
return
False
if
image_dir
:
image_path
=
osp
.
join
(
path
,
image_dir
)
if
not
osp
.
isdir
(
image_path
):
logger
.
info
(
"Config image_dir {} is not a "
"directory"
.
format
(
image_path
))
"directory"
.
format
(
image_path
))
return
False
return
True
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录