提交 5d6432cf authored 作者: Olivier Delalleau's avatar Olivier Delalleau

Moved the information about compilation directory from the sandbox to the…

Moved the information about compilation directory from the sandbox to the advanced topic on the compilation pipeline
上级 141fa114
...@@ -97,6 +97,24 @@ output containers will be cleared (if they stay there, as would be the ...@@ -97,6 +97,24 @@ output containers will be cleared (if they stay there, as would be the
case if ``borrow`` was True, the thunk would be allowed to reuse (or case if ``borrow`` was True, the thunk would be allowed to reuse (or
"recycle") the storage). "recycle") the storage).
.. note::
Compiled libraries are stored within a specific compilation directory,
which by default is set to ``$HOME/.theano/compiledir_xxx``, where
``xxx`` identifies the platform. It may be manually set to a different
location either by setting the ``THEANO_COMPILEDIR`` environment variable,
or by calling ``theano.gof.compiledir.set_compiledir(..)`` within your
Python script.
The compile cache is based upon the C++ code of the graph to be compiled.
So, if you change compilation environment variables, such as
``THEANO_BLAS_LDFLAGS``, you will need to manually remove your compile cache,
using ``Theano/bin/theano-compiledir clear``
Theano also implements a lock mechanism that prevents
multiple compilations within the same compilation directory (to avoid
crashes with paralell execution of some scripts). This mechanism is
currently disabled by default, but can be enabled using the function
``theano.gof.compilelock.set_lock_status(..)``.
Step 4 - Wrap the thunk in a pretty package Step 4 - Wrap the thunk in a pretty package
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
......
...@@ -153,18 +153,6 @@ export THEANO_BLAS_LDFLAGS='-lmkl -liomp5 -fopenmp' ...@@ -153,18 +153,6 @@ export THEANO_BLAS_LDFLAGS='-lmkl -liomp5 -fopenmp'
export OMP_NUM_THREADS=2 export OMP_NUM_THREADS=2
=======================================================
Cache
=======================================================
The compile cache is written to ``THEANO_COMPILEDIR``. If this environment
variable is not present, the compile cache defaults to ``$HOME/.theano``.
The compile cache is based upon the C++ code of the graph to be compiled.
So, if you change compilation environment variables, such as
``THEANO_BLAS_LDFLAGS``, you will need to manually remove your compile cache.
``Theano/bin/theano-compiledir clear``
======================================================= =======================================================
Type checking Type checking
======================================================= =======================================================
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论