Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
P
pytensor
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
testgroup
pytensor
Commits
a4ed0e85
提交
a4ed0e85
authored
3月 29, 2022
作者:
Brandon T. Willard
提交者:
Brandon T. Willard
4月 07, 2022
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Remove unnecessary GPU-related options in ConvOp
上级
e6d07bcb
隐藏空白字符变更
内嵌
并排
正在显示
1 个修改的文件
包含
2 行增加
和
27 行删除
+2
-27
conv.py
aesara/tensor/nnet/conv.py
+2
-27
没有找到文件。
aesara/tensor/nnet/conv.py
浏览文件 @
a4ed0e85
...
...
@@ -262,14 +262,6 @@ class ConvOp(OpenMPOp):
Use a version of c_code that unroll the batch
(by unroll_batch) and the nkern(by unroll_kern) loop. The size
must by a multiple of bsize or nkern respectively.
verbose : int
Passed to GpuConv.
version: int or str
Passed to GpuConv, if version='no_fft', fft
optimization will be deactivated at the op level.
direction_hint: {'forward', 'bprop weights', 'bprop inputs'}
Passed to GpuConv, used by graph optimizers to aid algorithm choice.
The 3 following parameters are used internally when we generate
the gradient when dx!=1 or dy!=1.
...
...
@@ -435,18 +427,9 @@ class ConvOp(OpenMPOp):
imshp_logical
=
None
,
kshp_logical
=
None
,
kshp_logical_top_aligned
=
True
,
verbose
=
0
,
version
=-
1
,
direction_hint
=
"forward"
,
verbose
=
False
,
openmp
=
None
,
):
# Deactivate fft_optimization at the op level if specified
if
version
==
"no_fft"
:
self
.
fft_opt
=
False
version
=
-
1
else
:
self
.
fft_opt
=
True
# Expand unknown image / kernel shapes into tuples of Nones
if
imshp
is
None
:
imshp
=
(
None
,
None
,
None
)
...
...
@@ -491,16 +474,13 @@ class ConvOp(OpenMPOp):
if
not
all_shape
or
self
.
openmp
:
# Only this version is parallelized
unroll_patch
=
True
self
.
verbose
=
verbose
self
.
imshp
=
imshp
self
.
kshp
=
kshp
self
.
nkern
=
nkern
self
.
bsize
=
bsize
self
.
dx
=
dx
self
.
dy
=
dy
self
.
verbose
=
verbose
self
.
version
=
version
self
.
direction_hint
=
direction_hint
# a triple
if
imshp_logical
is
None
:
...
...
@@ -687,7 +667,6 @@ class ConvOp(OpenMPOp):
def
__setstate__
(
self
,
d
):
super
()
.
__setstate__
(
d
)
self
.
direction_hint
=
d
.
get
(
"direction_hint"
,
None
)
self
.
_rehash
()
def
_rehash
(
self
):
...
...
@@ -1074,8 +1053,6 @@ class ConvOp(OpenMPOp):
imshp_logical
=
imshp_logical
,
kshp_logical
=
kshp_logical
,
kshp_logical_top_aligned
=
kshp_logical_top_aligned
,
version
=
self
.
version
,
direction_hint
=
"bprop weights"
,
verbose
=
self
.
verbose
,
)
...
...
@@ -1113,8 +1090,6 @@ class ConvOp(OpenMPOp):
unroll_patch
=
None
,
imshp_logical
=
imshp_logical
,
kshp_logical
=
None
,
version
=-
1
,
# we we change the mode, we don't forward the version.
direction_hint
=
"bprop inputs"
,
verbose
=
self
.
verbose
,
)
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论