Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
PaddlePaddle
PaddleX
提交
0c1831c5
P
PaddleX
项目概览
PaddlePaddle
/
PaddleX
通知
138
Star
4
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
43
列表
看板
标记
里程碑
合并请求
5
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
P
PaddleX
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
43
Issue
43
列表
看板
标记
里程碑
合并请求
5
合并请求
5
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
0c1831c5
编写于
6月 08, 2020
作者:
F
FlyingQianMM
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
add flag with pretrain_weights key
上级
f8ab6cc0
变更
1
隐藏空白更改
内联
并排
Showing
1 changed file
with
21 addition
and
20 deletion
+21
-20
paddlex/cv/models/utils/pretrain_weights.py
paddlex/cv/models/utils/pretrain_weights.py
+21
-20
未找到文件。
paddlex/cv/models/utils/pretrain_weights.py
浏览文件 @
0c1831c5
...
@@ -74,47 +74,47 @@ image_pretrain = {
...
@@ -74,47 +74,47 @@ image_pretrain = {
}
}
coco_pretrain
=
{
coco_pretrain
=
{
'YOLOv3_DarkNet53'
:
'YOLOv3_DarkNet53
_COCO
'
:
'https://paddlemodels.bj.bcebos.com/object_detection/yolov3_darknet.tar'
,
'https://paddlemodels.bj.bcebos.com/object_detection/yolov3_darknet.tar'
,
'YOLOv3_MobileNetV1'
:
'YOLOv3_MobileNetV1
_COCO
'
:
'https://paddlemodels.bj.bcebos.com/object_detection/yolov3_mobilenet_v1.tar'
,
'https://paddlemodels.bj.bcebos.com/object_detection/yolov3_mobilenet_v1.tar'
,
'YOLOv3_MobileNetV3_large'
:
'YOLOv3_MobileNetV3_large
_COCO
'
:
'https://paddlemodels.bj.bcebos.com/object_detection/yolov3_mobilenet_v3.pdparams'
,
'https://paddlemodels.bj.bcebos.com/object_detection/yolov3_mobilenet_v3.pdparams'
,
'YOLOv3_ResNet34'
:
'YOLOv3_ResNet34
_COCO
'
:
'https://paddlemodels.bj.bcebos.com/object_detection/yolov3_r34.tar'
,
'https://paddlemodels.bj.bcebos.com/object_detection/yolov3_r34.tar'
,
'YOLOv3_ResNet50_vd'
:
'YOLOv3_ResNet50_vd
_COCO
'
:
'https://paddlemodels.bj.bcebos.com/object_detection/yolov3_r50vd_dcn.tar'
,
'https://paddlemodels.bj.bcebos.com/object_detection/yolov3_r50vd_dcn.tar'
,
'FasterRCNN_ResNet50'
:
'FasterRCNN_ResNet50
_COCO
'
:
'https://paddlemodels.bj.bcebos.com/object_detection/faster_rcnn_r50_fpn_2x.tar'
,
'https://paddlemodels.bj.bcebos.com/object_detection/faster_rcnn_r50_fpn_2x.tar'
,
'FasterRCNN_ResNet50_vd'
:
'FasterRCNN_ResNet50_vd
_COCO
'
:
'https://paddlemodels.bj.bcebos.com/object_detection/faster_rcnn_r50_vd_fpn_2x.tar'
,
'https://paddlemodels.bj.bcebos.com/object_detection/faster_rcnn_r50_vd_fpn_2x.tar'
,
'FasterRCNN_ResNet101'
:
'FasterRCNN_ResNet101
_COCO
'
:
'https://paddlemodels.bj.bcebos.com/object_detection/faster_rcnn_r101_fpn_2x.tar'
,
'https://paddlemodels.bj.bcebos.com/object_detection/faster_rcnn_r101_fpn_2x.tar'
,
'FasterRCNN_ResNet101_vd'
:
'FasterRCNN_ResNet101_vd
_COCO
'
:
'https://paddlemodels.bj.bcebos.com/object_detection/faster_rcnn_r101_vd_fpn_2x.tar'
,
'https://paddlemodels.bj.bcebos.com/object_detection/faster_rcnn_r101_vd_fpn_2x.tar'
,
'FasterRCNN_HRNet_W18'
:
'FasterRCNN_HRNet_W18
_COCO
'
:
'https://paddlemodels.bj.bcebos.com/object_detection/faster_rcnn_hrnetv2p_w18_2x.tar'
,
'https://paddlemodels.bj.bcebos.com/object_detection/faster_rcnn_hrnetv2p_w18_2x.tar'
,
'MaskRCNN_ResNet50'
:
'MaskRCNN_ResNet50
_COCO
'
:
'https://paddlemodels.bj.bcebos.com/object_detection/mask_rcnn_r50_fpn_2x.tar'
,
'https://paddlemodels.bj.bcebos.com/object_detection/mask_rcnn_r50_fpn_2x.tar'
,
'MaskRCNN_ResNet50_vd'
:
'MaskRCNN_ResNet50_vd
_COCO
'
:
'https://paddlemodels.bj.bcebos.com/object_detection/mask_rcnn_r50_vd_fpn_2x.tar'
,
'https://paddlemodels.bj.bcebos.com/object_detection/mask_rcnn_r50_vd_fpn_2x.tar'
,
'MaskRCNN_ResNet101'
:
'MaskRCNN_ResNet101
_COCO
'
:
'https://paddlemodels.bj.bcebos.com/object_detection/faster_rcnn_r101_fpn_2x.tar'
,
'https://paddlemodels.bj.bcebos.com/object_detection/faster_rcnn_r101_fpn_2x.tar'
,
'MaskRCNN_ResNet101_vd'
:
'MaskRCNN_ResNet101_vd
_COCO
'
:
'https://paddlemodels.bj.bcebos.com/object_detection/mask_rcnn_r101_vd_fpn_1x.tar'
,
'https://paddlemodels.bj.bcebos.com/object_detection/mask_rcnn_r101_vd_fpn_1x.tar'
,
'UNet'
:
'https://paddleseg.bj.bcebos.com/models/unet_coco_v3.tgz'
,
'UNet
_COCO
'
:
'https://paddleseg.bj.bcebos.com/models/unet_coco_v3.tgz'
,
'DeepLabv3p_MobileNetV2_x1.0'
:
'DeepLabv3p_MobileNetV2_x1.0
_COCO
'
:
'https://bj.bcebos.com/v1/paddleseg/deeplab_mobilenet_x1_0_coco.tgz'
,
'https://bj.bcebos.com/v1/paddleseg/deeplab_mobilenet_x1_0_coco.tgz'
,
'DeepLabv3p_Xception65'
:
'DeepLabv3p_Xception65
_COCO
'
:
'https://paddleseg.bj.bcebos.com/models/xception65_coco.tgz'
'https://paddleseg.bj.bcebos.com/models/xception65_coco.tgz'
}
}
cityscapes_pretrain
=
{
cityscapes_pretrain
=
{
'DeepLabv3p_MobileNetV2_x1.0'
:
'DeepLabv3p_MobileNetV2_x1.0
_CITYSCAPES
'
:
'https://paddleseg.bj.bcebos.com/models/mobilenet_cityscapes.tgz'
,
'https://paddleseg.bj.bcebos.com/models/mobilenet_cityscapes.tgz'
,
'DeepLabv3p_Xception65'
:
'DeepLabv3p_Xception65
_CITYSCAPES
'
:
'https://paddleseg.bj.bcebos.com/models/xception65_bn_cityscapes.tgz'
,
'https://paddleseg.bj.bcebos.com/models/xception65_bn_cityscapes.tgz'
,
'HRNet_W18'
:
'HRNet_W18
_CITYSCAPES
'
:
'https://paddleseg.bj.bcebos.com/models/hrnet_w18_bn_cityscapes.tgz'
'https://paddleseg.bj.bcebos.com/models/hrnet_w18_bn_cityscapes.tgz'
}
}
...
@@ -198,6 +198,7 @@ def get_pretrain_weights(flag, class_name, backbone, save_dir):
...
@@ -198,6 +198,7 @@ def get_pretrain_weights(flag, class_name, backbone, save_dir):
new_save_dir
=
paddlex
.
pretrain_dir
new_save_dir
=
paddlex
.
pretrain_dir
if
class_name
in
[
'YOLOv3'
,
'FasterRCNN'
,
'MaskRCNN'
,
'DeepLabv3p'
]:
if
class_name
in
[
'YOLOv3'
,
'FasterRCNN'
,
'MaskRCNN'
,
'DeepLabv3p'
]:
backbone
=
'{}_{}'
.
format
(
class_name
,
backbone
)
backbone
=
'{}_{}'
.
format
(
class_name
,
backbone
)
backbone
=
"{}_{}"
.
format
(
backbone
,
flag
)
if
flag
==
'COCO'
:
if
flag
==
'COCO'
:
url
=
coco_pretrain
[
backbone
]
url
=
coco_pretrain
[
backbone
]
elif
flag
==
'CITYSCAPES'
:
elif
flag
==
'CITYSCAPES'
:
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录