Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
PaddlePaddle
Serving
提交
8357cd40
S
Serving
项目概览
PaddlePaddle
/
Serving
1 年多 前同步成功
通知
186
Star
833
Fork
253
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
105
列表
看板
标记
里程碑
合并请求
10
Wiki
2
Wiki
分析
仓库
DevOps
项目成员
Pages
S
Serving
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
105
Issue
105
列表
看板
标记
里程碑
合并请求
10
合并请求
10
Pages
分析
分析
仓库分析
DevOps
Wiki
2
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
8357cd40
编写于
5月 06, 2020
作者:
D
dongdaxiang
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
fix input of unet
上级
6b75a5c6
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
21 addition
and
23 deletion
+21
-23
core/sdk-cpp/include/endpoint_config.h
core/sdk-cpp/include/endpoint_config.h
+15
-15
python/examples/unet_for_image_seg/seg_client.py
python/examples/unet_for_image_seg/seg_client.py
+5
-7
python/paddle_serving_app/models/model_list.py
python/paddle_serving_app/models/model_list.py
+1
-1
未找到文件。
core/sdk-cpp/include/endpoint_config.h
浏览文件 @
8357cd40
...
...
@@ -22,23 +22,23 @@ namespace baidu {
namespace
paddle_serving
{
namespace
sdk_cpp
{
#define PARSE_CONF_ITEM(conf, item, name, fail)
\
do {
\
if (conf.has_##name()) {
\
item.set(conf.name());
\
} else {
\
LOG(ERROR
) << "Not found key in configue: " << #name; \
}
\
#define PARSE_CONF_ITEM(conf, item, name, fail) \
do { \
if (conf.has_##name()) { \
item.set(conf.name()); \
} else { \
VLOG(2
) << "Not found key in configue: " << #name; \
} \
} while (0)
#define ASSIGN_CONF_ITEM(dest, src, fail)
\
do {
\
if (!src.init) {
\
LOG(ERROR
) << "Cannot assign an unintialized item: " << #src \
<< " to dest: " << #dest; \
return fail;
\
}
\
dest = src.value;
\
#define ASSIGN_CONF_ITEM(dest, src, fail) \
do { \
if (!src.init) { \
VLOG(2
) << "Cannot assign an unintialized item: " << #src \
<< " to dest: " << #dest; \
return fail; \
} \
dest = src.value; \
} while (0)
template
<
typename
T
>
...
...
python/examples/unet_for_image_seg/seg_client.py
浏览文件 @
8357cd40
...
...
@@ -18,7 +18,7 @@ import sys
import
cv2
client
=
Client
()
client
.
load_client_config
(
sys
.
argv
[
1
]
)
client
.
load_client_config
(
"unet_client/serving_client_conf.prototxt"
)
client
.
connect
([
"127.0.0.1:9494"
])
preprocess
=
Sequential
(
...
...
@@ -27,9 +27,7 @@ preprocess = Sequential(
postprocess
=
SegPostprocess
(
2
)
for
i
in
range
(
100
):
filename
=
sys
.
argv
[
2
]
im
=
preprocess
(
filename
)
fetch_map
=
client
.
predict
(
feed
=
{
"image"
:
im
},
fetch
=
[
"output"
])
fetch_map
[
"filename"
]
=
filename
postprocess
(
fetch_map
)
im
=
preprocess
(
"N0060.jpg"
)
fetch_map
=
client
.
predict
(
feed
=
{
"image"
:
im
},
fetch
=
[
"output"
])
fetch_map
[
"filename"
]
=
filename
postprocess
(
fetch_map
)
python/paddle_serving_app/models/model_list.py
浏览文件 @
8357cd40
...
...
@@ -27,7 +27,7 @@ class ServingModels(object):
self
.
model_dict
[
"ObjectDetection"
]
=
[
"faster_rcnn"
,
"yolov3"
]
self
.
model_dict
[
"ImageSegmentation"
]
=
[
"unet"
,
"deeplabv3"
]
self
.
model_dict
[
"ImageClassification"
]
=
[
"resnet_v2_50_imagenet"
,
"
efficientnetb6
_imagenet"
"resnet_v2_50_imagenet"
,
"
mobilenet_v2
_imagenet"
]
image_class_url
=
"https://paddle-serving.bj.bcebos.com/paddle_hub_models/image/ImageClassification/"
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录