Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
PaddlePaddle
PaddleClas
提交
b9440ce5
P
PaddleClas
项目概览
PaddlePaddle
/
PaddleClas
大约 1 年 前同步成功
通知
115
Star
4999
Fork
1114
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
19
列表
看板
标记
里程碑
合并请求
6
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
P
PaddleClas
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
19
Issue
19
列表
看板
标记
里程碑
合并请求
6
合并请求
6
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
b9440ce5
编写于
11月 17, 2021
作者:
D
dongshuilong
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
update wholechain klquant
上级
62b3775e
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
5 addition
and
5 deletion
+5
-5
deploy/slim/quant_post_static.py
deploy/slim/quant_post_static.py
+3
-3
test_tipc/test_train_inference_python.sh
test_tipc/test_train_inference_python.sh
+2
-2
未找到文件。
deploy/slim/quant_post_static.py
浏览文件 @
b9440ce5
...
...
@@ -41,11 +41,11 @@ def main():
'inference.pdmodel'
))
and
os
.
path
.
exists
(
os
.
path
.
join
(
config
[
"Global"
][
"save_inference_dir"
],
'inference.pdiparams'
))
config
[
"DataLoader"
][
"
Train
"
][
"sampler"
][
"batch_size"
]
=
1
config
[
"DataLoader"
][
"
Train
"
][
"loader"
][
"num_workers"
]
=
0
config
[
"DataLoader"
][
"
Eval
"
][
"sampler"
][
"batch_size"
]
=
1
config
[
"DataLoader"
][
"
Eval
"
][
"loader"
][
"num_workers"
]
=
0
init_logger
()
device
=
paddle
.
set_device
(
"cpu"
)
train_dataloader
=
build_dataloader
(
config
[
"DataLoader"
],
"
Train
"
,
device
,
train_dataloader
=
build_dataloader
(
config
[
"DataLoader"
],
"
Eval
"
,
device
,
False
)
def
sample_generator
(
loader
):
...
...
test_tipc/test_train_inference_python.sh
浏览文件 @
b9440ce5
...
...
@@ -156,7 +156,7 @@ function func_inference(){
done
}
if
[
${
MODE
}
=
"whole_infer"
]
||
[
${
MODE
}
=
"klquant_whole_infer"
]
;
then
if
[
${
MODE
}
=
"whole_infer"
]
||
[
${
MODE
}
=
"klquant_whole_infer"
]
;
then
IFS
=
"|"
infer_export_flag
=(
${
infer_export_flag
}
)
if
[
${
infer_export_flag
}
!=
"null"
]
&&
[
${
infer_export_flag
}
!=
"False"
]
;
then
...
...
@@ -199,7 +199,7 @@ elif [ ${MODE} = "klquant_whole_infer" ]; then
ln
-s
__params__ inference.pdiparams
cd
../../deploy
is_quant
=
True
func_inference
"
${
python
}
"
"
${
inference_py
}
"
"
${
infer_model
}
/quant_post_static_model"
"../
${
LOG_PATH
}
"
"
${
infer_img_dir
}
"
${
is_quant
}
func_inference
"
${
python
}
"
"
${
inference_py
}
"
"
${
infer_model
_dir_list
}
/quant_post_static_model"
"../
${
LOG_PATH
}
"
"
${
infer_img_dir
}
"
${
is_quant
}
cd
..
fi
else
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录