Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
P
pytensor
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
testgroup
pytensor
Commits
50ec34d6
提交
50ec34d6
authored
10月 21, 2020
作者:
Brandon T. Willard
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Apply isort to theano.misc sub-package modules
上级
6796db42
隐藏空白字符变更
内嵌
并排
正在显示
15 个修改的文件
包含
36 行增加
和
20 行删除
+36
-20
burn_gpu.py
theano/misc/burn_gpu.py
+0
-1
check_blas.py
theano/misc/check_blas.py
+2
-2
check_duplicate_key.py
theano/misc/check_duplicate_key.py
+2
-1
do_nightly_build_send
theano/misc/do_nightly_build_send
+7
-2
elemwise_openmp_speedup.py
theano/misc/elemwise_openmp_speedup.py
+2
-1
elemwise_time_test.py
theano/misc/elemwise_time_test.py
+1
-2
frozendict.py
theano/misc/frozendict.py
+1
-1
gh_api.py
theano/misc/gh_api.py
+3
-1
check_whitespace.py
theano/misc/hooks/check_whitespace.py
+3
-1
reindent.py
theano/misc/hooks/reindent.py
+1
-1
latence_gpu_transfert.py
theano/misc/latence_gpu_transfert.py
+1
-0
may_share_memory.py
theano/misc/may_share_memory.py
+4
-0
ordered_set.py
theano/misc/ordered_set.py
+0
-1
pkl_utils.py
theano/misc/pkl_utils.py
+8
-6
safe_asarray.py
theano/misc/safe_asarray.py
+1
-0
没有找到文件。
theano/misc/burn_gpu.py
浏览文件 @
50ec34d6
...
@@ -8,7 +8,6 @@ import numpy as np
...
@@ -8,7 +8,6 @@ import numpy as np
import
theano
import
theano
import
theano.tensor
as
tt
import
theano.tensor
as
tt
from
theano.gpuarray
import
dnn
from
theano.gpuarray
import
dnn
from
theano.tensor.nnet.abstract_conv
import
get_conv_output_shape
from
theano.tensor.nnet.abstract_conv
import
get_conv_output_shape
...
...
theano/misc/check_blas.py
浏览文件 @
50ec34d6
...
@@ -10,13 +10,13 @@
...
@@ -10,13 +10,13 @@
import
os
import
os
import
sys
import
sys
import
time
import
time
from
optparse
import
OptionParser
import
numpy
as
np
import
numpy
as
np
import
theano
import
theano
import
theano.tensor
as
tt
import
theano.tensor
as
tt
from
optparse
import
OptionParser
def
execute
(
execute
=
True
,
verbose
=
True
,
M
=
2000
,
N
=
2000
,
K
=
2000
,
iters
=
10
,
order
=
"C"
):
def
execute
(
execute
=
True
,
verbose
=
True
,
M
=
2000
,
N
=
2000
,
K
=
2000
,
iters
=
10
,
order
=
"C"
):
"""
"""
...
...
theano/misc/check_duplicate_key.py
浏览文件 @
50ec34d6
import
six.moves.cPickle
as
pickle
import
os
import
os
import
sys
import
sys
import
six.moves.cPickle
as
pickle
import
theano
import
theano
...
...
theano/misc/do_nightly_build_send
浏览文件 @
50ec34d6
#!/bin/env python
#!/bin/env python
# Import smtplib for the actual sending function
# Import smtplib for the actual sending function
import
smtplib
import
os.path
import
os.path
import
smtplib
import
sys
import
sys
from
theano.misc.buildbot_filter
import
filter_output
from
theano.misc.buildbot_filter
import
filter_output
# me == the sender's email address
# me == the sender's email address
# family = the list of all recipients' email addresses
# family = the list of all recipients' email addresses
family
=
[
'theano-buildbot@googlegroups.com'
]
family
=
[
'theano-buildbot@googlegroups.com'
]
...
@@ -33,9 +36,11 @@ else:
...
@@ -33,9 +36,11 @@ else:
files
=
[
os
.
path
.
join
(
'/tmp'
,
x
)
for
x
in
files
]
files
=
[
os
.
path
.
join
(
'/tmp'
,
x
)
for
x
in
files
]
print
(
'path'
,
files
)
print
(
'path'
,
files
)
from
email.mime.multipart
import
MIMEMultipart
# Here are the email package modules we'll need
# Here are the email package modules we'll need
from
email.mime.text
import
MIMEText
from
email.mime.text
import
MIMEText
from
email.mime.multipart
import
MIMEMultipart
COMMASPACE
=
', '
COMMASPACE
=
', '
...
...
theano/misc/elemwise_openmp_speedup.py
浏览文件 @
50ec34d6
import
os
import
os
import
subprocess
import
subprocess
import
sys
import
sys
from
optparse
import
OptionParser
from
locale
import
getpreferredencoding
from
locale
import
getpreferredencoding
from
optparse
import
OptionParser
import
theano
import
theano
from
theano.compat
import
decode_with
from
theano.compat
import
decode_with
console_encoding
=
getpreferredencoding
()
console_encoding
=
getpreferredencoding
()
parser
=
OptionParser
(
parser
=
OptionParser
(
...
...
theano/misc/elemwise_time_test.py
浏览文件 @
50ec34d6
import
sys
import
sys
import
time
import
time
from
optparse
import
OptionParser
import
numpy
as
np
import
numpy
as
np
import
theano
import
theano
import
theano.tensor
as
tt
import
theano.tensor
as
tt
from
optparse
import
OptionParser
parser
=
OptionParser
(
parser
=
OptionParser
(
usage
=
"
%
prog <options>
\n
Compute time for"
" fast and slow elemwise operations"
usage
=
"
%
prog <options>
\n
Compute time for"
" fast and slow elemwise operations"
...
...
theano/misc/frozendict.py
浏览文件 @
50ec34d6
...
@@ -2,8 +2,8 @@
...
@@ -2,8 +2,8 @@
import
collections
import
collections
import
operator
import
functools
import
functools
import
operator
from
theano.compat
import
Mapping
from
theano.compat
import
Mapping
...
...
theano/misc/gh_api.py
浏览文件 @
50ec34d6
...
@@ -6,10 +6,12 @@ try:
...
@@ -6,10 +6,12 @@ try:
except
NameError
:
except
NameError
:
pass
pass
import
requests
import
getpass
import
getpass
import
json
import
json
import
requests
# Keyring stores passwords by a 'username', but we're not storing a username and
# Keyring stores passwords by a 'username', but we're not storing a username and
# password
# password
fake_username
=
"ipython_tools"
fake_username
=
"ipython_tools"
...
...
theano/misc/hooks/check_whitespace.py
浏览文件 @
50ec34d6
...
@@ -7,10 +7,11 @@ import difflib
...
@@ -7,10 +7,11 @@ import difflib
import
operator
import
operator
import
os
import
os
import
string
import
string
from
subprocess
import
Popen
,
PIPE
import
sys
import
sys
import
tabnanny
import
tabnanny
import
tokenize
import
tokenize
from
subprocess
import
PIPE
,
Popen
try
:
try
:
import
argparse
import
argparse
...
@@ -24,6 +25,7 @@ except ImportError:
...
@@ -24,6 +25,7 @@ except ImportError:
import
reindent
import
reindent
from
six
import
StringIO
from
six
import
StringIO
SKIP_WHITESPACE_CHECK_FILENAME
=
".hg/skip_whitespace_check"
SKIP_WHITESPACE_CHECK_FILENAME
=
".hg/skip_whitespace_check"
...
...
theano/misc/hooks/reindent.py
浏览文件 @
50ec34d6
...
@@ -42,10 +42,10 @@ you'd prefer. You can always use the --nobackup option to prevent this.
...
@@ -42,10 +42,10 @@ you'd prefer. You can always use the --nobackup option to prevent this.
__version__
=
"1"
__version__
=
"1"
import
tokenize
import
os
import
os
import
shutil
import
shutil
import
sys
import
sys
import
tokenize
verbose
=
0
verbose
=
0
...
...
theano/misc/latence_gpu_transfert.py
浏览文件 @
50ec34d6
...
@@ -4,6 +4,7 @@ import numpy as np
...
@@ -4,6 +4,7 @@ import numpy as np
import
theano
import
theano
y
=
theano
.
tensor
.
fvector
()
y
=
theano
.
tensor
.
fvector
()
x
=
theano
.
shared
(
np
.
zeros
(
1
,
dtype
=
"float32"
))
x
=
theano
.
shared
(
np
.
zeros
(
1
,
dtype
=
"float32"
))
f1
=
theano
.
function
([
y
],
updates
=
{
x
:
y
})
f1
=
theano
.
function
([
y
],
updates
=
{
x
:
y
})
...
...
theano/misc/may_share_memory.py
浏览文件 @
50ec34d6
...
@@ -5,10 +5,13 @@ numpy version support only ndarray.
...
@@ -5,10 +5,13 @@ numpy version support only ndarray.
import
numpy
as
np
import
numpy
as
np
from
theano.tensor.basic
import
TensorType
from
theano.tensor.basic
import
TensorType
try
:
try
:
import
scipy.sparse
import
scipy.sparse
from
theano.sparse.basic
import
SparseType
from
theano.sparse.basic
import
SparseType
def
_is_sparse
(
a
):
def
_is_sparse
(
a
):
...
@@ -23,6 +26,7 @@ except ImportError:
...
@@ -23,6 +26,7 @@ except ImportError:
from
theano
import
gpuarray
from
theano
import
gpuarray
if
gpuarray
.
pygpu
:
if
gpuarray
.
pygpu
:
def
_is_gpua
(
a
):
def
_is_gpua
(
a
):
...
...
theano/misc/ordered_set.py
浏览文件 @
50ec34d6
import
types
import
types
import
weakref
import
weakref
from
collections.abc
import
MutableSet
from
collections.abc
import
MutableSet
from
six
import
string_types
from
six
import
string_types
...
...
theano/misc/pkl_utils.py
浏览文件 @
50ec34d6
...
@@ -5,21 +5,22 @@ These pickled graphs can be used, for instance, as cases for
...
@@ -5,21 +5,22 @@ These pickled graphs can be used, for instance, as cases for
unit tests or regression tests.
unit tests or regression tests.
"""
"""
import
numpy
as
np
import
os
import
os
import
pickle
import
pickle
import
sys
import
sys
import
tempfile
import
tempfile
import
zipfile
import
warnings
import
warnings
import
zipfile
import
theano
from
collections
import
defaultdict
from
collections
import
defaultdict
from
contextlib
import
closing
from
contextlib
import
closing
from
pickle
import
HIGHEST_PROTOCOL
from
pickle
import
HIGHEST_PROTOCOL
import
numpy
as
np
from
six
import
BytesIO
from
six
import
BytesIO
import
theano
try
:
try
:
from
pickle
import
DEFAULT_PROTOCOL
from
pickle
import
DEFAULT_PROTOCOL
except
ImportError
:
except
ImportError
:
...
@@ -28,6 +29,7 @@ except ImportError:
...
@@ -28,6 +29,7 @@ except ImportError:
from
theano
import
config
from
theano
import
config
from
theano.compile.sharedvalue
import
SharedVariable
from
theano.compile.sharedvalue
import
SharedVariable
__docformat__
=
"restructuredtext en"
__docformat__
=
"restructuredtext en"
__authors__
=
"Pascal Lamblin"
__authors__
=
"Pascal Lamblin"
__copyright__
=
"Copyright 2013, Universite de Montreal"
__copyright__
=
"Copyright 2013, Universite de Montreal"
...
@@ -212,8 +214,8 @@ class PersistentNdarrayLoad(object):
...
@@ -212,8 +214,8 @@ class PersistentNdarrayLoad(object):
self
.
cache
=
{}
self
.
cache
=
{}
def
__call__
(
self
,
persid
):
def
__call__
(
self
,
persid
):
from
theano.gpuarray.type
import
get_context
from
theano.gpuarray
import
pygpu
from
theano.gpuarray
import
pygpu
from
theano.gpuarray.type
import
get_context
array_type
,
name
=
persid
.
split
(
"."
)
array_type
,
name
=
persid
.
split
(
"."
)
...
...
theano/misc/safe_asarray.py
浏览文件 @
50ec34d6
...
@@ -7,6 +7,7 @@ import numpy as np
...
@@ -7,6 +7,7 @@ import numpy as np
import
theano
import
theano
__docformat__
=
"restructuredtext en"
__docformat__
=
"restructuredtext en"
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论