<p dir="auto">To create a setup where:</p>
<ul dir="auto">
<li>There are multiple worker processes on different servers.</li>
<li>Using multiple threads in each worker process.</li>
</ul>
<p dir="auto">Then one currently needs to jump through some hoops to setup the <code class="notranslate">JULIA_NUM_THREADS</code> environment variable for each worker process. Thus one can't use a simple <code class="notranslate">addprocs</code> with something like <code class="notranslate">SshClusterManater</code>. A possible workaround is writing a shell script which sets the environment variable and launches <code class="notranslate">julia</code> and specify this as the Julia executable.</p>
<p dir="auto">It would be much more convenient and natural if <code class="notranslate">julia</code> provided a command line option for specifying the number of threads. If such a command line option is explicitly specified, it should override the value of <code class="notranslate">JULIA_NUM_THREADS</code>, if any.</p>
<p dir="auto">This setup is useful because the threads within each worker process automatically share "everything" without having to resort to constructs like <code class="notranslate">SharedArray</code>. Of course this also means one needs to be more careful.</p>
<p dir="auto">I like the environment variable <code class="notranslate">JULIA_NUM_THREADS</code>, but it should be overridable with a -t(hreads) choice.  If -p works, -t could reasonably do this, too.</p>