Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
P
pytensor
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
testgroup
pytensor
Commits
e473c6c3
提交
e473c6c3
authored
2月 06, 2012
作者:
Olivier Delalleau
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Fixed a few typos
上级
7f862fdc
隐藏空白字符变更
内嵌
并排
正在显示
1 个修改的文件
包含
10 行增加
和
11 行删除
+10
-11
compiledir.py
theano/gof/compiledir.py
+10
-11
没有找到文件。
theano/gof/compiledir.py
浏览文件 @
e473c6c3
...
...
@@ -53,7 +53,7 @@ def filter_compiledir(path):
# the same directory at the same time.
if
e
.
errno
!=
errno
.
EEXIST
:
raise
ValueError
(
"Unable to create t
o create t
he compiledir directory"
"Unable to create the compiledir directory"
" '
%
s'. Check the permissions."
%
path
)
# PROBLEM: sometimes the initial approach based on
...
...
@@ -118,7 +118,7 @@ def print_compiledir_content():
compiledir
=
theano
.
config
.
compiledir
table
=
[]
more_th
e
n_one_ops
=
0
more_th
a
n_one_ops
=
0
zeros_op
=
0
for
dir
in
os
.
listdir
(
compiledir
):
file
=
None
...
...
@@ -131,7 +131,7 @@ def print_compiledir_content():
if
len
(
ops
)
==
0
:
zeros_op
+=
1
elif
len
(
ops
)
>
1
:
more_th
e
n_one_ops
+=
1
more_th
a
n_one_ops
+=
1
else
:
types
=
list
(
set
([
x
for
x
in
flatten
(
keydata
.
keys
)
if
isinstance
(
x
,
theano
.
gof
.
Type
)]))
...
...
@@ -142,7 +142,7 @@ def print_compiledir_content():
if
file
is
not
None
:
file
.
close
()
print
"List
%
d compiled individual op in this theano cache
%
s:"
%
(
print
"List
%
d compiled individual op
s
in this theano cache
%
s:"
%
(
len
(
table
),
compiledir
)
print
"sub directory/Op/a set of the different associated Theano type"
table
=
sorted
(
table
,
key
=
lambda
t
:
str
(
t
[
1
]))
...
...
@@ -153,13 +153,12 @@ def print_compiledir_content():
table_op_class
[
op
.
__class__
]
+=
1
print
print
"List
%
d of individual compiled Op class
and"
%
(
len
(
table_op_class
)
),
print
" the number of time
it
got compiled"
print
"List
%
d of individual compiled Op class
es and"
%
len
(
table_op_class
),
print
" the number of time
s they
got compiled"
table_op_class
=
sorted
(
table_op_class
.
iteritems
(),
key
=
lambda
t
:
t
[
1
])
for
op_class
,
nb
in
table_op_class
:
print
op_class
,
nb
print
(
"Skipped
%
d files that contained more then"
" 1 op (was compiled with the c linker)"
%
(
more_then_one_ops
))
print
(
"Skipped
%
d files that contained 0 op"
"(Are they always theano.scalar ops?)"
%
(
more_then_one_ops
))
print
(
"Skipped
%
d files that contained more than"
" 1 op (was compiled with the C linker)"
%
more_than_one_ops
)
print
(
"Skipped
%
d files that contained 0 op "
"(are they always theano.scalar ops?)"
%
zeros_op
)
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论