Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
P
pytensor
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
testgroup
pytensor
Commits
546daeff
提交
546daeff
authored
5月 24, 2017
作者:
notoraptor
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Add Python implementation for exhaustive tests (remove old bash version).
Synchronize configdefaults with #5964.
上级
8f2e37ac
全部展开
隐藏空白字符变更
内嵌
并排
正在显示
3 个修改的文件
包含
3 行增加
和
77 行删除
+3
-77
configdefaults.py
theano/configdefaults.py
+3
-3
check_dnn.py
theano/gpuarray/tests/check_dnn.py
+0
-0
check_dnn.sh
theano/gpuarray/tests/check_dnn.sh
+0
-74
没有找到文件。
theano/configdefaults.py
浏览文件 @
546daeff
...
...
@@ -346,20 +346,20 @@ AddConfigVar('dnn.conv.algo_bwd',
AddConfigVar
(
'dnn.conv.algo_fwd'
,
"Default implementation to use for cuDNN forward convolution."
,
EnumStr
(
*
(
SUPPORTED_DNN_CONV_ALGO_FWD
+
SUPPORTED_DNN_CONV_ALGO_RUNTIME
)
),
EnumStr
(
*
SUPPORTED_DNN_CONV_ALGO_FWD
),
in_c_key
=
False
)
AddConfigVar
(
'dnn.conv.algo_bwd_data'
,
"Default implementation to use for cuDNN backward convolution to "
"get the gradients of the convolution with regard to the inputs."
,
EnumStr
(
*
(
SUPPORTED_DNN_CONV_ALGO_BWD_DATA
+
SUPPORTED_DNN_CONV_ALGO_RUNTIME
)
),
EnumStr
(
*
SUPPORTED_DNN_CONV_ALGO_BWD_DATA
),
in_c_key
=
False
)
AddConfigVar
(
'dnn.conv.algo_bwd_filter'
,
"Default implementation to use for cuDNN backward convolution to "
"get the gradients of the convolution with regard to the "
"filters."
,
EnumStr
(
*
(
SUPPORTED_DNN_CONV_ALGO_BWD_FILTER
+
SUPPORTED_DNN_CONV_ALGO_RUNTIME
)
),
EnumStr
(
*
SUPPORTED_DNN_CONV_ALGO_BWD_FILTER
),
in_c_key
=
False
)
AddConfigVar
(
'dnn.conv.precision'
,
...
...
theano/gpuarray/tests/check_dnn.py
0 → 100644
浏览文件 @
546daeff
差异被折叠。
点击展开。
theano/gpuarray/tests/check_dnn.sh
deleted
100644 → 0
浏览文件 @
8f2e37ac
#!/usr/bin/env bash
## This command should make this script stop at first error occured
## or keyboard interruption received.
set
-e
## Get all DNN algorithms supported by Theano.
export
SUPPORTED_DNN_CONV_ALGO_FWD
=
$(
python
-c
"from theano.configdefaults import SUPPORTED_DNN_CONV_ALGO_RUNTIME, SUPPORTED_DNN_CONV_ALGO_FWD; print('
\n
'.join(SUPPORTED_DNN_CONV_ALGO_FWD + SUPPORTED_DNN_CONV_ALGO_RUNTIME))"
)
export
SUPPORTED_DNN_CONV_ALGO_BWD_DATA
=
$(
python
-c
"from theano.configdefaults import SUPPORTED_DNN_CONV_ALGO_RUNTIME, SUPPORTED_DNN_CONV_ALGO_BWD_DATA; print('
\n
'.join(SUPPORTED_DNN_CONV_ALGO_BWD_DATA + SUPPORTED_DNN_CONV_ALGO_RUNTIME))"
)
export
SUPPORTED_DNN_CONV_ALGO_BWD_FILTER
=
$(
python
-c
"from theano.configdefaults import SUPPORTED_DNN_CONV_ALGO_RUNTIME, SUPPORTED_DNN_CONV_ALGO_BWD_FILTER; print('
\n
'.join(SUPPORTED_DNN_CONV_ALGO_BWD_FILTER + SUPPORTED_DNN_CONV_ALGO_RUNTIME))"
)
export
SUPPORTED_DNN_CONV_PRECISION
=
$(
python
-c
"from theano.configdefaults import SUPPORTED_DNN_CONV_PRECISION; print('
\n
'.join(SUPPORTED_DNN_CONV_PRECISION))"
)
## List special Theano DNN tests that depend on DNN algorithms.
## Other Theano DNN tests will be run once.
## These special Theano DNN tests will be run
## for every combination of DNN algorithms.
declare
-a
special_tests
=(
'theano.gpuarray.tests.test_dnn.test_conv3d_bwd'
'theano.gpuarray.tests.test_dnn.test_conv3d_fwd'
'theano.gpuarray.tests.test_dnn.test_dnn_conv_alpha_output_merge'
'theano.gpuarray.tests.test_dnn.test_dnn_conv_border_mode'
'theano.gpuarray.tests.test_dnn.test_dnn_conv_grad'
'theano.gpuarray.tests.test_dnn.test_dnn_conv_inplace'
'theano.gpuarray.tests.test_dnn.test_dnn_conv_merge'
'theano.gpuarray.tests.test_dnn.TestDnnInferShapes'
)
## Precompute nosetests arguments used later.
# PB: To test quickly this script, you can temporarly
# add "--collect-only" arg into this variable.
export
NOSEARGS
=
"-xvs --collect-only"
#export NOSEARGS="-xvs"
# Convert list of special tests to a list of tests to be executed by nosetests.
export
SPECIAL_NOSETESTS
=
$(
echo
${
special_tests
[@]
}
|
sed
's/\.test_dnn\./.test_dnn:/g'
)
# Convert list of special tests to a list of tests to be excluded by nosetests.
export
SPECIAL_NOSETESTS_EXCLUDED
=
$(for
test
in
"
${
special_tests
[@]
}
"
;
do
echo
"--exclude-test=
$test
"
;
done)
## Run all Theano DNN tests without special tests.
echo
Running independent DNN tests.
THEANO_FLAGS
=
warn.dnn_recent
=
False
eval
"nosetests
$NOSEARGS
$(
echo
$SPECIAL_NOSETESTS_EXCLUDED
)
theano/gpuarray/tests/test_dnn.py"
## Run all special Theano DNN tests for every combination of DNN algorithms.
# This may take a very (very) long time.
echo
Running DNN tests depending on algorithms parameters.
for
fwd
in
$SUPPORTED_DNN_CONV_ALGO_FWD
do
for
bwd_filter
in
$SUPPORTED_DNN_CONV_ALGO_BWD_FILTER
do
for
bwd_data
in
$SUPPORTED_DNN_CONV_ALGO_BWD_DATA
do
for
precision
in
$SUPPORTED_DNN_CONV_PRECISION
do
# THEANO_FLAGS is set on multiple lines to avoid a declaration with one too long line.
export
THEANO_FLAGS
=
warn.dnn_recent
=
False
export
THEANO_FLAGS
=
$THEANO_FLAGS
,dnn.conv.algo_fwd
=
$fwd
export
THEANO_FLAGS
=
$THEANO_FLAGS
,dnn.conv.algo_bwd_data
=
$bwd_data
export
THEANO_FLAGS
=
$THEANO_FLAGS
,dnn.conv.algo_bwd_filter
=
$bwd_filter
export
THEANO_FLAGS
=
$THEANO_FLAGS
,dnn.conv.precision
=
$precision
echo
"Running with:
$THEANO_FLAGS
"
eval
"nosetests
$NOSEARGS
$SPECIAL_NOSETESTS
"
done
done
done
done
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论