Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
PaddlePaddle
Paddle
提交
8d3ce01f
P
Paddle
项目概览
PaddlePaddle
/
Paddle
大约 1 年 前同步成功
通知
2299
Star
20931
Fork
5422
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
1423
列表
看板
标记
里程碑
合并请求
543
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
P
Paddle
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
1,423
Issue
1,423
列表
看板
标记
里程碑
合并请求
543
合并请求
543
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
8d3ce01f
编写于
4月 11, 2018
作者:
S
Siddharth Goyal
提交者:
Abhinav Arora
4月 11, 2018
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Fix cpplint errors for a set of operators (#9837)
* Fix cpplint errors, round2 * Fix pointer issue
上级
f605f647
变更
22
隐藏空白更改
内联
并排
Showing
22 changed file
with
35 addition
and
13 deletion
+35
-13
paddle/fluid/operators/ctc_align_op.cu
paddle/fluid/operators/ctc_align_op.cu
+1
-0
paddle/fluid/operators/ctc_align_op.h
paddle/fluid/operators/ctc_align_op.h
+1
-0
paddle/fluid/operators/elementwise_op.h
paddle/fluid/operators/elementwise_op.h
+7
-6
paddle/fluid/operators/gru_op.cc
paddle/fluid/operators/gru_op.cc
+1
-0
paddle/fluid/operators/gru_op.h
paddle/fluid/operators/gru_op.h
+3
-4
paddle/fluid/operators/im2sequence_op.cc
paddle/fluid/operators/im2sequence_op.cc
+1
-0
paddle/fluid/operators/im2sequence_op.h
paddle/fluid/operators/im2sequence_op.h
+1
-1
paddle/fluid/operators/label_smooth_op.cc
paddle/fluid/operators/label_smooth_op.cc
+1
-0
paddle/fluid/operators/linear_chain_crf_op.h
paddle/fluid/operators/linear_chain_crf_op.h
+1
-1
paddle/fluid/operators/logical_op.cc
paddle/fluid/operators/logical_op.cc
+1
-0
paddle/fluid/operators/lrn_op.cc
paddle/fluid/operators/lrn_op.cc
+1
-0
paddle/fluid/operators/lstm_op.cc
paddle/fluid/operators/lstm_op.cc
+1
-0
paddle/fluid/operators/lstm_op.h
paddle/fluid/operators/lstm_op.h
+1
-0
paddle/fluid/operators/lstm_unit_op.cu
paddle/fluid/operators/lstm_unit_op.cu
+1
-0
paddle/fluid/operators/lstmp_op.cc
paddle/fluid/operators/lstmp_op.cc
+1
-0
paddle/fluid/operators/lstmp_op.h
paddle/fluid/operators/lstmp_op.h
+1
-0
paddle/fluid/operators/matmul_op.cc
paddle/fluid/operators/matmul_op.cc
+2
-0
paddle/fluid/operators/matmul_op.h
paddle/fluid/operators/matmul_op.h
+3
-1
paddle/fluid/operators/maxout_op.cc
paddle/fluid/operators/maxout_op.cc
+2
-0
paddle/fluid/operators/minus_op.cc
paddle/fluid/operators/minus_op.cc
+2
-0
paddle/fluid/operators/momentum_op.cu
paddle/fluid/operators/momentum_op.cu
+1
-0
paddle/fluid/operators/mul_op.cc
paddle/fluid/operators/mul_op.cc
+1
-0
未找到文件。
paddle/fluid/operators/ctc_align_op.cu
浏览文件 @
8d3ce01f
...
...
@@ -15,6 +15,7 @@ limitations under the License. */
#include <stdio.h>
#include <thrust/device_vector.h>
#include <thrust/host_vector.h>
#include <vector>
#include "paddle/fluid/operators/ctc_align_op.h"
namespace
paddle
{
...
...
paddle/fluid/operators/ctc_align_op.h
浏览文件 @
8d3ce01f
...
...
@@ -15,6 +15,7 @@ limitations under the License. */
#pragma once
#include <string.h>
#include <vector>
#include "paddle/fluid/framework/op_registry.h"
#include "paddle/fluid/operators/math/math_function.h"
...
...
paddle/fluid/operators/elementwise_op.h
浏览文件 @
8d3ce01f
...
...
@@ -13,6 +13,7 @@ See the License for the specific language governing permissions and
limitations under the License. */
#pragma once
#include <string>
#include "paddle/fluid/framework/op_registry.h"
#include "paddle/fluid/framework/operator.h"
...
...
@@ -106,18 +107,18 @@ information. However, the output only shares the LoD information with input $X$.
protected:
std
::
string
comment_
;
void
Replace
(
std
::
string
&
src
,
std
::
string
from
,
std
::
string
to
)
{
void
Replace
(
std
::
string
*
src
,
std
::
string
from
,
std
::
string
to
)
{
std
::
size_t
len_from
=
std
::
strlen
(
from
.
c_str
());
std
::
size_t
len_to
=
std
::
strlen
(
to
.
c_str
());
for
(
std
::
size_t
pos
=
src
.
find
(
from
);
pos
!=
std
::
string
::
npos
;
pos
=
src
.
find
(
from
,
pos
+
len_to
))
{
src
.
replace
(
pos
,
len_from
,
to
);
for
(
std
::
size_t
pos
=
src
->
find
(
from
);
pos
!=
std
::
string
::
npos
;
pos
=
src
->
find
(
from
,
pos
+
len_to
))
{
src
->
replace
(
pos
,
len_from
,
to
);
}
}
void
SetComment
(
std
::
string
name
,
std
::
string
equation
)
{
Replace
(
comment_
,
"{name}"
,
name
);
Replace
(
comment_
,
"{equation}"
,
equation
);
Replace
(
&
comment_
,
"{name}"
,
name
);
Replace
(
&
comment_
,
"{equation}"
,
equation
);
}
};
...
...
paddle/fluid/operators/gru_op.cc
浏览文件 @
8d3ce01f
...
...
@@ -13,6 +13,7 @@ See the License for the specific language governing permissions and
limitations under the License. */
#include "paddle/fluid/operators/gru_op.h"
#include <string>
namespace
paddle
{
namespace
operators
{
...
...
paddle/fluid/operators/gru_op.h
浏览文件 @
8d3ce01f
...
...
@@ -13,15 +13,14 @@ See the License for the specific language governing permissions and
limitations under the License. */
#pragma once
#include <string>
#include "paddle/fluid/framework/eigen.h"
#include "paddle/fluid/framework/op_registry.h"
#include "paddle/fluid/operators/math/detail/activation_functions.h"
#include "paddle/fluid/operators/math/gru_compute.h"
#include "paddle/fluid/operators/math/math_function.h"
#include "paddle/fluid/operators/math/sequence2batch.h"
#include "paddle/fluid/framework/eigen.h"
#include "paddle/fluid/framework/op_registry.h"
namespace
paddle
{
namespace
operators
{
...
...
paddle/fluid/operators/im2sequence_op.cc
浏览文件 @
8d3ce01f
...
...
@@ -13,6 +13,7 @@ See the License for the specific language governing permissions and
limitations under the License. */
#include "paddle/fluid/operators/im2sequence_op.h"
#include <vector>
namespace
paddle
{
namespace
operators
{
...
...
paddle/fluid/operators/im2sequence_op.h
浏览文件 @
8d3ce01f
...
...
@@ -13,7 +13,7 @@
limitations under the License. */
#pragma once
#include <vector>
#include "paddle/fluid/framework/data_layout.h"
#include "paddle/fluid/framework/eigen.h"
#include "paddle/fluid/framework/op_registry.h"
...
...
paddle/fluid/operators/label_smooth_op.cc
浏览文件 @
8d3ce01f
...
...
@@ -13,6 +13,7 @@ See the License for the specific language governing permissions and
limitations under the License. */
#include "paddle/fluid/operators/label_smooth_op.h"
#include <string>
namespace
paddle
{
namespace
operators
{
...
...
paddle/fluid/operators/linear_chain_crf_op.h
浏览文件 @
8d3ce01f
...
...
@@ -100,7 +100,7 @@ class LinearChainCRFOpKernel : public framework::OpKernel<T> {
auto
x_row_max
=
EigenMatrix
<
T
>::
From
(
emission_row_max
);
x_row_max
.
device
(
place
)
=
x
.
maximum
(
Eigen
::
DSizes
<
int
,
1
>
(
1
))
.
reshape
(
Eigen
::
DSizes
<
int
,
2
>
(
int
(
batch_size
),
1
));
.
reshape
(
Eigen
::
DSizes
<
int
,
2
>
(
static_cast
<
int
>
(
batch_size
),
1
));
auto
x_exps
=
EigenMatrix
<
T
>::
From
(
*
emission_exps
);
x_exps
.
device
(
place
)
=
...
...
paddle/fluid/operators/logical_op.cc
浏览文件 @
8d3ce01f
...
...
@@ -13,6 +13,7 @@ See the License for the specific language governing permissions and
limitations under the License. */
#include "paddle/fluid/operators/logical_op.h"
#include <string>
#include "paddle/fluid/framework/op_registry.h"
namespace
paddle
{
...
...
paddle/fluid/operators/lrn_op.cc
浏览文件 @
8d3ce01f
...
...
@@ -13,6 +13,7 @@ See the License for the specific language governing permissions and
limitations under the License. */
#include "paddle/fluid/operators/lrn_op.h"
#include <string>
#ifdef PADDLE_WITH_MKLDNN
#include "paddle/fluid/platform/mkldnn_helper.h"
#endif
...
...
paddle/fluid/operators/lstm_op.cc
浏览文件 @
8d3ce01f
...
...
@@ -13,6 +13,7 @@ See the License for the specific language governing permissions and
limitations under the License. */
#include "paddle/fluid/operators/lstm_op.h"
#include <string>
namespace
paddle
{
namespace
operators
{
...
...
paddle/fluid/operators/lstm_op.h
浏览文件 @
8d3ce01f
...
...
@@ -13,6 +13,7 @@ See the License for the specific language governing permissions and
limitations under the License. */
#pragma once
#include <string>
#include "paddle/fluid/framework/op_registry.h"
#include "paddle/fluid/operators/math/detail/activation_functions.h"
#include "paddle/fluid/operators/math/lstm_compute.h"
...
...
paddle/fluid/operators/lstm_unit_op.cu
浏览文件 @
8d3ce01f
...
...
@@ -18,6 +18,7 @@ https://github.com/caffe2/caffe2/blob/master/caffe2/operators/lstm_unit_op_gpu.c
#include "paddle/fluid/framework/op_registry.h"
#include "paddle/fluid/operators/cross_entropy_op.h"
#include "paddle/fluid/operators/lstm_unit_op.h"
#include "paddle/fluid/platform/assert.h"
#include "paddle/fluid/platform/hostdevice.h"
...
...
paddle/fluid/operators/lstmp_op.cc
浏览文件 @
8d3ce01f
...
...
@@ -13,6 +13,7 @@ See the License for the specific language governing permissions and
limitations under the License. */
#include "paddle/fluid/operators/lstmp_op.h"
#include <string>
namespace
paddle
{
namespace
operators
{
...
...
paddle/fluid/operators/lstmp_op.h
浏览文件 @
8d3ce01f
...
...
@@ -13,6 +13,7 @@ See the License for the specific language governing permissions and
limitations under the License. */
#pragma once
#include <string>
#include "paddle/fluid/operators/activation_op.h"
#include "paddle/fluid/operators/math/detail/activation_functions.h"
#include "paddle/fluid/operators/math/lstm_compute.h"
...
...
paddle/fluid/operators/matmul_op.cc
浏览文件 @
8d3ce01f
...
...
@@ -13,6 +13,8 @@ See the License for the specific language governing permissions and
limitations under the License. */
#include "paddle/fluid/operators/matmul_op.h"
#include <algorithm>
#include <vector>
namespace
paddle
{
namespace
operators
{
...
...
paddle/fluid/operators/matmul_op.h
浏览文件 @
8d3ce01f
...
...
@@ -13,7 +13,9 @@ See the License for the specific language governing permissions and
limitations under the License. */
#pragma once
#include <algorithm>
#include <functional>
#include <vector>
#include "paddle/fluid/framework/op_registry.h"
#include "paddle/fluid/operators/math/math_function.h"
#include "paddle/fluid/operators/math/matmul.h"
...
...
paddle/fluid/operators/maxout_op.cc
浏览文件 @
8d3ce01f
...
...
@@ -13,6 +13,8 @@
* limitations under the License. */
#include "paddle/fluid/operators/maxout_op.h"
#include <vector>
namespace
paddle
{
namespace
operators
{
...
...
paddle/fluid/operators/minus_op.cc
浏览文件 @
8d3ce01f
...
...
@@ -13,6 +13,8 @@ See the License for the specific language governing permissions and
limitations under the License. */
#include "paddle/fluid/operators/minus_op.h"
#include <string>
#include <vector>
#include "paddle/fluid/operators/net_op.h"
namespace
paddle
{
...
...
paddle/fluid/operators/momentum_op.cu
浏览文件 @
8d3ce01f
...
...
@@ -13,6 +13,7 @@ See the License for the specific language governing permissions and
limitations under the License. */
#include "paddle/fluid/framework/op_registry.h"
#include "paddle/fluid/operators/momentum_op.h"
namespace
paddle
{
namespace
operators
{
...
...
paddle/fluid/operators/mul_op.cc
浏览文件 @
8d3ce01f
...
...
@@ -13,6 +13,7 @@ See the License for the specific language governing permissions and
limitations under the License. */
#include "paddle/fluid/operators/mul_op.h"
#include <vector>
namespace
paddle
{
namespace
operators
{
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录