提交 3098ee05 authored 作者: Arnaud Bergeron's avatar Arnaud Bergeron

Move leftover flags that seemed forgotten.

上级 8d680018
...@@ -17,13 +17,12 @@ from theano.compat import izip ...@@ -17,13 +17,12 @@ from theano.compat import izip
import numpy import numpy
import theano import theano
from theano import gof from theano import gof, config
from theano.compat import get_unbound_function from theano.compat import get_unbound_function
from six import string_types, iteritems, itervalues from six import iteritems, itervalues
from six.moves import StringIO, xrange from six.moves import StringIO, xrange
from theano.gof import (graph, utils, link, ops_with_inner_function) from theano.gof import (graph, utils, link, ops_with_inner_function)
from theano.gof.link import raise_with_op from theano.gof.link import raise_with_op
from theano.configparser import (config, AddConfigVar, IntParam, StrParam)
from theano.compile.function_module import ( from theano.compile.function_module import (
FunctionMaker, Function, infer_reuse_pattern, FunctionMaker, Function, infer_reuse_pattern,
SymbolicInputKit, SymbolicOutput, Supervisor, std_fgraph) SymbolicInputKit, SymbolicOutput, Supervisor, std_fgraph)
...@@ -31,39 +30,6 @@ from theano.compile.mode import Mode, register_mode ...@@ -31,39 +30,6 @@ from theano.compile.mode import Mode, register_mode
from theano.compile.ops import OutputGuard from theano.compile.ops import OutputGuard
__docformat__ = "restructuredtext en" __docformat__ = "restructuredtext en"
def is_valid_check_preallocated_output_param(param):
if not isinstance(param, string_types):
return False
valid = ["initial", "previous", "c_contiguous", "f_contiguous",
"strided", "wrong_size", "ALL", ""]
for p in param.split(":"):
if p not in valid:
return False
return True
AddConfigVar('DebugMode.check_preallocated_output',
('Test thunks with pre-allocated memory as output storage. '
'This is a list of strings separated by ":". Valid values are: '
'"initial" (initial storage in storage map, happens with Scan),'
'"previous" (previously-returned memory), '
'"c_contiguous", "f_contiguous", '
'"strided" (positive and negative strides), '
'"wrong_size" (larger and smaller dimensions), and '
'"ALL" (all of the above).'),
StrParam('', is_valid=is_valid_check_preallocated_output_param),
in_c_key=False)
AddConfigVar('DebugMode.check_preallocated_output_ndim',
('When testing with "strided" preallocated output memory, '
'test all combinations of strides over that number of '
'(inner-most) dimensions. You may want to reduce that number '
'to reduce memory or time usage, but it is advised to keep a '
'minimum of 2.'),
IntParam(4, lambda i: i > 0),
in_c_key=False)
_logger = logging.getLogger("theano.compile.debugmode") _logger = logging.getLogger("theano.compile.debugmode")
......
...@@ -29,7 +29,6 @@ import numpy ...@@ -29,7 +29,6 @@ import numpy
import theano import theano
from six import iteritems from six import iteritems
from theano.gof import graph from theano.gof import graph
from theano.configparser import AddConfigVar, BoolParam, IntParam, StrParam
theano_imported_time = time.time() theano_imported_time = time.time()
config = theano.config config = theano.config
......
差异被折叠。
...@@ -14,8 +14,7 @@ from theano.compile import optdb ...@@ -14,8 +14,7 @@ from theano.compile import optdb
from theano.gof import EquilibriumDB, SequenceDB from theano.gof import EquilibriumDB, SequenceDB
from theano.gof.cmodule import get_lib_extension from theano.gof.cmodule import get_lib_extension
from theano.gof.compilelock import get_lock, release_lock from theano.gof.compilelock import get_lock, release_lock
from theano.configparser import ( from theano import config
config, AddConfigVar, BoolParam, FloatParam, StrParam)
from . import nvcc_compiler from . import nvcc_compiler
from theano.tensor.basic import register_transfer from theano.tensor.basic import register_transfer
......
...@@ -4,7 +4,7 @@ import sys ...@@ -4,7 +4,7 @@ import sys
import warnings import warnings
import theano import theano
from theano.configparser import config, AddConfigVar, BoolParam from theano import config
from theano.compile import optdb from theano.compile import optdb
from theano.tensor.basic import register_transfer from theano.tensor.basic import register_transfer
......
...@@ -87,9 +87,6 @@ from theano.scan_module.scan_utils import safe_new, forced_replace ...@@ -87,9 +87,6 @@ from theano.scan_module.scan_utils import safe_new, forced_replace
_logger = logging.getLogger('theano.scan_module.scan_op') _logger = logging.getLogger('theano.scan_module.scan_op')
from theano.configparser import AddConfigVar, BoolParam
class Scan(PureOp): class Scan(PureOp):
""" """
......
差异被折叠。
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论