Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
P
pytensor
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
testgroup
pytensor
Commits
93ded46f
提交
93ded46f
authored
12月 10, 2010
作者:
Frederic Bastien
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
put a member imshp into GpuConv for another version of it that is in development.
上级
b7283974
隐藏空白字符变更
内嵌
并排
正在显示
2 个修改的文件
包含
16 行增加
和
4 行删除
+16
-4
blas.py
theano/sandbox/cuda/blas.py
+14
-3
opt.py
theano/sandbox/cuda/opt.py
+2
-1
没有找到文件。
theano/sandbox/cuda/blas.py
浏览文件 @
93ded46f
...
@@ -266,7 +266,8 @@ class GpuConv(Op):
...
@@ -266,7 +266,8 @@ class GpuConv(Op):
logical_kern_align_top
=
True
,
logical_kern_align_top
=
True
,
version
=-
1
,
version
=-
1
,
verbose
=
0
,
verbose
=
0
,
kshp
=
None
):
kshp
=
None
,
imshp
=
None
):
"""
"""
:param version: each version of c_code implement many kernel for the
:param version: each version of c_code implement many kernel for the
convolution. By default we try to guess the best one.
convolution. By default we try to guess the best one.
...
@@ -278,6 +279,8 @@ class GpuConv(Op):
...
@@ -278,6 +279,8 @@ class GpuConv(Op):
:param kshp: The size of the kernel. If provided, can genera
:param kshp: The size of the kernel. If provided, can genera
faster code. If the GpuConv op is automatically inserted,
faster code. If the GpuConv op is automatically inserted,
we take its value automatically from the Conv op.
we take its value automatically from the Conv op.
:param imshp: The size of the image. Not used for code generation but
allow to select an experimental new version in another repo.
"""
"""
self
.
border_mode
=
border_mode
self
.
border_mode
=
border_mode
self
.
subsample
=
subsample
self
.
subsample
=
subsample
...
@@ -299,6 +302,7 @@ class GpuConv(Op):
...
@@ -299,6 +302,7 @@ class GpuConv(Op):
self
.
version
=
version
self
.
version
=
version
self
.
verbose
=
verbose
self
.
verbose
=
verbose
self
.
kshp
=
kshp
self
.
kshp
=
kshp
self
.
imshp
=
imshp
def
__eq__
(
self
,
other
):
def
__eq__
(
self
,
other
):
return
type
(
self
)
==
type
(
other
)
\
return
type
(
self
)
==
type
(
other
)
\
...
@@ -309,7 +313,13 @@ class GpuConv(Op):
...
@@ -309,7 +313,13 @@ class GpuConv(Op):
and
self
.
logical_kern_align_top
==
other
.
logical_kern_align_top
\
and
self
.
logical_kern_align_top
==
other
.
logical_kern_align_top
\
and
self
.
version
==
other
.
version
\
and
self
.
version
==
other
.
version
\
and
self
.
verbose
==
other
.
verbose
\
and
self
.
verbose
==
other
.
verbose
\
and
self
.
kshp
==
other
.
kshp
and
self
.
kshp
==
other
.
kshp
\
and
self
.
imshp
==
other
.
imshp
def
__setstate__
(
self
,
d
):
self
.
__dict__
.
update
(
d
)
if
not
hasattr
(
self
,
"imshp"
):
self
.
imshp
=
None
def
__hash__
(
self
):
def
__hash__
(
self
):
# don't use hash(self.version) as hash(-1)==-2 and hash(-2)==-2 in python!
# don't use hash(self.version) as hash(-1)==-2 and hash(-2)==-2 in python!
...
@@ -321,7 +331,8 @@ class GpuConv(Op):
...
@@ -321,7 +331,8 @@ class GpuConv(Op):
^
hash
(
self
.
logical_kern_align_top
)
\
^
hash
(
self
.
logical_kern_align_top
)
\
^
self
.
version
\
^
self
.
version
\
^
hash
(
self
.
verbose
)
\
^
hash
(
self
.
verbose
)
\
^
hash
(
self
.
kshp
)
^
hash
(
self
.
kshp
)
\
^
hash
(
self
.
imshp
)
def
__str__
(
self
):
def
__str__
(
self
):
return
'
%
s{
%
s,
%
s,
%
s,
%
s,
%
s}'
%
(
self
.
__class__
.
__name__
,
return
'
%
s{
%
s,
%
s,
%
s,
%
s,
%
s}'
%
(
self
.
__class__
.
__name__
,
...
...
theano/sandbox/cuda/opt.py
浏览文件 @
93ded46f
...
@@ -606,7 +606,8 @@ def local_gpu_conv(node):
...
@@ -606,7 +606,8 @@ def local_gpu_conv(node):
logical_kern_align_top
=
op
.
kshp_logical_top_aligned
,
logical_kern_align_top
=
op
.
kshp_logical_top_aligned
,
kshp
=
op
.
kshp
,
kshp
=
op
.
kshp
,
version
=
op
.
version
,
version
=
op
.
version
,
verbose
=
op
.
verbose
verbose
=
op
.
verbose
,
imshp
=
op
.
imshp
,
)
)
#HACK to print the number of MFlops in the profiler output.
#HACK to print the number of MFlops in the profiler output.
if
hasattr
(
op
,
'flops'
):
if
hasattr
(
op
,
'flops'
):
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论