Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
P
pytensor
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
testgroup
pytensor
Commits
5a116137
提交
5a116137
authored
9月 07, 2017
作者:
Frederic Bastien
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Again skip tests when cudnn isn't there
上级
2bdfda4a
隐藏空白字符变更
内嵌
并排
正在显示
1 个修改的文件
包含
16 行增加
和
2 行删除
+16
-2
test_dnn.py
theano/gpuarray/tests/test_dnn.py
+16
-2
没有找到文件。
theano/gpuarray/tests/test_dnn.py
浏览文件 @
5a116137
...
...
@@ -584,6 +584,8 @@ class TestDnnInferShapes(utt.InferShapeTester):
conv_modes
=
[
'conv'
,
'cross'
]
def
setUp
(
self
):
if
not
dnn
.
dnn_available
(
test_ctx_name
):
raise
SkipTest
(
dnn
.
dnn_available
.
msg
)
super
(
TestDnnInferShapes
,
self
)
.
setUp
()
self
.
mode
=
mode_with_gpu
...
...
@@ -1032,6 +1034,8 @@ def test_dnn_conv_grad():
def
get_conv3d_test_cases
():
if
not
dnn
.
dnn_available
(
test_ctx_name
):
raise
SkipTest
(
dnn
.
dnn_available
.
msg
)
# Every element of test_shapes follows the format
# [input_shape, filter_shape, subsample, dilation]
test_shapes
=
[[(
128
,
3
,
5
,
5
,
5
),
(
64
,
3
,
1
,
2
,
4
),
(
1
,
1
,
1
),
(
1
,
1
,
1
)],
...
...
@@ -1117,14 +1121,18 @@ def run_conv_small_batched_vs_multicall(inputs_shape, filters_shape, batch_sub):
def
test_batched_conv_small
():
# OK
if
not
dnn
.
dnn_available
(
test_ctx_name
):
raise
SkipTest
(
dnn
.
dnn_available
.
msg
)
yield
(
run_conv_small_batched_vs_multicall
,
(
65536
,
2
,
2
,
2
),
(
1
,
2
,
2
,
2
),
5
)
# Should fail with cuDNN < V6020, but there's currently a workaround in `dnn_fwd.c` for that case.
yield
(
run_conv_small_batched_vs_multicall
,
(
65537
,
2
,
2
,
2
),
(
1
,
2
,
2
,
2
),
5
)
def
test_batched_conv3d_small
():
# OK
if
not
dnn
.
dnn_available
(
test_ctx_name
):
raise
SkipTest
(
dnn
.
dnn_available
.
msg
)
yield
(
run_conv_small_batched_vs_multicall
,
(
65536
,
2
,
2
,
2
,
2
),
(
1
,
2
,
2
,
2
,
2
),
5
)
# Should fail with cuDNN < V6020, but there's currently a workaround in `dnn_fwd.c` for that case.
yield
(
run_conv_small_batched_vs_multicall
,
(
65537
,
2
,
2
,
2
,
2
),
(
1
,
2
,
2
,
2
,
2
),
5
)
...
...
@@ -1529,11 +1537,15 @@ def dnn_reduction_strides(shp, shuffle, slice):
def
test_dnn_reduction_strides
():
if
not
dnn
.
dnn_available
(
test_ctx_name
):
raise
SkipTest
(
dnn
.
dnn_available
.
msg
)
yield
dnn_reduction_strides
,
(
2
,
3
,
2
),
(
1
,
0
,
2
),
slice
(
None
,
None
,
None
)
yield
dnn_reduction_strides
,
(
2
,
3
,
2
),
(
0
,
1
,
2
),
slice
(
None
,
None
,
-
1
)
def
test_dnn_reduction_error
():
if
not
dnn
.
dnn_available
(
test_ctx_name
):
raise
SkipTest
(
dnn
.
dnn_available
.
msg
)
nLoops
=
5
vec
=
np
.
arange
(
0
,
10
,
dtype
=
np
.
float32
)
slow_output
=
np
.
zeros
((
5
,
10
))
...
...
@@ -2708,6 +2720,8 @@ class TestDnnConv3DRuntimeAlgorithms(TestDnnConv2DRuntimeAlgorithms):
def
test_conv_guess_once_with_dtypes
():
# This test checks that runtime conv algorithm selection does not raise any exception
# when consecutive functions with different dtypes and precisions are executed.
if
not
dnn
.
dnn_available
(
test_ctx_name
):
raise
SkipTest
(
dnn
.
dnn_available
.
msg
)
utt
.
seed_rng
()
inputs_shape
=
(
2
,
3
,
5
,
5
)
filters_shape
=
(
2
,
3
,
40
,
4
)
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论