Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
P
pytensor
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
testgroup
pytensor
Commits
24896131
提交
24896131
authored
5月 06, 2016
作者:
Arnaud Bergeron
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Move the autoselection variables to be per-thunk rather than per-program since…
Move the autoselection variables to be per-thunk rather than per-program since that's what it should have been in the first place.
上级
beefa939
隐藏空白字符变更
内嵌
并排
正在显示
3 个修改的文件
包含
60 行增加
和
20 行删除
+60
-20
dnn_fwd.c
theano/sandbox/gpuarray/dnn_fwd.c
+20
-8
dnn_gi.c
theano/sandbox/gpuarray/dnn_gi.c
+20
-6
dnn_gw.c
theano/sandbox/gpuarray/dnn_gw.c
+20
-6
没有找到文件。
theano/sandbox/gpuarray/dnn_fwd.c
浏览文件 @
24896131
#section init_code_struct
#ifdef CHOOSE_ALGO
reuse_algo
=
0
;
prev_algo
=
CONV_ALGO
;
#ifndef CHOOSE_ONCE
memset
(
prev_img_dims
,
0
,
sizeof
(
prev_img_dims
));
memset
(
prev_kern_dims
,
0
,
sizeof
(
prev_kern_dims
));
#endif
#endif
#section support_code_struct
#ifdef CHOOSE_ALGO
int
reuse_algo
;
cudnnConvolutionFwdAlgo_t
prev_algo
;
#ifndef CHOOSE_ONCE
size_t
prev_img_dims
[
5
];
size_t
prev_kern_dims
[
5
];
#endif
#endif
int
APPLY_SPECIFIC
(
conv_fwd
)(
PyGpuArrayObject
*
input
,
PyGpuArrayObject
*
kerns
,
PyGpuArrayObject
*
om
,
...
...
@@ -57,15 +77,7 @@ APPLY_SPECIFIC(conv_fwd)(PyGpuArrayObject *input, PyGpuArrayObject *kerns,
cuda_enter
(
c
->
ctx
);
#ifdef CHOOSE_ALGO
/* Static variables are only initialized once so this will not
* reset the previous algo every time */
static
int
reuse_algo
=
0
;
static
cudnnConvolutionFwdAlgo_t
prev_algo
=
CONV_ALGO
;
#ifndef CHOOSE_ONCE
static
size_t
prev_img_dims
[
5
]
=
{
0
};
static
size_t
prev_kern_dims
[
5
]
=
{
0
};
reuse_algo
=
1
;
for
(
unsigned
int
i
=
0
;
i
<
PyGpuArray_NDIM
(
input
);
i
++
)
{
reuse_algo
=
(
reuse_algo
&&
...
...
theano/sandbox/gpuarray/dnn_gi.c
浏览文件 @
24896131
#section init_code_struct
#ifdef CHOOSE_ALGO
reuse_algo
=
0
;
prev_algo
=
CONV_ALGO
;
#ifndef CHOOSE_ONCE
memset
(
prev_kern_dims
,
0
,
sizeof
(
prev_kern_dims
));
memset
(
prev_top_dims
,
0
,
sizeof
(
prev_top_dims
));
#endif
#endif
#section support_code_struct
#ifdef CHOOSE_ALGO
int
reuse_algo
=
0
;
cudnnConvolutionBwdDataAlgo_t
prev_algo
=
CONV_ALGO
;
#ifndef CHOOSE_ONCE
size_t
prev_kern_dims
[
5
]
=
{
0
};
size_t
prev_top_dims
[
5
]
=
{
0
};
#endif
#endif
int
APPLY_SPECIFIC
(
conv_gi
)(
PyGpuArrayObject
*
kerns
,
PyGpuArrayObject
*
output
,
PyGpuArrayObject
*
im
,
...
...
@@ -57,13 +77,7 @@ APPLY_SPECIFIC(conv_gi)(PyGpuArrayObject *kerns, PyGpuArrayObject *output,
cuda_enter
(
c
->
ctx
);
#ifdef CHOOSE_ALGO
static
int
reuse_algo
=
0
;
static
cudnnConvolutionBwdDataAlgo_t
prev_algo
=
CONV_ALGO
;
#ifndef CHOOSE_ONCE
static
size_t
prev_kern_dims
[
5
]
=
{
0
};
static
size_t
prev_top_dims
[
5
]
=
{
0
};
reuse_algo
=
1
;
for
(
unsigned
int
i
=
0
;
i
<
PyGpuArray_NDIM
(
kerns
);
i
++
)
{
reuse_algo
=
(
reuse_algo
&&
...
...
theano/sandbox/gpuarray/dnn_gw.c
浏览文件 @
24896131
#section init_code_struct
#ifdef CHOOSE_ALGO
reuse_algo
=
0
;
prev_algo
=
CONV_ALGO
;
#ifndef CHOOSE_ONCE
memset
(
prev_img_dims
,
0
,
sizeof
(
prev_img_dims
));
memset
(
prev_top_dims
,
0
,
sizeof
(
prev_top_dims
));
#endif
#endif
#section support_code_struct
#ifdef CHOOSE_ALGO
int
reuse_algo
;
cudnnConvolutionBwdFilterAlgo_t
prev_algo
;
#ifndef CHOOSE_ONCE
size_t
prev_img_dims
[
5
];
size_t
prev_top_dims
[
5
];
#endif
#endif
int
APPLY_SPECIFIC
(
conv_gw
)(
PyGpuArrayObject
*
input
,
PyGpuArrayObject
*
output
,
PyGpuArrayObject
*
km
,
...
...
@@ -57,13 +77,7 @@ APPLY_SPECIFIC(conv_gw)(PyGpuArrayObject *input, PyGpuArrayObject *output,
cuda_enter
(
c
->
ctx
);
#ifdef CHOOSE_ALGO
static
int
reuse_algo
=
0
;
static
cudnnConvolutionBwdFilterAlgo_t
prev_algo
=
CONV_ALGO
;
#ifndef CHOOSE_ONCE
static
size_t
prev_img_dims
[
5
]
=
{
0
};
static
size_t
prev_top_dims
[
5
]
=
{
0
};
reuse_algo
=
1
;
for
(
unsigned
int
i
=
0
;
i
<
PyGpuArray_NDIM
(
input
);
i
++
)
{
reuse_algo
=
(
reuse_algo
&&
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论