Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
csdn_franckjun
Paddle
提交
de3c1527
P
Paddle
项目概览
csdn_franckjun
/
Paddle
与 Fork 源项目一致
Fork自
PaddlePaddle / Paddle
通知
1
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
1
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
P
Paddle
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
1
Issue
1
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
de3c1527
编写于
12月 27, 2016
作者:
L
liaogang
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Fix glog check type unmatch
上级
46cadaea
变更
6
隐藏空白更改
内联
并排
Showing
6 changed file
with
15 addition
and
14 deletion
+15
-14
paddle/function/cross_map_normal_op.cpp
paddle/function/cross_map_normal_op.cpp
+8
-8
paddle/gserver/layers/ConvProjection.cpp
paddle/gserver/layers/ConvProjection.cpp
+2
-1
paddle/gserver/tests/LayerGradUtil.cpp
paddle/gserver/tests/LayerGradUtil.cpp
+1
-1
paddle/gserver/tests/test_BatchNorm.cpp
paddle/gserver/tests/test_BatchNorm.cpp
+2
-2
paddle/gserver/tests/test_PyDataProvider2.cpp
paddle/gserver/tests/test_PyDataProvider2.cpp
+1
-1
paddle/math/Matrix.cpp
paddle/math/Matrix.cpp
+1
-1
未找到文件。
paddle/function/cross_map_normal_op.cpp
浏览文件 @
de3c1527
...
...
@@ -128,11 +128,11 @@ public:
void
calc
(
const
Arguments
&
inputs
,
const
Arguments
&
outputs
,
const
Arguments
&
inouts
)
override
{
CHECK_EQ
(
1
,
inputs
.
size
(
));
CHECK_EQ
(
2
,
outputs
.
size
(
));
CHECK_EQ
(
0
,
inouts
.
size
(
));
CHECK_EQ
(
1
,
static_cast
<
int
>
(
inputs
.
size
()
));
CHECK_EQ
(
2
,
static_cast
<
int
>
(
outputs
.
size
()
));
CHECK_EQ
(
0
,
static_cast
<
int
>
(
inouts
.
size
()
));
CHECK_EQ
(
inputs
[
0
].
dims_
.
size
(
),
4
);
CHECK_EQ
(
static_cast
<
int
>
(
inputs
[
0
].
dims_
.
size
()
),
4
);
for
(
size_t
i
=
0
;
i
<
inputs
[
0
].
dims_
.
size
();
i
++
)
{
CHECK_EQ
(
inputs
[
0
].
dims_
[
i
],
outputs
[
0
].
dims_
[
i
]);
CHECK_EQ
(
inputs
[
0
].
dims_
[
i
],
outputs
[
1
].
dims_
[
i
]);
...
...
@@ -180,11 +180,11 @@ public:
void
calc
(
const
Arguments
&
inputs
,
const
Arguments
&
outputs
,
const
Arguments
&
inouts
)
override
{
CHECK_EQ
(
4
,
inputs
.
size
(
));
CHECK_EQ
(
1
,
outputs
.
size
(
));
CHECK_EQ
(
0
,
inouts
.
size
(
));
CHECK_EQ
(
4
,
static_cast
<
int
>
(
inputs
.
size
()
));
CHECK_EQ
(
1
,
static_cast
<
int
>
(
outputs
.
size
()
));
CHECK_EQ
(
0
,
static_cast
<
int
>
(
inouts
.
size
()
));
CHECK_EQ
(
inputs
[
0
].
dims_
.
size
(
),
4
);
CHECK_EQ
(
static_cast
<
int
>
(
inputs
[
0
].
dims_
.
size
()
),
4
);
for
(
size_t
i
=
0
;
i
<
inputs
[
0
].
dims_
.
size
();
i
++
)
{
CHECK_EQ
(
inputs
[
0
].
dims_
[
i
],
inputs
[
1
].
dims_
[
i
]);
CHECK_EQ
(
inputs
[
0
].
dims_
[
i
],
inputs
[
2
].
dims_
[
i
]);
...
...
paddle/gserver/layers/ConvProjection.cpp
浏览文件 @
de3c1527
...
...
@@ -130,7 +130,8 @@ void ConvProjection::reshapeTensorDesc(int batchSize) {
void
ConvProjection
::
reshape
(
int
batchSize
)
{
size_t
width
=
calOutputSize
();
CHECK_EQ
(
width
,
out_
->
value
->
getWidth
());
CHECK_EQ
(
channels_
*
imageH_
*
imageW_
,
in_
->
value
->
getWidth
())
CHECK_EQ
(
static_cast
<
size_t
>
(
channels_
*
imageH_
*
imageW_
),
in_
->
value
->
getWidth
())
<<
"Wrong input size for convolution"
<<
" channels="
<<
channels_
<<
" imageH="
<<
imageH_
<<
" imageW="
<<
imageW_
<<
" inputSize="
<<
in_
->
value
->
getWidth
();
...
...
paddle/gserver/tests/LayerGradUtil.cpp
浏览文件 @
de3c1527
...
...
@@ -310,7 +310,7 @@ void initDataLayer(TestConfig testConf,
testConf
.
inputDefs
[
i
].
labelSeqStartPositions
;
if
(
labelSeqStartPositions
.
size
()
!=
0
)
{
CHECK
(
!
sequenceStartPositions
);
CHECK_GE
(
labelSeqStartPositions
.
size
(
),
2
);
CHECK_GE
(
static_cast
<
int
>
(
labelSeqStartPositions
.
size
()
),
2
);
sequenceStartPositions
=
ICpuGpuVector
::
create
(
labelSeqStartPositions
.
size
(),
useGpu
);
...
...
paddle/gserver/tests/test_BatchNorm.cpp
浏览文件 @
de3c1527
...
...
@@ -114,8 +114,8 @@ TEST(Layer, batchNorm) {
bnLayer
->
forward
(
PASS_GC
);
convLayer
->
forward
(
PASS_GC
);
CHECK_EQ
(
convLayer
->
getOutputValue
()
->
getHeight
(
),
100
);
CHECK_EQ
(
convLayer
->
getOutputValue
()
->
getWidth
(
),
576
);
CHECK_EQ
(
static_cast
<
int
>
(
convLayer
->
getOutputValue
()
->
getHeight
()
),
100
);
CHECK_EQ
(
static_cast
<
int
>
(
convLayer
->
getOutputValue
()
->
getWidth
()
),
576
);
}
int
main
(
int
argc
,
char
**
argv
)
{
...
...
paddle/gserver/tests/test_PyDataProvider2.cpp
浏览文件 @
de3c1527
...
...
@@ -293,7 +293,7 @@ TEST(PyDataProvider2, can_over_batch_size) {
while
(
true
)
{
int64_t
realBatchSize
=
provider
->
getNextBatchInternal
(
batchSize
,
&
batch
);
if
(
realBatchSize
)
{
CHECK_LE
(
realBatchSize
,
batchSize
);
CHECK_LE
(
static_cast
<
size_t
>
(
realBatchSize
)
,
batchSize
);
}
else
{
break
;
}
...
...
paddle/math/Matrix.cpp
浏览文件 @
de3c1527
...
...
@@ -2268,7 +2268,7 @@ void CpuMatrix::contextProjectionBackward(Matrix* inputGrad,
int64_t
inputDim
=
inputGrad
?
inputGrad
->
getWidth
()
:
weightGrad
?
weightGrad
->
getWidth
()
:
0
;
CHECK_EQ
(
getWidth
(),
inputDim
*
contextLength
);
CHECK_EQ
(
getWidth
(),
static_cast
<
size_t
>
(
inputDim
*
contextLength
)
);
const
int
*
starts
=
sequence
.
getData
();
size_t
numSequences
=
sequence
.
getSize
()
-
1
;
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录