You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
<spanid="ot-gpu"></span><h1>ot.gpu<aclass="headerlink" href="#module-ot.gpu" title="Permalink to this headline"></a></h1>
<p>GPU implementation for several OT solvers and utility
functions.</p>
<p>The GPU backend in handled by <aclass="reference external" href="https://cupy.chainer.org/">cupy</a>.</p>
<divclass="admonition warning">
<pclass="admonition-title">Warning</p>
<p>This module is now deprecated and will be removed in future releases. POT
now privides a backend mechanism that allows for solving prolem on GPU wth
the pytorch backend.</p>
</div>
<divclass="admonition warning">
<pclass="admonition-title">Warning</p>
<p>Note that by default the module is not imported in <aclass="reference internal" href="../all.html#module-ot" title="ot"><codeclass="xref py py-mod docutils literal notranslate"><spanclass="pre">ot</span></code></a>. In order to
use it you need to explicitely import <aclass="reference internal" href="#module-ot.gpu" title="ot.gpu"><codeclass="xref py py-mod docutils literal notranslate"><spanclass="pre">ot.gpu</span></code></a> .</p>
</div>
<p>By default, the functions in this module accept and return numpy arrays
in order to proide drop-in replacement for the other POT function but
the transfer between CPU en GPU comes with a significant overhead.</p>
<p>In order to get the best performances, we recommend to give only cupy
arrays to the functions and desactivate the conversion to numpy of the
result of the function with parameter <codeclass="docutils literal notranslate"><spanclass="pre">to_numpy=False</span></code>.</p>