Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
P
pytensor
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
testgroup
pytensor
Commits
6c29dc4f
提交
6c29dc4f
authored
9月 24, 2008
作者:
James Bergstra
浏览文件
操作
浏览文件
下载
差异文件
merged
上级
2480f1d1
74bd2167
隐藏空白字符变更
内嵌
并排
正在显示
2 个修改的文件
包含
39 行增加
和
11 行删除
+39
-11
gen_oplist.py
gen_oplist.py
+9
-7
local.epydoc
local.epydoc
+30
-4
没有找到文件。
gen_oplist.py
浏览文件 @
6c29dc4f
"""script to generate doc/oplist.txt """
__docformat__
=
"restructuredtext en"
import
sys
import
sys
import
gof
import
gof
...
@@ -11,6 +13,7 @@ def isOpConstructor(thing, module):
...
@@ -11,6 +13,7 @@ def isOpConstructor(thing, module):
def
print_title
(
title_string
,
under_char
):
def
print_title
(
title_string
,
under_char
):
print
title_string
print
title_string
print
under_char
*
len
(
title_string
)
print
under_char
*
len
(
title_string
)
print
""
def
chomp
(
s
):
def
chomp
(
s
):
"""interpret and left-align a docstring"""
"""interpret and left-align a docstring"""
...
@@ -42,14 +45,14 @@ def chomp(s):
...
@@ -42,14 +45,14 @@ def chomp(s):
return
""
.
join
(
r
)
return
""
.
join
(
r
)
import
elemwise
,
scalar
,
sparse
,
tensor
import
scalar
,
sparse
,
tensor
print_title
(
"Theano Op List"
,
"~"
)
print_title
(
"Theano Op List"
,
"~"
)
print
""
print
""
print
".. contents:: "
print
".. contents:: "
print
""
print
""
for
module
in
[
elemwise
,
scalar
,
sparse
,
tensor
]:
for
module
in
[
scalar
,
sparse
,
tensor
]:
print_title
(
'module: `
%
s`'
%
module
.
__name__
,
'='
)
print_title
(
'module: `
%
s`'
%
module
.
__name__
,
'='
)
print_title
(
'Op Classes'
,
'-'
)
print_title
(
'Op Classes'
,
'-'
)
...
@@ -58,9 +61,9 @@ for module in [elemwise, scalar, sparse, tensor]:
...
@@ -58,9 +61,9 @@ for module in [elemwise, scalar, sparse, tensor]:
symbol
=
getattr
(
module
,
symbol_name
)
symbol
=
getattr
(
module
,
symbol_name
)
if
isOpClass
(
symbol
)
and
symbol
.
__module__
==
module
.
__name__
:
if
isOpClass
(
symbol
):
print
""
print
""
print
"- :api:`
%
s.
%
s`"
%
(
module
.
__nam
e__
,
symbol_name
)
print
"- :api:`
%
s.
%
s`"
%
(
symbol
.
__modul
e__
,
symbol_name
)
docstring
=
getattr
(
symbol
,
'__doc__'
,
""
)
docstring
=
getattr
(
symbol
,
'__doc__'
,
""
)
if
not
docstring
:
if
not
docstring
:
...
@@ -77,10 +80,9 @@ for module in [elemwise, scalar, sparse, tensor]:
...
@@ -77,10 +80,9 @@ for module in [elemwise, scalar, sparse, tensor]:
symbol
=
getattr
(
module
,
symbol_name
)
symbol
=
getattr
(
module
,
symbol_name
)
if
isOpConstructor
(
symbol
,
module
)
\
if
isOpConstructor
(
symbol
,
module
):
and
symbol
.
__module__
==
module
.
__name__
:
print
""
print
""
print
"- :api:`
%
s.
%
s`"
%
(
module
.
__nam
e__
,
symbol_name
)
print
"- :api:`
%
s.
%
s`"
%
(
symbol
.
__modul
e__
,
symbol_name
)
docstring
=
getattr
(
symbol
,
'__doc__'
,
""
)
docstring
=
getattr
(
symbol
,
'__doc__'
,
""
)
if
not
docstring
:
if
not
docstring
:
...
...
local.epydoc
浏览文件 @
6c29dc4f
...
@@ -7,10 +7,36 @@
...
@@ -7,10 +7,36 @@
# The list of objects to document. Objects can be named using
# The list of objects to document. Objects can be named using
# dotted names, module filenames, or package directory names.
# dotted names, module filenames, or package directory names.
# Alases for this option include "objects" and "values".
# Alases for this option include "objects" and "values".
modules: *.py, gof/__init__.py,
modules: __init__.py,
gof/a*,
a*,
gof/c*,
b*,
gof/d*,
c*,
d*,
e*,
f*,
g*,
h*,
i*,
j*,
k*,
l*,
m*,
n*,
o*,
p*,
q*,
r*,
s*,
t*,
u*
v*
w*
x*
y*
z*
gof/__init__.py,
gof/[a-z]*,
gof/[A-Z]*,
gof/e*,
gof/e*,
gof/g*,
gof/g*,
gof/l*,
gof/l*,
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论