Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
PaddlePaddle
Paddle
提交
fa8bab9c
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看板
提交
fa8bab9c
编写于
12月 30, 2019
作者:
F
FDInSky
提交者:
Zhang Ting
12月 30, 2019
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
add fp64 check_grad for conv2d, conv3d (#21931)
* test=develop add fp64 check_grad for conv2d, conv3d
上级
cf7b3253
变更
4
显示空白变更内容
内联
并排
Showing
4 changed file
with
25 addition
and
5 deletion
+25
-5
python/paddle/fluid/tests/unittests/mkldnn/test_conv2d_mkldnn_op.py
...dle/fluid/tests/unittests/mkldnn/test_conv2d_mkldnn_op.py
+3
-0
python/paddle/fluid/tests/unittests/mkldnn/test_conv3d_mkldnn_op.py
...dle/fluid/tests/unittests/mkldnn/test_conv3d_mkldnn_op.py
+18
-1
python/paddle/fluid/tests/unittests/test_conv2d_op.py
python/paddle/fluid/tests/unittests/test_conv2d_op.py
+2
-2
python/paddle/fluid/tests/unittests/test_conv3d_op.py
python/paddle/fluid/tests/unittests/test_conv3d_op.py
+2
-2
未找到文件。
python/paddle/fluid/tests/unittests/mkldnn/test_conv2d_mkldnn_op.py
浏览文件 @
fa8bab9c
...
...
@@ -44,6 +44,7 @@ class TestConv2dMKLDNNOp(TestConv2dOp):
self
.
data_format
=
"NCHW"
self
.
use_mkldnn
=
True
self
.
_cpu_only
=
True
self
.
dtype
=
np
.
float32
def
init_test_case
(
self
):
self
.
pad
=
[
0
,
0
]
...
...
@@ -62,6 +63,7 @@ class TestConv2dMKLDNNOp(TestConv2dOp):
self
.
fuse_brelu_threshold
=
6.0
self
.
fuse_residual_connection
=
False
self
.
input_residual_size
=
None
TestConv2dOp
.
setUp
(
self
)
output
=
self
.
outputs
[
'Output'
]
...
...
@@ -179,6 +181,7 @@ class TestWithInput1x1Filter1x1(TestConv2dMKLDNNOp):
class
TestConv2dOp_AsyPadding_MKLDNN
(
TestConv2dOp_v2
):
def
init_kernel_type
(
self
):
self
.
use_mkldnn
=
True
self
.
dtype
=
np
.
float32
def
init_paddings
(
self
):
self
.
pad
=
[
0
,
0
,
1
,
2
]
...
...
python/paddle/fluid/tests/unittests/mkldnn/test_conv3d_mkldnn_op.py
浏览文件 @
fa8bab9c
...
...
@@ -15,7 +15,7 @@
from
__future__
import
print_function
import
unittest
import
numpy
as
np
from
paddle.fluid.tests.unittests.test_conv3d_op
import
TestConv3dOp
,
TestCase1
,
TestWithGroup1
,
TestWithGroup2
,
TestWith1x1
,
TestWithInput1x1Filter1x1
,
TestConv3dOp_2
...
...
@@ -23,42 +23,49 @@ class TestMKLDNN(TestConv3dOp):
def
init_kernel_type
(
self
):
self
.
use_mkldnn
=
True
self
.
data_format
=
"NCHW"
self
.
dtype
=
np
.
float32
class
TestMKLDNNCase1
(
TestCase1
):
def
init_kernel_type
(
self
):
self
.
use_mkldnn
=
True
self
.
data_format
=
"NCHW"
self
.
dtype
=
np
.
float32
class
TestMKLDNNGroup1
(
TestWithGroup1
):
def
init_kernel_type
(
self
):
self
.
use_mkldnn
=
True
self
.
data_format
=
"NCHW"
self
.
dtype
=
np
.
float32
class
TestMKLDNNGroup2
(
TestWithGroup2
):
def
init_kernel_type
(
self
):
self
.
use_mkldnn
=
True
self
.
data_format
=
"NCHW"
self
.
dtype
=
np
.
float32
class
TestMKLDNNWith1x1
(
TestWith1x1
):
def
init_kernel_type
(
self
):
self
.
use_mkldnn
=
True
self
.
data_format
=
"NCHW"
self
.
dtype
=
np
.
float32
class
TestMKLDNNWithInput1x1Filter1x1
(
TestWithInput1x1Filter1x1
):
def
init_kernel_type
(
self
):
self
.
use_mkldnn
=
True
self
.
data_format
=
"NCHW"
self
.
dtype
=
np
.
float32
class
TestConv3dOp_AsyPadding_MKLDNN
(
TestConv3dOp
):
def
init_kernel_type
(
self
):
self
.
use_mkldnn
=
True
self
.
data_format
=
"NCHW"
self
.
dtype
=
np
.
float32
def
init_paddings
(
self
):
self
.
pad
=
[
1
,
0
,
1
,
0
,
0
,
2
]
...
...
@@ -70,12 +77,22 @@ class TestConv3dOp_Same_MKLDNN(TestConv3dOp_AsyPadding_MKLDNN):
self
.
pad
=
[
0
,
0
,
0
]
self
.
padding_algorithm
=
"SAME"
def
init_kernel_type
(
self
):
self
.
use_mkldnn
=
True
self
.
data_format
=
"NCHW"
self
.
dtype
=
np
.
float32
class
TestConv3dOp_Valid_MKLDNN
(
TestConv3dOp_AsyPadding_MKLDNN
):
def
init_paddings
(
self
):
self
.
pad
=
[
1
,
1
,
1
]
self
.
padding_algorithm
=
"VALID"
def
init_kernel_type
(
self
):
self
.
use_mkldnn
=
True
self
.
data_format
=
"NCHW"
self
.
dtype
=
np
.
float32
if
__name__
==
'__main__'
:
unittest
.
main
()
python/paddle/fluid/tests/unittests/test_conv2d_op.py
浏览文件 @
fa8bab9c
...
...
@@ -298,7 +298,7 @@ class TestConv2dOp(OpTest):
self
.
use_mkldnn
=
False
self
.
fuse_relu_before_depthwise_conv
=
False
self
.
data_format
=
"AnyLayout"
self
.
dtype
=
np
.
float
32
self
.
dtype
=
np
.
float
64
self
.
init_kernel_type
()
self
.
init_group
()
self
.
init_dilation
()
...
...
@@ -723,7 +723,7 @@ class TestConv2dOp_v2(OpTest):
self
.
use_cuda
=
False
self
.
use_mkldnn
=
False
self
.
fuse_relu_before_depthwise_conv
=
False
self
.
dtype
=
np
.
float
32
self
.
dtype
=
np
.
float
64
self
.
init_kernel_type
()
self
.
init_group
()
self
.
init_dilation
()
...
...
python/paddle/fluid/tests/unittests/test_conv3d_op.py
浏览文件 @
fa8bab9c
...
...
@@ -234,7 +234,7 @@ class TestConv3dOp(OpTest):
self
.
use_cudnn
=
False
self
.
use_mkldnn
=
False
self
.
data_format
=
"AnyLayout"
self
.
dtype
=
np
.
float
32
self
.
dtype
=
np
.
float
64
self
.
init_kernel_type
()
self
.
init_group
()
self
.
init_dilation
()
...
...
@@ -525,7 +525,7 @@ class TestConv3dOp_2(OpTest):
self
.
use_cudnn
=
False
self
.
use_mkldnn
=
False
self
.
data_format
=
"NCDHW"
self
.
dtype
=
np
.
float
32
self
.
dtype
=
np
.
float
64
self
.
init_kernel_type
()
self
.
init_group
()
self
.
init_dilation
()
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录