Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
PaddlePaddle
Paddle-Lite
提交
b76d82ef
P
Paddle-Lite
项目概览
PaddlePaddle
/
Paddle-Lite
通知
332
Star
4
Fork
1
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
271
列表
看板
标记
里程碑
合并请求
78
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
P
Paddle-Lite
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
271
Issue
271
列表
看板
标记
里程碑
合并请求
78
合并请求
78
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
未验证
提交
b76d82ef
编写于
9月 22, 2019
作者:
W
Wilber
提交者:
GitHub
9月 22, 2019
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
CHERRY_PICK: 2109, 2008, 2098, 2102 (#2111)
cherry pick 2109, 2008, 2098, 2102
上级
7e446198
变更
7
显示空白变更内容
内联
并排
Showing
7 changed file
with
17 addition
and
4 deletion
+17
-4
lite/api/model_test.cc
lite/api/model_test.cc
+1
-0
lite/core/mir/fusion/conv_elementwise_fuser.cc
lite/core/mir/fusion/conv_elementwise_fuser.cc
+4
-2
lite/core/mir/memory_optimize_pass.cc
lite/core/mir/memory_optimize_pass.cc
+1
-0
lite/kernels/arm/norm_compute.cc
lite/kernels/arm/norm_compute.cc
+1
-0
lite/operators/op_params.h
lite/operators/op_params.h
+1
-0
lite/tests/kernels/norm_compute_test.cc
lite/tests/kernels/norm_compute_test.cc
+1
-1
lite/tools/build.sh
lite/tools/build.sh
+8
-1
未找到文件。
lite/api/model_test.cc
浏览文件 @
b76d82ef
...
...
@@ -40,6 +40,7 @@ void OutputOptModel(const std::string& load_model_dir,
config
.
set_valid_places
({
Place
{
TARGET
(
kX86
),
PRECISION
(
kFloat
)},
Place
{
TARGET
(
kARM
),
PRECISION
(
kFloat
)},
Place
{
TARGET
(
kHost
),
PRECISION
(
kFloat
)},
});
auto
predictor
=
lite_api
::
CreatePaddlePredictor
(
config
);
...
...
lite/core/mir/fusion/conv_elementwise_fuser.cc
浏览文件 @
b76d82ef
...
...
@@ -27,8 +27,10 @@ void ConvElementwiseFuser::BuildPattern() {
VarNode
(
"input"
)
->
assert_is_op_input
(
conv_type_
,
"Input"
)
->
AsInput
();
auto
*
filter
=
VarNode
(
"filter"
)
->
assert_is_op_input
(
conv_type_
,
"Filter"
)
->
AsInput
();
auto
*
bias
=
VarNode
(
"bias"
)
->
assert_is_op_input
(
"elementwise_add"
,
"Y"
)
->
AsInput
();
auto
*
bias
=
VarNode
(
"bias"
)
->
assert_is_op_input
(
"elementwise_add"
,
"Y"
)
->
AsInput
()
->
assert_is_persistable_var
();
// create op nodes
auto
*
conv2d
=
...
...
lite/core/mir/memory_optimize_pass.cc
浏览文件 @
b76d82ef
...
...
@@ -49,6 +49,7 @@ void MemoryOptimizePass::CollectLifeCycleByDevice(
"equal"
,
"lod_reset"
,
"concat"
,
"yolo_box"
,
"graph_op"
,
"feed"
,
"fetch"
};
...
...
lite/kernels/arm/norm_compute.cc
浏览文件 @
b76d82ef
...
...
@@ -47,4 +47,5 @@ REGISTER_LITE_KERNEL(
norm
,
kARM
,
kFloat
,
kNCHW
,
paddle
::
lite
::
kernels
::
arm
::
NormCompute
,
def
)
.
BindInput
(
"X"
,
{
LiteType
::
GetTensorTy
(
TARGET
(
kARM
))})
.
BindOutput
(
"Out"
,
{
LiteType
::
GetTensorTy
(
TARGET
(
kARM
))})
.
BindOutput
(
"Norm"
,
{
LiteType
::
GetTensorTy
(
TARGET
(
kARM
))})
.
Finalize
();
lite/operators/op_params.h
浏览文件 @
b76d82ef
...
...
@@ -600,6 +600,7 @@ struct SequenceSoftmaxParam {
struct
NormParam
{
const
lite
::
Tensor
*
X
{};
lite
::
Tensor
*
Out
{};
lite
::
Tensor
*
Norm
{};
int
axis
{
1
};
float
epsilon
{
1e-10
};
};
...
...
lite/tests/kernels/norm_compute_test.cc
浏览文件 @
b76d82ef
...
...
@@ -46,7 +46,7 @@ class NormComputeTester : public arena::TestCase {
auto
*
x
=
scope
->
FindTensor
(
input_
);
const
auto
*
x_data
=
x
->
data
<
float
>
();
int
axis
=
axis_
<
0
?
axis
+
dims_
.
size
()
:
axis_
;
int
axis
=
axis_
<
0
?
axis
_
+
dims_
.
size
()
:
axis_
;
int
pre_n
=
dims_
.
count
(
0
,
axis
);
int
n
=
dims_
[
axis
];
int
post_n
=
dims_
.
count
(
axis
+
1
,
dims_
.
size
());
...
...
lite/tools/build.sh
浏览文件 @
b76d82ef
...
...
@@ -221,7 +221,7 @@ function print_usage {
echo
-e
"argument choices:"
echo
-e
"--arm_os:
\t
android|ios|ios64"
echo
-e
"--arm_abi:
\t
armv8|armv7"
echo
-e
"--arm_lang:
\t
gcc|clang
(for android)"
echo
-e
"--arm_lang:
\t
only support gcc now, clang will be supported in future.
(for android)"
echo
-e
"--android_stl:
\t
c++_static|c++_shared (for android)"
echo
echo
-e
"tasks:"
...
...
@@ -252,6 +252,13 @@ function main {
;;
--arm_lang
=
*
)
ARM_LANG
=
"
${
i
#*=
}
"
if
[
${
ARM_LANG
}
==
"clang"
]
;
then
set
+x
echo
echo
-e
"error: only support gcc now, clang will be supported in future."
echo
exit
1
fi
shift
;;
--android_stl
=
*
)
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录