Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
PaddlePaddle
Paddle-Lite
提交
5b03cddc
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看板
提交
5b03cddc
编写于
7月 02, 2018
作者:
Y
Yao,kun
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Add marco
上级
1060a1d7
变更
8
隐藏空白更改
内联
并排
Showing
8 changed file
with
29 addition
and
10 deletion
+29
-10
src/operators/dropout_op.cpp
src/operators/dropout_op.cpp
+2
-2
src/operators/dropout_op.h
src/operators/dropout_op.h
+4
-3
src/operators/im2sequence_op.cpp
src/operators/im2sequence_op.cpp
+2
-2
src/operators/im2sequence_op.h
src/operators/im2sequence_op.h
+5
-3
src/operators/kernel/arm/dropout_kernel.cpp
src/operators/kernel/arm/dropout_kernel.cpp
+4
-0
src/operators/kernel/arm/im2sequence_kernel.cpp
src/operators/kernel/arm/im2sequence_kernel.cpp
+4
-0
src/operators/kernel/dropout_kernel.h
src/operators/kernel/dropout_kernel.h
+4
-0
src/operators/kernel/im2sequence_kernel.h
src/operators/kernel/im2sequence_kernel.h
+4
-0
未找到文件。
src/operators/dropout_op.cpp
浏览文件 @
5b03cddc
...
...
@@ -28,8 +28,8 @@ template class DropoutOp<CPU, float>;
namespace
ops
=
paddle_mobile
::
operators
;
#ifdef PADDLE_MOBILE_CPU
USE_OP
(
Dropout
);
REGISTER_OPERATOR
(
dropout
,
ops
::
DropoutOp
);
USE_OP
_CPU
(
Dropout
);
REGISTER_OPERATOR
_CPU
(
dropout
,
ops
::
DropoutOp
);
#endif
#ifdef PADDLE_MOBILE_MALI_GPU
#endif
...
...
src/operators/dropout_op.h
浏览文件 @
5b03cddc
...
...
@@ -30,13 +30,14 @@ using paddle_mobile::framework::Tensor;
template
<
typename
DeviceType
,
typename
T
>
class
DropoutOp
:
public
framework
::
OperatorWithKernel
<
DeviceType
,
DropoutParam
,
operators
::
DropoutKern
a
l
<
DeviceType
,
T
>>
{
DeviceType
,
DropoutParam
,
operators
::
DropoutKern
e
l
<
DeviceType
,
T
>>
{
public:
DropoutOp
(
const
std
::
string
&
type
,
const
VariableNameMap
&
inputs
,
const
VariableNameMap
&
outputs
,
const
framework
::
AttributeMap
attrs
,
std
::
shared_ptr
<
framework
::
Scope
>
scope
)
:
framework
::
OperatorWithKernel
<
DeviceType
>
(
type
,
inputs
,
outputs
,
attrs
,
scope
),
:
framework
::
OperatorWithKernel
<
DeviceType
,
DropoutParam
,
operators
::
DropoutKernel
<
DeviceType
,
T
>>
(
type
,
inputs
,
outputs
,
attrs
,
scope
),
param_
(
inputs
,
outputs
,
attrs
,
*
scope
)
{}
using
framework
::
OperatorWithKernel
<
DeviceType
,
DropoutParam
,
...
...
src/operators/im2sequence_op.cpp
浏览文件 @
5b03cddc
...
...
@@ -54,8 +54,8 @@ template class Im2SequenceOp<CPU, float>;
namespace
ops
=
paddle_mobile
::
operators
;
#ifdef PADDLE_MOBILE_CPU
USE_OP
(
im2sequence
);
REGISTER_OPERATOR
(
im2sequence
,
ops
::
Im2SequenceOp
);
USE_OP
_CPU
(
im2sequence
);
REGISTER_OPERATOR
_CPU
(
im2sequence
,
ops
::
Im2SequenceOp
);
#endif
#ifdef PADDLE_MOBILE_MALI_GPU
#endif
...
...
src/operators/im2sequence_op.h
浏览文件 @
5b03cddc
...
...
@@ -28,14 +28,16 @@ using namespace framework;
template
<
typename
DeviceType
,
typename
T
>
class
Im2SequenceOp
:
public
framework
::
OperatorWithKernel
<
DeviceType
,
Im2SequenceParam
,
operators
::
Im2SequenceKern
a
l
<
DeviceType
,
T
>>
{
operators
::
Im2SequenceKern
e
l
<
DeviceType
,
T
>>
{
public:
Im2SequenceOp
(
const
std
::
string
&
type
,
const
VariableNameMap
&
inputs
,
const
VariableNameMap
&
outputs
,
const
framework
::
AttributeMap
&
attrs
,
std
::
shared_ptr
<
framework
::
Scope
>
scope
)
:
framework
::
OperatorWithKernel
<
DeviceType
>
(
type
,
inputs
,
outputs
,
attrs
,
scope
),
:
framework
::
OperatorWithKernel
<
DeviceType
,
Im2SequenceParam
,
operators
::
Im2SequenceKernel
<
DeviceType
,
T
>>
(
type
,
inputs
,
outputs
,
attrs
,
scope
),
param_
(
inputs
,
outputs
,
attrs
,
*
scope
)
{}
using
framework
::
OperatorWithKernel
<
...
...
src/operators/kernel/arm/dropout_kernel.cpp
浏览文件 @
5b03cddc
...
...
@@ -12,6 +12,8 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License. */
#ifdef DROPOUT_OP
#pragma once
#include "operators/kernel/dropout_kernel.h"
...
...
@@ -43,3 +45,5 @@ void DropoutKernel<CPU, float>::Compute(const DropoutParam ¶m) const {
}
}
// namespace operators
}
// namespace paddle_mobile
#endif
src/operators/kernel/arm/im2sequence_kernel.cpp
浏览文件 @
5b03cddc
...
...
@@ -12,6 +12,8 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License. */
#ifdef IM2SEQUENCE_OP
#include "operators/kernel/im2sequence_kernel.h"
namespace
paddle_mobile
{
...
...
@@ -72,3 +74,5 @@ template class Im2SequenceKernel<CPU, float>;
}
// namespace operators
}
// namespace paddle_mobile
#endif
src/operators/kernel/dropout_kernel.h
浏览文件 @
5b03cddc
...
...
@@ -12,6 +12,8 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License. */
#ifdef DROPOUT_OP
#include "framework/operator.h"
#include "operators/op_param.h"
...
...
@@ -28,3 +30,5 @@ class DropoutKernel : public framework::OpKernelBase<DeviceType, DropoutParam> {
};
}
// namespace operators
}
// namespace paddle_mobile
#endif
src/operators/kernel/im2sequence_kernel.h
浏览文件 @
5b03cddc
...
...
@@ -12,6 +12,8 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License. */
#ifdef IM2SEQUENCE_OP
#include "framework/operator.h"
#include "operators/math/im2col.h"
#include "operators/math/math_function.h"
...
...
@@ -34,3 +36,5 @@ class Im2SequenceKernel
};
}
// namespace operators
}
// namespace paddle_mobile
#endif
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录