blob: f67433fc9fbb042f661394a69c0c4b78845508e1 [file] [log] [blame]
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8"/>
<meta content="IE=edge" http-equiv="X-UA-Compatible"/>
<meta content="width=device-width, initial-scale=1" name="viewport"/>
<title>Environment Variables — mxnet documentation</title>
<link crossorigin="anonymous" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css" integrity="sha384-1q8mTJOASx8j1Au+a5WDVnPi2lkFfwwEAa8hDDdjZlpLegxhjVME1fgjWPGmkzs7" rel="stylesheet"/>
<link href="https://maxcdn.bootstrapcdn.com/font-awesome/4.5.0/css/font-awesome.min.css" rel="stylesheet"/>
<link href="../_static/basic.css" rel="stylesheet" type="text/css">
<link href="../_static/pygments.css" rel="stylesheet" type="text/css">
<link href="../_static/mxnet.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript">
var DOCUMENTATION_OPTIONS = {
URL_ROOT: '../',
VERSION: '',
COLLAPSE_INDEX: false,
FILE_SUFFIX: '.html',
HAS_SOURCE: true,
SOURCELINK_SUFFIX: ''
};
</script>
<script src="../_static/jquery-1.11.1.js" type="text/javascript"></script>
<script src="../_static/underscore.js" type="text/javascript"></script>
<script src="../_static/searchtools_custom.js" type="text/javascript"></script>
<script src="../_static/doctools.js" type="text/javascript"></script>
<script src="../_static/selectlang.js" type="text/javascript"></script>
<script src="https://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML" type="text/javascript"></script>
<script type="text/javascript"> jQuery(function() { Search.loadIndex("/searchindex.js"); Search.init();}); </script>
<script>
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new
Date();a=s.createElement(o),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
})(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
ga('create', 'UA-96378503-1', 'auto');
ga('send', 'pageview');
</script>
<!-- -->
<!-- <script type="text/javascript" src="../_static/jquery.js"></script> -->
<!-- -->
<!-- <script type="text/javascript" src="../_static/underscore.js"></script> -->
<!-- -->
<!-- <script type="text/javascript" src="../_static/doctools.js"></script> -->
<!-- -->
<!-- <script type="text/javascript" src="https://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML"></script> -->
<!-- -->
<link href="https://raw.githubusercontent.com/dmlc/web-data/master/mxnet/image/mxnet-icon.png" rel="icon" type="image/png"/>
</link></link></head>
<body role="document"><!-- Previous Navbar Layout
<div class="navbar navbar-default navbar-fixed-top">
<div class="container">
<div class="navbar-header">
<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar" aria-expanded="false" aria-controls="navbar">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a href="../" class="navbar-brand">
<img src="http://data.mxnet.io/theme/mxnet.png">
</a>
</div>
<div id="navbar" class="navbar-collapse collapse">
<ul id="navbar" class="navbar navbar-left">
<li> <a href="../get_started/index.html">Get Started</a> </li>
<li> <a href="../tutorials/index.html">Tutorials</a> </li>
<li> <a href="../how_to/index.html">How To</a> </li>
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="true">Packages <span class="caret"></span></a>
<ul class="dropdown-menu">
<li><a href="../packages/python/index.html">
Python
</a></li>
<li><a href="../packages/r/index.html">
R
</a></li>
<li><a href="../packages/julia/index.html">
Julia
</a></li>
<li><a href="../packages/c++/index.html">
C++
</a></li>
<li><a href="../packages/scala/index.html">
Scala
</a></li>
<li><a href="../packages/perl/index.html">
Perl
</a></li>
</ul>
</li>
<li> <a href="../system/index.html">System</a> </li>
<li>
<form class="" role="search" action="../search.html" method="get" autocomplete="off">
<div class="form-group inner-addon left-addon">
<i class="glyphicon glyphicon-search"></i>
<input type="text" name="q" class="form-control" placeholder="Search">
</div>
<input type="hidden" name="check_keywords" value="yes" />
<input type="hidden" name="area" value="default" />
</form> </li>
</ul>
<ul id="navbar" class="navbar navbar-right">
<li> <a href="../index.html"><span class="flag-icon flag-icon-us"></span></a> </li>
<li> <a href="..//zh/index.html"><span class="flag-icon flag-icon-cn"></span></a> </li>
</ul>
</div>
</div>
</div>
Previous Navbar Layout End -->
<div class="navbar navbar-fixed-top">
<div class="container" id="navContainer">
<div class="innder" id="header-inner">
<h1 id="logo-wrap">
<a href="../" id="logo"><img src="http://data.mxnet.io/theme/mxnet.png"/></a>
</h1>
<nav class="nav-bar" id="main-nav">
<a class="main-nav-link" href="../get_started/install.html">Install</a>
<a class="main-nav-link" href="../tutorials/index.html">Tutorials</a>
<a class="main-nav-link" href="../how_to/index.html">How To</a>
<span id="dropdown-menu-position-anchor">
<a aria-expanded="true" aria-haspopup="true" class="main-nav-link dropdown-toggle" data-toggle="dropdown" href="#" role="button">API <span class="caret"></span></a>
<ul class="dropdown-menu" id="package-dropdown-menu">
<li><a class="main-nav-link" href="../api/python/index.html">Python</a></li>
<li><a class="main-nav-link" href="../api/scala/index.html">Scala</a></li>
<li><a class="main-nav-link" href="../api/r/index.html">R</a></li>
<li><a class="main-nav-link" href="../api/julia/index.html">Julia</a></li>
<li><a class="main-nav-link" href="../api/c++/index.html">C++</a></li>
<li><a class="main-nav-link" href="../api/perl/index.html">Perl</a></li>
</ul>
</span>
<a class="main-nav-link" href="../architecture/index.html">Architecture</a>
<!-- <a class="main-nav-link" href="../community/index.html">Community</a> -->
<a class="main-nav-link" href="https://github.com/dmlc/mxnet">Github</a>
<span id="dropdown-menu-position-anchor-version" style="position: relative"><a href="#" class="main-nav-link dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="true">Versions(master)<span class="caret"></span></a><ul id="package-dropdown-menu" class="dropdown-menu"><li><a class="main-nav-link" href=http://mxnet.incubator.apache.org/test/>v0.10.14</a></li><li><a class="main-nav-link" href=http://mxnet.incubator.apache.org/test/versions/0.10/index.html>0.10</a></li><li><a class="main-nav-link" href=http://mxnet.incubator.apache.org/test/versions/master/index.html>master</a></li></ul></span></nav>
<script> function getRootPath(){ return "../" } </script>
<div class="burgerIcon dropdown">
<a class="dropdown-toggle" data-toggle="dropdown" href="#" role="button"></a>
<ul class="dropdown-menu dropdown-menu-right" id="burgerMenu">
<li><a href="../get_started/install.html">Install</a></li>
<li><a href="../tutorials/index.html">Tutorials</a></li>
<li><a href="../how_to/index.html">How To</a></li>
<li class="dropdown-submenu">
<a href="#" tabindex="-1">API</a>
<ul class="dropdown-menu">
<li><a href="../api/python/index.html" tabindex="-1">Python</a>
</li>
<li><a href="../api/scala/index.html" tabindex="-1">Scala</a>
</li>
<li><a href="../api/r/index.html" tabindex="-1">R</a>
</li>
<li><a href="../api/julia/index.html" tabindex="-1">Julia</a>
</li>
<li><a href="../api/c++/index.html" tabindex="-1">C++</a>
</li>
<li><a href="../api/perl/index.html" tabindex="-1">Perl</a>
</li>
</ul>
</li>
<li><a href="../architecture/index.html">Architecture</a></li>
<li><a class="main-nav-link" href="https://github.com/dmlc/mxnet">Github</a></li>
<li id="dropdown-menu-position-anchor-version-mobile" class="dropdown-submenu" style="position: relative"><a href="#" tabindex="-1">Versions(master)</a><ul class="dropdown-menu"><li><a tabindex="-1" href=http://mxnet.incubator.apache.org/test/>v0.10.14</a></li><li><a tabindex="-1" href=http://mxnet.incubator.apache.org/test/versions/0.10/index.html>0.10</a></li><li><a tabindex="-1" href=http://mxnet.incubator.apache.org/test/versions/master/index.html>master</a></li></ul></li></ul>
</div>
<div class="plusIcon dropdown">
<a class="dropdown-toggle" data-toggle="dropdown" href="#" role="button"><span aria-hidden="true" class="glyphicon glyphicon-plus"></span></a>
<ul class="dropdown-menu dropdown-menu-right" id="plusMenu"></ul>
</div>
<div id="search-input-wrap">
<form action="../search.html" autocomplete="off" class="" method="get" role="search">
<div class="form-group inner-addon left-addon">
<i class="glyphicon glyphicon-search"></i>
<input class="form-control" name="q" placeholder="Search" type="text"/>
</div>
<input name="check_keywords" type="hidden" value="yes">
<input name="area" type="hidden" value="default"/>
</input></form>
<div id="search-preview"></div>
</div>
<div id="searchIcon">
<span aria-hidden="true" class="glyphicon glyphicon-search"></span>
</div>
<!-- <div id="lang-select-wrap"> -->
<!-- <label id="lang-select-label"> -->
<!-- <\!-- <i class="fa fa-globe"></i> -\-> -->
<!-- <span></span> -->
<!-- </label> -->
<!-- <select id="lang-select"> -->
<!-- <option value="en">Eng</option> -->
<!-- <option value="zh">中文</option> -->
<!-- </select> -->
<!-- </div> -->
<!-- <a id="mobile-nav-toggle">
<span class="mobile-nav-toggle-bar"></span>
<span class="mobile-nav-toggle-bar"></span>
<span class="mobile-nav-toggle-bar"></span>
</a> -->
</div>
</div>
</div>
<div class="container">
<div class="row">
<div aria-label="main navigation" class="sphinxsidebar leftsidebar" role="navigation">
<div class="sphinxsidebarwrapper">
<ul>
<li class="toctree-l1"><a class="reference internal" href="../api/python/index.html">Python Documents</a></li>
<li class="toctree-l1"><a class="reference internal" href="../api/r/index.html">R Documents</a></li>
<li class="toctree-l1"><a class="reference internal" href="../api/julia/index.html">Julia Documents</a></li>
<li class="toctree-l1"><a class="reference internal" href="../api/c++/index.html">C++ Documents</a></li>
<li class="toctree-l1"><a class="reference internal" href="../api/scala/index.html">Scala Documents</a></li>
<li class="toctree-l1"><a class="reference internal" href="../api/perl/index.html">Perl Documents</a></li>
<li class="toctree-l1"><a class="reference internal" href="index.html">HowTo Documents</a></li>
<li class="toctree-l1"><a class="reference internal" href="../architecture/index.html">System Documents</a></li>
<li class="toctree-l1"><a class="reference internal" href="../tutorials/index.html">Tutorials</a></li>
</ul>
</div>
</div>
<div class="content">
<div class="section" id="environment-variables">
<span id="environment-variables"></span><h1>Environment Variables<a class="headerlink" href="#environment-variables" title="Permalink to this headline"></a></h1>
<p>MXNet has several settings that you can change with environment variables.
Typically, you wouldn’t need to change these settings, but they are listed here for reference.</p>
<p>For example, you can set these environment variables in Linux or macOS as follows:</p>
<div class="highlight-python"><div class="highlight"><pre><span></span>export MXNET_GPU_WORKER_NTHREADS=3
</pre></div>
</div>
<div class="section" id="set-the-number-of-threads">
<span id="set-the-number-of-threads"></span><h2>Set the Number of Threads<a class="headerlink" href="#set-the-number-of-threads" title="Permalink to this headline"></a></h2>
<ul class="simple">
<li>MXNET_GPU_WORKER_NTHREADS<ul>
<li>Values: Int <code class="docutils literal"><span class="pre">(default=2)</span></code></li>
<li>The maximum number of threads to use on each GPU. This parameter is used to parallelize the computation within a single GPU card.</li>
</ul>
</li>
<li>MXNET_GPU_COPY_NTHREADS<ul>
<li>Values: Int <code class="docutils literal"><span class="pre">(default=1)</span></code></li>
<li>The maximum number of concurrent threads that do the memory copy job on each GPU.</li>
</ul>
</li>
<li>MXNET_CPU_WORKER_NTHREADS<ul>
<li>Values: Int <code class="docutils literal"><span class="pre">(default=1)</span></code></li>
<li>The maximum number of scheduling threads on CPU. It specifies how many operators can be run in parallel.</li>
</ul>
</li>
<li>MXNET_CPU_PRIORITY_NTHREADS<ul>
<li>Values: Int <code class="docutils literal"><span class="pre">(default=4)</span></code></li>
<li>The number of threads given to prioritized CPU jobs.</li>
</ul>
</li>
<li>MXNET_CPU_NNPACK_NTHREADS<ul>
<li>Values: Int <code class="docutils literal"><span class="pre">(default=4)</span></code></li>
<li>The number of threads used for NNPACK. NNPACK package aims to provide high-performance implementations of some layers for multi-core CPUs. Checkout <a class="reference external" href="http://mxnet.io/how_to/nnpack.html">NNPACK</a> to know more about it.</li>
</ul>
</li>
</ul>
</div>
<div class="section" id="memory-options">
<span id="memory-options"></span><h2>Memory Options<a class="headerlink" href="#memory-options" title="Permalink to this headline"></a></h2>
<ul class="simple">
<li>MXNET_EXEC_ENABLE_INPLACE<ul>
<li>Values: true or false <code class="docutils literal"><span class="pre">(default=true)</span></code></li>
<li>Whether to enable in-place optimization in symbolic execution. Checkout <a class="reference external" href="http://mxnet.io/architecture/note_memory.html#in-place-operations">in-place optimization</a> to know more about it.</li>
</ul>
</li>
<li>NNVM_EXEC_MATCH_RANGE<ul>
<li>Values: Int <code class="docutils literal"><span class="pre">(default=16)</span></code></li>
<li>The approximate matching scale in the symbolic execution memory allocator.</li>
<li>Set this to 0 if you don’t want to enable memory sharing between graph nodes(for debugging purposes).</li>
<li>This variable has impact on the result of memory planning. So, MXNet sweep between [1, NNVM_EXEC_MATCH_RANGE], and selects the best value.</li>
</ul>
</li>
<li>MXNET_EXEC_NUM_TEMP<ul>
<li>Values: Int <code class="docutils literal"><span class="pre">(default=1)</span></code></li>
<li>The maximum number of temporary workspaces to allocate to each device. This controls space replicas and in turn reduces the memory usage.</li>
<li>Setting this to a small number can save GPU memory. It will also likely decrease the level of parallelism, which is usually acceptable.</li>
<li>MXNet internally uses graph coloring algorithm to <a class="reference external" href="http://mxnet.io/architecture/note_memory.html">optimize memory consumption</a>.</li>
<li>This parameter is also used to get number of matching colors in graph and in turn how much parallelism one can get in each GPU. Color based match usually costs more memory but also enables more parallelism.</li>
</ul>
</li>
<li>MXNET_GPU_MEM_POOL_RESERVE<ul>
<li>Values: Int <code class="docutils literal"><span class="pre">(default=5)</span></code></li>
<li>The percentage of GPU memory to reserve for things other than the GPU array, such as kernel launch or cudnn handle space.</li>
<li>If you see a strange out-of-memory error from the kernel launch, after multiple iterations, try setting this to a larger value.</li>
</ul>
</li>
</ul>
</div>
<div class="section" id="engine-type">
<span id="engine-type"></span><h2>Engine Type<a class="headerlink" href="#engine-type" title="Permalink to this headline"></a></h2>
<ul class="simple">
<li>MXNET_ENGINE_TYPE<ul>
<li>Values: String <code class="docutils literal"><span class="pre">(default=ThreadedEnginePerDevice)</span></code></li>
<li>The type of underlying execution engine of MXNet.</li>
<li>Choices:<ul>
<li>NaiveEngine: A very simple engine that uses the master thread to do the computation synchronously. Setting this engine disables multi-threading. You can use this type for debugging in case of any error. Backtrace will give you the series of calls that lead to the error. Remember to set MXNET_ENGINE_TYPE back to empty after debugging.</li>
<li>ThreadedEngine: A threaded engine that uses a global thread pool to schedule jobs.</li>
<li>ThreadedEnginePerDevice: A threaded engine that allocates thread per GPU and executes jobs asynchronously.</li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
<div class="section" id="execution-options">
<span id="execution-options"></span><h2>Execution Options<a class="headerlink" href="#execution-options" title="Permalink to this headline"></a></h2>
<ul class="simple">
<li>MXNET_EXEC_BULK_EXEC_INFERENCE<ul>
<li>Values: 0(false) or 1(true) <code class="docutils literal"><span class="pre">(default=1)</span></code></li>
<li>If set to <code class="docutils literal"><span class="pre">1</span></code>, during inference MXNet executes the entire computation graph in bulk mode, which reduces kernel launch gaps in between symbolic operators.</li>
</ul>
</li>
<li>MXNET_EXEC_BULK_EXEC_TRAIN<ul>
<li>Values: 0(false) or 1(true) <code class="docutils literal"><span class="pre">(default=1)</span></code></li>
<li>If set to <code class="docutils literal"><span class="pre">1</span></code>, during training MXNet executes the computation graph as several subgraphs in bulk mode.</li>
</ul>
</li>
<li>MXNET_EXEC_BULK_EXEC_MAX_NODE_TRAIN<ul>
<li>Values: Int <code class="docutils literal"><span class="pre">(default=15)</span></code></li>
<li>The maximum number of nodes in the subgraph executed in bulk during training(not inference). Setting this to a larger number may reduce the degree of parallelism for multi-GPU training.</li>
</ul>
</li>
</ul>
</div>
<div class="section" id="control-the-data-communication">
<span id="control-the-data-communication"></span><h2>Control the Data Communication<a class="headerlink" href="#control-the-data-communication" title="Permalink to this headline"></a></h2>
<ul class="simple">
<li>MXNET_KVSTORE_REDUCTION_NTHREADS<ul>
<li>Values: Int <code class="docutils literal"><span class="pre">(default=4)</span></code><ul>
<li>The number of CPU threads used for summing big arrays.</li>
</ul>
</li>
</ul>
</li>
<li>MXNET_KVSTORE_BIGARRAY_BOUND<ul>
<li>Values: Int <code class="docutils literal"><span class="pre">(default=1000000)</span></code></li>
<li>The minimum size of a “big array”.</li>
<li>When the array size is bigger than this threshold, MXNET_KVSTORE_REDUCTION_NTHREADS threads are used for reduction.</li>
<li>This parameter is also used as a load balancer in kvstore. It controls when to partition a single weight to all the servers. If the size of a single weight is less than MXNET_KVSTORE_BIGARRAY_BOUND then, it is sent to a single randomly picked server otherwise it is partitioned to all the servers.</li>
</ul>
</li>
<li>MXNET_ENABLE_GPU_P2P<ul>
<li>Values: 0(false) or 1(true) <code class="docutils literal"><span class="pre">(default=1)</span></code></li>
<li>If true, MXNet tries to use GPU peer-to-peer communication, if available on your device,
when kvstore’s type is <code class="docutils literal"><span class="pre">device</span></code>.</li>
</ul>
</li>
</ul>
</div>
<div class="section" id="memonger">
<span id="memonger"></span><h2>Memonger<a class="headerlink" href="#memonger" title="Permalink to this headline"></a></h2>
<ul class="simple">
<li>MXNET_BACKWARD_DO_MIRROR<ul>
<li>Values: 0(false) or 1(true) <code class="docutils literal"><span class="pre">(default=0)</span></code></li>
<li>MXNet uses mirroring concept to save memory. Normally backward pass needs some forward input and it is stored in memory but you can choose to release this saved input and recalculate it in backward pass when needed. This basically trades off the computation for memory consumption.</li>
<li>This parameter decides whether to do <code class="docutils literal"><span class="pre">mirror</span></code> during training for saving device memory.</li>
<li>When set to <code class="docutils literal"><span class="pre">1</span></code>, during forward propagation, graph executor will <code class="docutils literal"><span class="pre">mirror</span></code> some layer’s feature map and drop others, but it will re-compute this dropped feature maps when needed.</li>
<li><code class="docutils literal"><span class="pre">MXNET_BACKWARD_DO_MIRROR=1</span></code> will save 30%~50% of device memory, but retains about 95% of running speed.</li>
<li>One extension of <code class="docutils literal"><span class="pre">mirror</span></code> in MXNet is called <a class="reference external" href="https://arxiv.org/abs/1604.06174">memonger technology</a>, it will only use O(sqrt(N)) memory at 75% running speed. Checkout the code <a class="reference external" href="https://github.com/dmlc/mxnet-memonger">here</a>.</li>
</ul>
</li>
</ul>
</div>
<div class="section" id="control-the-profiler">
<span id="control-the-profiler"></span><h2>Control the profiler<a class="headerlink" href="#control-the-profiler" title="Permalink to this headline"></a></h2>
<p>When USE_PROFILER is enabled in Makefile or CMake, the following environments can be used to profile the application without changing code. Execution options may affect the granularity of profiling result. If you need profiling result of every operator, please set MXNET_EXEC_BULK_EXEC_INFERENCE and MXNET_EXEC_BULK_EXEC_TRAIN to 0.</p>
<ul class="simple">
<li>MXNET_PROFILER_AUTOSTART<ul>
<li>Values: 0(false) or 1(true) <code class="docutils literal"><span class="pre">(default=0)</span></code><ul>
<li>Set to 1, MXNet starts the profiler automatically. The profiling result is stored into profile.json in the working directory.</li>
</ul>
</li>
</ul>
</li>
<li>MXNET_PROFILER_MODE<ul>
<li>Values: 0(false) or 1(true) <code class="docutils literal"><span class="pre">(default=0)</span></code><ul>
<li>If set to ‘0’, profiler records the events of the symbolic operators.</li>
<li>If set to ‘1’, profiler records the events of all operators.</li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
<div class="section" id="other-environment-variables">
<span id="other-environment-variables"></span><h2>Other Environment Variables<a class="headerlink" href="#other-environment-variables" title="Permalink to this headline"></a></h2>
<ul class="simple">
<li>MXNET_CUDNN_AUTOTUNE_DEFAULT<ul>
<li>Values: 0(false) or 1(true) <code class="docutils literal"><span class="pre">(default=0)</span></code></li>
<li>The default value of cudnn auto tunning for convolution layers.</li>
<li>Auto tuning is turned off by default. For benchmarking, set this to 1 to turn it on by default.</li>
</ul>
</li>
</ul>
</div>
<div class="section" id="settings-for-minimum-memory-usage">
<span id="settings-for-minimum-memory-usage"></span><h2>Settings for Minimum Memory Usage<a class="headerlink" href="#settings-for-minimum-memory-usage" title="Permalink to this headline"></a></h2>
<ul class="simple">
<li>Make sure <code class="docutils literal"><span class="pre">min(MXNET_EXEC_NUM_TEMP,</span> <span class="pre">MXNET_GPU_WORKER_NTHREADS)</span> <span class="pre">=</span> <span class="pre">1</span></code><ul>
<li>The default setting satisfies this.</li>
</ul>
</li>
</ul>
</div>
<div class="section" id="settings-for-more-gpu-parallelism">
<span id="settings-for-more-gpu-parallelism"></span><h2>Settings for More GPU Parallelism<a class="headerlink" href="#settings-for-more-gpu-parallelism" title="Permalink to this headline"></a></h2>
<ul class="simple">
<li>Set <code class="docutils literal"><span class="pre">MXNET_GPU_WORKER_NTHREADS</span></code> to a larger number (e.g., 2)<ul>
<li>To reduce memory usage, consider setting <code class="docutils literal"><span class="pre">MXNET_EXEC_NUM_TEMP</span></code>.</li>
<li>This might not speed things up, especially for image applications, because GPU is usually fully utilized even with serialized jobs.</li>
</ul>
</li>
</ul>
</div>
</div>
<div class="container">
<div class="footer">
<p> © 2015-2017 DMLC. All rights reserved. </p>
</div>
</div>
</div>
<div aria-label="main navigation" class="sphinxsidebar rightsidebar" role="navigation">
<div class="sphinxsidebarwrapper">
<h3><a href="../index.html">Table Of Contents</a></h3>
<ul>
<li><a class="reference internal" href="#">Environment Variables</a><ul>
<li><a class="reference internal" href="#set-the-number-of-threads">Set the Number of Threads</a></li>
<li><a class="reference internal" href="#memory-options">Memory Options</a></li>
<li><a class="reference internal" href="#engine-type">Engine Type</a></li>
<li><a class="reference internal" href="#execution-options">Execution Options</a></li>
<li><a class="reference internal" href="#control-the-data-communication">Control the Data Communication</a></li>
<li><a class="reference internal" href="#memonger">Memonger</a></li>
<li><a class="reference internal" href="#control-the-profiler">Control the profiler</a></li>
<li><a class="reference internal" href="#other-environment-variables">Other Environment Variables</a></li>
<li><a class="reference internal" href="#settings-for-minimum-memory-usage">Settings for Minimum Memory Usage</a></li>
<li><a class="reference internal" href="#settings-for-more-gpu-parallelism">Settings for More GPU Parallelism</a></li>
</ul>
</li>
</ul>
</div>
</div>
</div> <!-- pagename != index -->
<script crossorigin="anonymous" integrity="sha384-0mSbJDEHialfmuBBQP6A4Qrprq5OVfW37PRR3j5ELqxss1yVqOtnepnHVP9aJ7xS" src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/js/bootstrap.min.js"></script>
<script src="../_static/js/sidebar.js" type="text/javascript"></script>
<script src="../_static/js/search.js" type="text/javascript"></script>
<script src="../_static/js/navbar.js" type="text/javascript"></script>
<script src="../_static/js/clipboard.min.js" type="text/javascript"></script>
<script src="../_static/js/copycode.js" type="text/javascript"></script>
<script type="text/javascript">
$('body').ready(function () {
$('body').css('visibility', 'visible');
});
</script>
</div></body>
</html>