提交 a7b1f4ff authored 作者: Joseph Turian's avatar Joseph Turian

Debug doc fixes

上级 c24687fd
...@@ -6,17 +6,17 @@ Using DebugMode ...@@ -6,17 +6,17 @@ Using DebugMode
=============== ===============
The DebugMode evaluation mode (available via ``mode='DEBUG_MODE'``, :api:`DebugMode`) includes a number of The DebugMode evaluation mode (available via ``mode='DEBUG_MODE'``,
self-checks and assertions that :api:`DebugMode`) includes a number of self-checks and assertions that
can help to diagnose several kinds of programmer can help to diagnose several kinds of programmer errors that can lead
errors that can lead to incorrect output. to incorrect output.
It is much slower to evaluate a function or method in DEBUG_MODE than it would It is much slower to evaluate a function or method in DEBUG_MODE than
be in FAST_RUN or even FAST_COMPILE, so it is recommended to use it during it would be in FAST_RUN or even FAST_COMPILE. We recommended you use
development, but not when you launch 1000 nearly-identical processes on a DebugMode during development, but not when you launch 1000 processes on
cluster. a cluster.
DebugMode is easy to use: DebugMode is used as follows:
.. code-block:: python .. code-block:: python
...@@ -29,16 +29,17 @@ DebugMode is easy to use: ...@@ -29,16 +29,17 @@ DebugMode is easy to use:
f(7) f(7)
If any problem is detected, at either call time (e.g. ``f(5)``) or compile time If any problem is detected, DebugMode will raise an exception according to
(e.g ``f = theano.function(x, 10*x, mode='DEBUG_MODE')``) then DebugMode will what went wrong, either at call time (e.g. ``f(5)``) or compile time (e.g
raise an exception according to what went wrong. None of these exceptions is ``f = theano.function(x, 10*x, mode='DEBUG_MODE')``). These exceptions
OK to ignore; talk to you your local Theano guru if you can't make the exception should *not* be ignored; talk to your local Theano guru or email the
go away. users list if you cannot make the exception go away.
Some kinds of errors can only be detected for certain input value combinations. Some kinds of errors can only be detected for certain input value combinations.
In the example above, there is no way to guarantee that a future call to say, In the example above, there is no way to guarantee that a future call to say,
``f(-1)`` won't cause a problem. DebugMode is no silver bullet. ``f(-1)`` won't cause a problem. DebugMode is not a silver bullet.
There following are DebugMode exceptions you might encounter:
BadCLinkerOutput BadCLinkerOutput
---------------- ----------------
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论