Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
P
pytensor
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
testgroup
pytensor
Commits
00483dbc
提交
00483dbc
authored
6月 18, 2013
作者:
Frederic
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Remove config from c key.
In particular remove nvcc.* stuff. We don't want the c_key of the config to change depending if theano.sandbox.cuda is imported or not.
上级
2f1c91cb
隐藏空白字符变更
内嵌
并排
正在显示
5 个修改的文件
包含
34 行增加
和
16 行删除
+34
-16
profiling.py
theano/compile/profiling.py
+2
-1
compiledir.py
theano/gof/compiledir.py
+6
-3
vm.py
theano/gof/vm.py
+8
-5
__init__.py
theano/sandbox/cuda/__init__.py
+4
-2
nvcc_compiler.py
theano/sandbox/cuda/nvcc_compiler.py
+14
-5
没有找到文件。
theano/compile/profiling.py
浏览文件 @
00483dbc
...
@@ -34,7 +34,8 @@ _atexit_print_file = sys.stderr
...
@@ -34,7 +34,8 @@ _atexit_print_file = sys.stderr
AddConfigVar
(
'profiling.time_thunks'
,
AddConfigVar
(
'profiling.time_thunks'
,
"""Time individual thunks when profiling"""
,
"""Time individual thunks when profiling"""
,
BoolParam
(
True
))
BoolParam
(
True
),
in_c_key
=
False
)
AddConfigVar
(
'profiling.n_apply'
,
AddConfigVar
(
'profiling.n_apply'
,
"Number of Apply instances to print by default"
,
"Number of Apply instances to print by default"
,
...
...
theano/gof/compiledir.py
浏览文件 @
00483dbc
...
@@ -80,7 +80,8 @@ AddConfigVar("compiledir_format",
...
@@ -80,7 +80,8 @@ AddConfigVar("compiledir_format",
module subdirectory (relative to base_compiledir).
module subdirectory (relative to base_compiledir).
Available keys:
%
s. Defaults to
%
r.
Available keys:
%
s. Defaults to
%
r.
"""
%
(
compiledir_format_keys
,
default_compiledir_format
))),
"""
%
(
compiledir_format_keys
,
default_compiledir_format
))),
StrParam
(
default_compiledir_format
,
allow_override
=
False
))
StrParam
(
default_compiledir_format
,
allow_override
=
False
),
in_c_key
=
False
)
def
default_compiledirname
():
def
default_compiledirname
():
...
@@ -160,7 +161,8 @@ AddConfigVar('base_compiledir',
...
@@ -160,7 +161,8 @@ AddConfigVar('base_compiledir',
ConfigParam
(
ConfigParam
(
default_base_compiledir
,
default_base_compiledir
,
filter
=
filter_base_compiledir
,
filter
=
filter_base_compiledir
,
allow_override
=
False
))
allow_override
=
False
),
in_c_key
=
False
)
AddConfigVar
(
'compiledir'
,
AddConfigVar
(
'compiledir'
,
"platform-dependent cache directory for compiled modules"
,
"platform-dependent cache directory for compiled modules"
,
...
@@ -169,7 +171,8 @@ AddConfigVar('compiledir',
...
@@ -169,7 +171,8 @@ AddConfigVar('compiledir',
config
.
base_compiledir
,
config
.
base_compiledir
,
default_compiledirname
()),
default_compiledirname
()),
filter
=
filter_compiledir
,
filter
=
filter_compiledir
,
allow_override
=
False
))
allow_override
=
False
),
in_c_key
=
False
)
def
cleanup
():
def
cleanup
():
...
...
theano/gof/vm.py
浏览文件 @
00483dbc
...
@@ -20,14 +20,16 @@ logger = logging.getLogger(__name__)
...
@@ -20,14 +20,16 @@ logger = logging.getLogger(__name__)
AddConfigVar
(
'profile'
,
AddConfigVar
(
'profile'
,
"If VM should collect profile information"
,
"If VM should collect profile information"
,
BoolParam
(
False
))
BoolParam
(
False
),
in_c_key
=
False
)
AddConfigVar
(
'profile_optimizer'
,
AddConfigVar
(
'profile_optimizer'
,
"If VM should collect optimizer profile information"
,
"If VM should collect optimizer profile information"
,
BoolParam
(
False
))
BoolParam
(
False
),
in_c_key
=
False
)
AddConfigVar
(
'profile_memory'
,
AddConfigVar
(
'profile_memory'
,
"If VM should collect memory profile information and print it"
,
"If VM should collect memory profile information and print it"
,
BoolParam
(
False
)
)
BoolParam
(
False
)
,
in_c_key
=
False
)
def
filter_vm_lazy
(
val
):
def
filter_vm_lazy
(
val
):
if
val
==
'False'
or
val
is
False
:
if
val
==
'False'
or
val
is
False
:
...
@@ -45,7 +47,8 @@ AddConfigVar('vm.lazy',
...
@@ -45,7 +47,8 @@ AddConfigVar('vm.lazy',
" auto detect if lazy evaluation is needed and use the apropriate"
" auto detect if lazy evaluation is needed and use the apropriate"
" version. If lazy is True/False, force the version used between"
" version. If lazy is True/False, force the version used between"
" Loop/LoopGC and Stack."
,
" Loop/LoopGC and Stack."
,
ConfigParam
(
'None'
,
filter_vm_lazy
))
ConfigParam
(
'None'
,
filter_vm_lazy
),
in_c_key
=
False
)
raise_with_op
=
link
.
raise_with_op
raise_with_op
=
link
.
raise_with_op
...
...
theano/sandbox/cuda/__init__.py
浏览文件 @
00483dbc
...
@@ -27,7 +27,8 @@ AddConfigVar('cuda.root',
...
@@ -27,7 +27,8 @@ AddConfigVar('cuda.root',
linker directives. Default: environment variable "CUDA_ROOT"
linker directives. Default: environment variable "CUDA_ROOT"
or else "AUTO".
or else "AUTO".
"""
,
"""
,
StrParam
(
os
.
getenv
(
'CUDA_ROOT'
,
"AUTO"
)))
StrParam
(
os
.
getenv
(
'CUDA_ROOT'
,
"AUTO"
)),
in_c_key
=
False
)
AddConfigVar
(
'pycuda.init'
,
AddConfigVar
(
'pycuda.init'
,
"""If True, always initialize PyCUDA when Theano want to
"""If True, always initialize PyCUDA when Theano want to
...
@@ -37,7 +38,8 @@ AddConfigVar('pycuda.init',
...
@@ -37,7 +38,8 @@ AddConfigVar('pycuda.init',
manually by importing theano.misc.pycuda_init before theano
manually by importing theano.misc.pycuda_init before theano
initialize the GPU device.
initialize the GPU device.
"""
,
"""
,
BoolParam
(
False
))
BoolParam
(
False
),
in_c_key
=
False
)
if
config
.
cuda
.
root
==
"AUTO"
:
if
config
.
cuda
.
root
==
"AUTO"
:
# set nvcc_path correctly and get the version
# set nvcc_path correctly and get the version
...
...
theano/sandbox/cuda/nvcc_compiler.py
浏览文件 @
00483dbc
...
@@ -27,7 +27,8 @@ from theano.configparser import (config, AddConfigVar, StrParam,
...
@@ -27,7 +27,8 @@ from theano.configparser import (config, AddConfigVar, StrParam,
AddConfigVar
(
'nvcc.compiler_bindir'
,
AddConfigVar
(
'nvcc.compiler_bindir'
,
"If defined, nvcc compiler driver will seek g++ and gcc"
"If defined, nvcc compiler driver will seek g++ and gcc"
" in this directory"
,
" in this directory"
,
StrParam
(
""
))
StrParam
(
""
),
in_c_key
=
False
)
AddConfigVar
(
'cuda.nvccflags'
,
AddConfigVar
(
'cuda.nvccflags'
,
"DEPRECATED, use nvcc.flags instead"
,
"DEPRECATED, use nvcc.flags instead"
,
...
@@ -51,13 +52,21 @@ def filter_nvcc_flags(s):
...
@@ -51,13 +52,21 @@ def filter_nvcc_flags(s):
" nvcc.flags value is '
%
s'"
%
s
)
" nvcc.flags value is '
%
s'"
%
s
)
return
' '
.
join
(
flags
)
return
' '
.
join
(
flags
)
AddConfigVar
(
'nvcc.flags'
,
AddConfigVar
(
'nvcc.flags'
,
"Extra compiler flags for nvcc"
,
"Extra compiler flags for nvcc"
,
ConfigParam
(
config
.
cuda
.
nvccflags
,
filter_nvcc_flags
))
ConfigParam
(
config
.
cuda
.
nvccflags
,
filter_nvcc_flags
),
# Not needed in c key as it is already added.
# We remove it as we don't make the md5 of config to change
# if theano.sandbox.cuda is loaded or not.
in_c_key
=
False
)
AddConfigVar
(
'nvcc.fastmath'
,
AddConfigVar
(
'nvcc.fastmath'
,
""
,
""
,
BoolParam
(
False
))
BoolParam
(
False
),
# Not needed in c key as it is already added.
# We remove it as we don't make the md5 of config to change
# if theano.sandbox.cuda is loaded or not.
in_c_key
=
False
)
nvcc_path
=
'nvcc'
nvcc_path
=
'nvcc'
nvcc_version
=
None
nvcc_version
=
None
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论