Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
PaddlePaddle
Paddle-Lite
提交
03f8fc19
P
Paddle-Lite
项目概览
PaddlePaddle
/
Paddle-Lite
通知
331
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看板
提交
03f8fc19
编写于
3月 05, 2020
作者:
Z
zhupengyang
提交者:
GitHub
3月 05, 2020
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
register arm kernel cast, fill_constant, fill_constant_batch_size_like to kAny (#3076)
上级
8fa18795
变更
9
隐藏空白更改
内联
并排
Showing
9 changed file
with
9 addition
and
9 deletion
+9
-9
lite/kernels/arm/cast_compute.cc
lite/kernels/arm/cast_compute.cc
+1
-1
lite/kernels/arm/cast_compute.h
lite/kernels/arm/cast_compute.h
+1
-1
lite/kernels/arm/fill_constant_batch_size_like_compute.cc
lite/kernels/arm/fill_constant_batch_size_like_compute.cc
+1
-1
lite/kernels/arm/fill_constant_batch_size_like_compute.h
lite/kernels/arm/fill_constant_batch_size_like_compute.h
+1
-1
lite/kernels/arm/fill_constant_compute.cc
lite/kernels/arm/fill_constant_compute.cc
+1
-1
lite/kernels/arm/fill_constant_compute.h
lite/kernels/arm/fill_constant_compute.h
+1
-1
lite/tests/kernels/cast_compute_test.cc
lite/tests/kernels/cast_compute_test.cc
+1
-1
lite/tests/kernels/fill_constant_batch_size_like_compute_test.cc
...sts/kernels/fill_constant_batch_size_like_compute_test.cc
+1
-1
lite/tests/kernels/fill_constant_compute_test.cc
lite/tests/kernels/fill_constant_compute_test.cc
+1
-1
未找到文件。
lite/kernels/arm/cast_compute.cc
浏览文件 @
03f8fc19
...
@@ -73,7 +73,7 @@ void CastCompute::Run() {
...
@@ -73,7 +73,7 @@ void CastCompute::Run() {
}
// namespace paddle
}
// namespace paddle
REGISTER_LITE_KERNEL
(
REGISTER_LITE_KERNEL
(
cast
,
kARM
,
k
Float
,
kNCHW
,
paddle
::
lite
::
kernels
::
arm
::
CastCompute
,
def
)
cast
,
kARM
,
k
Any
,
kNCHW
,
paddle
::
lite
::
kernels
::
arm
::
CastCompute
,
def
)
.
BindInput
(
"X"
,
{
LiteType
::
GetTensorTy
(
TARGET
(
kARM
),
PRECISION
(
kAny
))})
.
BindInput
(
"X"
,
{
LiteType
::
GetTensorTy
(
TARGET
(
kARM
),
PRECISION
(
kAny
))})
.
BindOutput
(
"Out"
,
{
LiteType
::
GetTensorTy
(
TARGET
(
kARM
),
PRECISION
(
kAny
))})
.
BindOutput
(
"Out"
,
{
LiteType
::
GetTensorTy
(
TARGET
(
kARM
),
PRECISION
(
kAny
))})
.
Finalize
();
.
Finalize
();
lite/kernels/arm/cast_compute.h
浏览文件 @
03f8fc19
...
@@ -23,7 +23,7 @@ namespace lite {
...
@@ -23,7 +23,7 @@ namespace lite {
namespace
kernels
{
namespace
kernels
{
namespace
arm
{
namespace
arm
{
class
CastCompute
:
public
KernelLite
<
TARGET
(
kARM
),
PRECISION
(
k
Float
)
>
{
class
CastCompute
:
public
KernelLite
<
TARGET
(
kARM
),
PRECISION
(
k
Any
)
>
{
public:
public:
using
param_t
=
operators
::
CastParam
;
using
param_t
=
operators
::
CastParam
;
...
...
lite/kernels/arm/fill_constant_batch_size_like_compute.cc
浏览文件 @
03f8fc19
...
@@ -52,7 +52,7 @@ void FillConstantBatchSizeLikeCompute::Run() {
...
@@ -52,7 +52,7 @@ void FillConstantBatchSizeLikeCompute::Run() {
REGISTER_LITE_KERNEL
(
REGISTER_LITE_KERNEL
(
fill_constant_batch_size_like
,
fill_constant_batch_size_like
,
kARM
,
kARM
,
k
Float
,
k
Any
,
kNCHW
,
kNCHW
,
paddle
::
lite
::
kernels
::
arm
::
FillConstantBatchSizeLikeCompute
,
paddle
::
lite
::
kernels
::
arm
::
FillConstantBatchSizeLikeCompute
,
def
)
def
)
...
...
lite/kernels/arm/fill_constant_batch_size_like_compute.h
浏览文件 @
03f8fc19
...
@@ -22,7 +22,7 @@ namespace kernels {
...
@@ -22,7 +22,7 @@ namespace kernels {
namespace
arm
{
namespace
arm
{
class
FillConstantBatchSizeLikeCompute
class
FillConstantBatchSizeLikeCompute
:
public
KernelLite
<
TARGET
(
kARM
),
PRECISION
(
k
Float
)
>
{
:
public
KernelLite
<
TARGET
(
kARM
),
PRECISION
(
k
Any
)
>
{
public:
public:
using
param_t
=
operators
::
FillConstantBatchSizeLikeParam
;
using
param_t
=
operators
::
FillConstantBatchSizeLikeParam
;
...
...
lite/kernels/arm/fill_constant_compute.cc
浏览文件 @
03f8fc19
...
@@ -52,7 +52,7 @@ void FillConstantCompute::Run() {
...
@@ -52,7 +52,7 @@ void FillConstantCompute::Run() {
// float
// float
REGISTER_LITE_KERNEL
(
fill_constant
,
REGISTER_LITE_KERNEL
(
fill_constant
,
kARM
,
kARM
,
k
Float
,
k
Any
,
kNCHW
,
kNCHW
,
paddle
::
lite
::
kernels
::
arm
::
FillConstantCompute
,
paddle
::
lite
::
kernels
::
arm
::
FillConstantCompute
,
def
)
def
)
...
...
lite/kernels/arm/fill_constant_compute.h
浏览文件 @
03f8fc19
...
@@ -21,7 +21,7 @@ namespace lite {
...
@@ -21,7 +21,7 @@ namespace lite {
namespace
kernels
{
namespace
kernels
{
namespace
arm
{
namespace
arm
{
class
FillConstantCompute
:
public
KernelLite
<
TARGET
(
kARM
),
PRECISION
(
k
Float
)
>
{
class
FillConstantCompute
:
public
KernelLite
<
TARGET
(
kARM
),
PRECISION
(
k
Any
)
>
{
public:
public:
using
param_t
=
operators
::
FillConstantParam
;
using
param_t
=
operators
::
FillConstantParam
;
...
...
lite/tests/kernels/cast_compute_test.cc
浏览文件 @
03f8fc19
...
@@ -163,7 +163,7 @@ TEST(Cast, precision) {
...
@@ -163,7 +163,7 @@ TEST(Cast, precision) {
Place
place
;
Place
place
;
float
abs_error
=
2e-5
;
float
abs_error
=
2e-5
;
#if defined(LITE_WITH_ARM)
#if defined(LITE_WITH_ARM)
place
=
TARGET
(
kARM
)
;
place
=
{
TARGET
(
kARM
),
PRECISION
(
kAny
)}
;
#elif defined(LITE_WITH_XPU)
#elif defined(LITE_WITH_XPU)
place
=
TARGET
(
kXPU
);
place
=
TARGET
(
kXPU
);
#else
#else
...
...
lite/tests/kernels/fill_constant_batch_size_like_compute_test.cc
浏览文件 @
03f8fc19
...
@@ -138,7 +138,7 @@ TEST(fill_constant_batch_size_like, precision) {
...
@@ -138,7 +138,7 @@ TEST(fill_constant_batch_size_like, precision) {
place
=
TARGET
(
kNPU
);
place
=
TARGET
(
kNPU
);
abs_error
=
1e-2
;
// use fp16 in npu
abs_error
=
1e-2
;
// use fp16 in npu
#elif defined(LITE_WITH_ARM)
#elif defined(LITE_WITH_ARM)
place
=
TARGET
(
kARM
)
;
place
=
{
TARGET
(
kARM
),
PRECISION
(
kAny
)}
;
#else
#else
return
;
return
;
#endif
#endif
...
...
lite/tests/kernels/fill_constant_compute_test.cc
浏览文件 @
03f8fc19
...
@@ -175,7 +175,7 @@ TEST(fill_constant, precision) {
...
@@ -175,7 +175,7 @@ TEST(fill_constant, precision) {
place
=
TARGET
(
kNPU
);
place
=
TARGET
(
kNPU
);
abs_error
=
1e-2
;
// use fp16 in npu
abs_error
=
1e-2
;
// use fp16 in npu
#elif defined(LITE_WITH_ARM)
#elif defined(LITE_WITH_ARM)
place
=
TARGET
(
kARM
)
;
place
=
{
TARGET
(
kARM
),
PRECISION
(
kAny
)}
;
#else
#else
return
;
return
;
#endif
#endif
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录