Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
P
pytensor
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
testgroup
pytensor
Commits
77b65acd
提交
77b65acd
authored
5月 22, 2012
作者:
Frederic Bastien
提交者:
Frederic
5月 23, 2012
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Make the gpu version of DownsampleFactorMax and its grad don't crash on bigger inputs
上级
de522246
全部展开
隐藏空白字符变更
内嵌
并排
正在显示
2 个修改的文件
包含
11 行增加
和
1 行删除
+11
-1
blas.py
theano/sandbox/cuda/blas.py
+0
-0
test_blas.py
theano/sandbox/cuda/tests/test_blas.py
+11
-1
没有找到文件。
theano/sandbox/cuda/blas.py
浏览文件 @
77b65acd
差异被折叠。
点击展开。
theano/sandbox/cuda/tests/test_blas.py
浏览文件 @
77b65acd
...
@@ -269,6 +269,8 @@ def test_downsample():
...
@@ -269,6 +269,8 @@ def test_downsample():
(
1
,
1
,
10
,
1023
),
(
1
,
1
,
10
,
1023
),
(
1
,
1
,
1025
,
10
),
(
1
,
1
,
1025
,
10
),
(
1
,
1
,
1023
,
10
),
(
1
,
1
,
1023
,
10
),
(
65536
,
1
,
10
,
10
),
(
1
,
65536
,
10
,
10
),
]
]
numpy
.
random
.
RandomState
(
unittest_tools
.
fetch_seed
())
.
shuffle
(
shps
)
numpy
.
random
.
RandomState
(
unittest_tools
.
fetch_seed
())
.
shuffle
(
shps
)
...
@@ -299,6 +301,14 @@ def test_downsample():
...
@@ -299,6 +301,14 @@ def test_downsample():
for
node
in
f2
.
maker
.
env
.
toposort
()])
for
node
in
f2
.
maker
.
env
.
toposort
()])
assert
numpy
.
allclose
(
f
(),
f2
())
assert
numpy
.
allclose
(
f
(),
f2
())
# The grad is too slow on GT220 GPU
# This cause the computer to freeze...
# Remove this when it get optimized enought
# This only bypass the last 2 checks
# Those tests where passing in all Mode on a GTX470
if
shp
[
0
]
>
30000
or
shp
[
1
]
>
30000
:
continue
g
=
pfunc
(
g
=
pfunc
(
[],
[],
tensor
.
grad
(
ds_op
(
tensor
.
as_tensor_variable
(
a
))
.
sum
(),
tensor
.
grad
(
ds_op
(
tensor
.
as_tensor_variable
(
a
))
.
sum
(),
...
@@ -314,7 +324,7 @@ def test_downsample():
...
@@ -314,7 +324,7 @@ def test_downsample():
for
node
in
g
.
maker
.
env
.
toposort
()])
for
node
in
g
.
maker
.
env
.
toposort
()])
assert
any
([
isinstance
(
node
.
op
,
DownsampleFactorMaxGrad
)
assert
any
([
isinstance
(
node
.
op
,
DownsampleFactorMaxGrad
)
for
node
in
g2
.
maker
.
env
.
toposort
()])
for
node
in
g2
.
maker
.
env
.
toposort
()])
assert
numpy
.
allclose
(
g
(),
g2
())
assert
numpy
.
allclose
(
g
(),
g2
())
,
shp
# We already check that the gpu version return
# We already check that the gpu version return
# the same value as the gpu version for
# the same value as the gpu version for
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论