Modified: incubator/singa/site/trunk/en/docs/net.html URL: http://svn.apache.org/viewvc/incubator/singa/site/trunk/en/docs/net.html?rev=1780083&r1=1780082&r2=1780083&view=diff ============================================================================== --- incubator/singa/site/trunk/en/docs/net.html (original) +++ incubator/singa/site/trunk/en/docs/net.html Tue Jan 24 14:49:41 2017 @@ -9,7 +9,7 @@ <meta name="viewport" content="width=device-width, initial-scale=1.0"> - <title>FeedForward Net — incubator-singa 1.0.1 documentation</title> + <title>FeedForward Net — incubator-singa 1.1.0 documentation</title> @@ -31,7 +31,7 @@ - <link rel="top" title="incubator-singa 1.0.1 documentation" href="../index.html"/> + <link rel="top" title="incubator-singa 1.1.0 documentation" href="../index.html"/> <link rel="up" title="Documentation" href="index.html"/> <link rel="next" title="Initializer" href="initializer.html"/> <link rel="prev" title="Layer" href="layer.html"/> @@ -67,7 +67,7 @@ <div class="version"> - 1.0 + 1.1 </div> @@ -171,6 +171,41 @@ <span id="feedforward-net"></span><h1>FeedForward Net<a class="headerlink" href="#module-singa.net" title="Permalink to this headline">¶</a></h1> <p>Nerual net class for constructing the nets using layers and providing access functions for net info, e.g., parameters.</p> +<p>Example usages:</p> +<div class="highlight-python"><div class="highlight"><pre><span class="kn">from</span> <span class="nn">singa</span> <span class="kn">import</span> <span class="n">net</span> <span class="k">as</span> <span class="n">ffnet</span> +<span class="kn">from</span> <span class="nn">singa</span> <span class="kn">import</span> <span class="n">metric</span> +<span class="kn">from</span> <span class="nn">singa</span> <span class="kn">import</span> <span class="n">loss</span> +<span class="kn">from</span> <span class="nn">singa</span> <span class="kn">import</span> <span class="n">layer</span> +<span class="kn">from</span> <span class="nn">singa</span> <span class="kn">import</span> <span class="n">device</span> + +<span class="c1"># create net and add layers</span> +<span class="n">net</span> <span class="o">=</span> <span class="n">ffnet</span><span class="o">.</span><span class="n">FeedForwardNet</span><span class="p">(</span><span class="n">loss</span><span class="o">.</span><span class="n">SoftmaxCrossEntropy</span><span class="p">(),</span> <span class="n">metric</span><span class="o">.</span><span class="n">Accuracy</span><span class="p">())</span> +<span class="n">net</span><span class="o">.</span><span class="n">add</span><span class="p">(</span><span class="n">layer</span><span class="o">.</span><span class="n">Conv2D</span><span class="p">(</span><span class="s1">'conv1'</span><span class="p">,</span> <span class="mi">32</span><span class="p">,</span> <span class="mi">5</span><span class="p">,</span> <span class="mi">1</span><span class="p">,</span> <span class="n">input_sample_shape</span><span class="o">=</span><span class="p">(</span><span class="mi">3</span><span class="p">,</span><span class="mi">32</span><span class="p">,</span><span class="mi">32</span><span class="p">,)))</span> +<span class="n">net</span><span class="o">.</span><span class="n">add</span><span class="p">(</span><span class="n">layer</span><span class="o">.</span><span class="n">Activation</span><span class="p">(</span><span class="s1">'relu1'</span><span class="p">))</span> +<span class="n">net</span><span class="o">.</span><span class="n">add</span><span class="p">(</span><span class="n">layer</span><span class="o">.</span><span class="n">MaxPooling2D</span><span class="p">(</span><span class="s1">'pool1'</span><span class="p">,</span> <span class="mi">3</span><span class="p">,</span> <span class="mi">2</span><span class="p">))</span> +<span class="n">net</span><span class="o">.</span><span class="n">add</span><span class="p">(</span><span class="n">layer</span><span class="o">.</span><span class="n">Flatten</span><span class="p">(</span><span class="s1">'flat'</span><span class="p">))</span> +<span class="n">net</span><span class="o">.</span><span class="n">add</span><span class="p">(</span><span class="n">layer</span><span class="o">.</span><span class="n">Dense</span><span class="p">(</span><span class="s1">'dense'</span><span class="p">,</span> <span class="mi">10</span><span class="p">))</span> + +<span class="c1"># init parameters</span> +<span class="k">for</span> <span class="n">p</span> <span class="ow">in</span> <span class="n">net</span><span class="o">.</span><span class="n">param_values</span><span class="p">():</span> + <span class="k">if</span> <span class="nb">len</span><span class="p">(</span><span class="n">p</span><span class="o">.</span><span class="n">shape</span><span class="p">)</span> <span class="o">==</span> <span class="mi">0</span><span class="p">:</span> + <span class="n">p</span><span class="o">.</span><span class="n">set_value</span><span class="p">(</span><span class="mi">0</span><span class="p">)</span> + <span class="k">else</span><span class="p">:</span> + <span class="n">p</span><span class="o">.</span><span class="n">gaussian</span><span class="p">(</span><span class="mi">0</span><span class="p">,</span> <span class="mf">0.01</span><span class="p">)</span> + +<span class="c1"># move net onto gpu</span> +<span class="n">dev</span> <span class="o">=</span> <span class="n">device</span><span class="o">.</span><span class="n">create_cuda_gpu</span><span class="p">()</span> +<span class="n">net</span><span class="o">.</span><span class="n">to_device</span><span class="p">(</span><span class="n">dev</span><span class="p">)</span> + +<span class="c1"># training (skipped)</span> + +<span class="c1"># do prediction after training</span> +<span class="n">x</span> <span class="o">=</span> <span class="n">tensor</span><span class="o">.</span><span class="n">Tensor</span><span class="p">((</span><span class="mi">2</span><span class="p">,</span> <span class="mi">3</span><span class="p">,</span> <span class="mi">32</span><span class="p">,</span> <span class="mi">32</span><span class="p">),</span> <span class="n">dev</span><span class="p">)</span> +<span class="n">x</span><span class="o">.</span><span class="n">uniform</span><span class="p">(</span><span class="o">-</span><span class="mi">1</span><span class="p">,</span> <span class="mi">1</span><span class="p">)</span> +<span class="n">y</span> <span class="o">=</span> <span class="n">net</span><span class="o">.</span><span class="n">predict</span><span class="p">(</span><span class="n">x</span><span class="p">)</span> +<span class="k">print</span> <span class="n">tensor</span><span class="o">.</span><span class="n">to_numpy</span><span class="p">(</span><span class="n">y</span><span class="p">)</span> +</pre></div> +</div> <dl class="class"> <dt id="singa.net.FeedForwardNet"> <em class="property">class </em><code class="descclassname">singa.net.</code><code class="descname">FeedForwardNet</code><span class="sig-paren">(</span><em>loss=None</em>, <em>metric=None</em><span class="sig-paren">)</span><a class="headerlink" href="#singa.net.FeedForwardNet" title="Permalink to this definition">¶</a></dt> @@ -178,7 +213,9 @@ functions for net info, e.g., parameters <dl class="method"> <dt id="singa.net.FeedForwardNet.to_device"> <code class="descname">to_device</code><span class="sig-paren">(</span><em>dev</em><span class="sig-paren">)</span><a class="headerlink" href="#singa.net.FeedForwardNet.to_device" title="Permalink to this definition">¶</a></dt> -<dd></dd></dl> +<dd><p>Move the net onto the given device, including +all parameters and intermediate data.</p> +</dd></dl> <dl class="method"> <dt id="singa.net.FeedForwardNet.add"> @@ -193,7 +230,11 @@ the src is a list of the src layers.</p> <col class="field-name" /> <col class="field-body" /> <tbody valign="top"> -<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>lyr</strong> (<a class="reference internal" href="layer.html#singa.layer.Layer" title="singa.layer.Layer"><em>Layer</em></a>) – the layer to be added</td> +<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first last simple"> +<li><strong>lyr</strong> (<a class="reference internal" href="layer.html#singa.layer.Layer" title="singa.layer.Layer"><em>Layer</em></a>) – the layer to be added</li> +<li><strong>src</strong> (<a class="reference internal" href="layer.html#singa.layer.Layer" title="singa.layer.Layer"><em>Layer</em></a>) – the source layer of lyr</li> +</ul> +</td> </tr> </tbody> </table> @@ -202,17 +243,20 @@ the src is a list of the src layers.</p> <dl class="method"> <dt id="singa.net.FeedForwardNet.param_values"> <code class="descname">param_values</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#singa.net.FeedForwardNet.param_values" title="Permalink to this definition">¶</a></dt> -<dd></dd></dl> +<dd><p>Return a list of tensors for all parameters</p> +</dd></dl> <dl class="method"> <dt id="singa.net.FeedForwardNet.param_specs"> <code class="descname">param_specs</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#singa.net.FeedForwardNet.param_specs" title="Permalink to this definition">¶</a></dt> -<dd></dd></dl> +<dd><p>Return a list of ParamSpec for all parameters</p> +</dd></dl> <dl class="method"> <dt id="singa.net.FeedForwardNet.param_names"> <code class="descname">param_names</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#singa.net.FeedForwardNet.param_names" title="Permalink to this definition">¶</a></dt> -<dd></dd></dl> +<dd><p>Return a list for the names of all params</p> +</dd></dl> <dl class="method"> <dt id="singa.net.FeedForwardNet.train"> @@ -334,7 +378,16 @@ else return a dictionary: layer name -&g <dl class="method"> <dt id="singa.net.FeedForwardNet.backward"> <code class="descname">backward</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#singa.net.FeedForwardNet.backward" title="Permalink to this definition">¶</a></dt> -<dd></dd></dl> +<dd><p>Run back-propagation after forward-propagation.</p> +<table class="docutils field-list" frame="void" rules="none"> +<col class="field-name" /> +<col class="field-body" /> +<tbody valign="top"> +<tr class="field-odd field"><th class="field-name">Returns:</th><td class="field-body">a list of gradient tensor for all parameters</td> +</tr> +</tbody> +</table> +</dd></dl> <dl class="method"> <dt id="singa.net.FeedForwardNet.save"> @@ -410,7 +463,7 @@ less space.</li> <script type="text/javascript"> var DOCUMENTATION_OPTIONS = { URL_ROOT:'../', - VERSION:'1.0.1', + VERSION:'1.1.0', COLLAPSE_INDEX:false, FILE_SUFFIX:'.html', HAS_SOURCE: true @@ -443,7 +496,7 @@ less space.</li> <span class="rst-current-version" data-toggle="rst-current-version"> <span class="fa fa-book"> incubator-singa </span> - v: 1.0 + v: 1.1 <span class="fa fa-caret-down"></span> </span> <div class="rst-other-versions">
Modified: incubator/singa/site/trunk/en/docs/neural-net.html URL: http://svn.apache.org/viewvc/incubator/singa/site/trunk/en/docs/neural-net.html?rev=1780083&r1=1780082&r2=1780083&view=diff ============================================================================== --- incubator/singa/site/trunk/en/docs/neural-net.html (original) +++ incubator/singa/site/trunk/en/docs/neural-net.html Tue Jan 24 14:49:41 2017 @@ -9,7 +9,7 @@ <meta name="viewport" content="width=device-width, initial-scale=1.0"> - <title>Neural Net — incubator-singa 1.0.1 documentation</title> + <title>Neural Net — incubator-singa 1.1.0 documentation</title> @@ -31,7 +31,7 @@ - <link rel="top" title="incubator-singa 1.0.1 documentation" href="../index.html"/> + <link rel="top" title="incubator-singa 1.1.0 documentation" href="../index.html"/> <link href="../_static/style.css" rel="stylesheet" type="text/css"> @@ -64,7 +64,7 @@ <div class="version"> - 1.0 + 1.1 </div> @@ -500,7 +500,7 @@ lower layers and <code class="docutils l <script type="text/javascript"> var DOCUMENTATION_OPTIONS = { URL_ROOT:'../', - VERSION:'1.0.1', + VERSION:'1.1.0', COLLAPSE_INDEX:false, FILE_SUFFIX:'.html', HAS_SOURCE: true @@ -533,7 +533,7 @@ lower layers and <code class="docutils l <span class="rst-current-version" data-toggle="rst-current-version"> <span class="fa fa-book"> incubator-singa </span> - v: 1.0 + v: 1.1 <span class="fa fa-caret-down"></span> </span> <div class="rst-other-versions"> Modified: incubator/singa/site/trunk/en/docs/notebook/README.html URL: http://svn.apache.org/viewvc/incubator/singa/site/trunk/en/docs/notebook/README.html?rev=1780083&r1=1780082&r2=1780083&view=diff ============================================================================== --- incubator/singa/site/trunk/en/docs/notebook/README.html (original) +++ incubator/singa/site/trunk/en/docs/notebook/README.html Tue Jan 24 14:49:41 2017 @@ -9,7 +9,7 @@ <meta name="viewport" content="width=device-width, initial-scale=1.0"> - <title><no title> — incubator-singa 1.0.1 documentation</title> + <title><no title> — incubator-singa 1.1.0 documentation</title> @@ -31,7 +31,7 @@ - <link rel="top" title="incubator-singa 1.0.1 documentation" href="../../index.html"/> + <link rel="top" title="incubator-singa 1.1.0 documentation" href="../../index.html"/> <link href="../../_static/style.css" rel="stylesheet" type="text/css"> @@ -64,7 +64,7 @@ <div class="version"> - 1.0 + 1.1 </div> @@ -179,7 +179,7 @@ <script type="text/javascript"> var DOCUMENTATION_OPTIONS = { URL_ROOT:'../../', - VERSION:'1.0.1', + VERSION:'1.1.0', COLLAPSE_INDEX:false, FILE_SUFFIX:'.html', HAS_SOURCE: true @@ -212,7 +212,7 @@ <span class="rst-current-version" data-toggle="rst-current-version"> <span class="fa fa-book"> incubator-singa </span> - v: 1.0 + v: 1.1 <span class="fa fa-caret-down"></span> </span> <div class="rst-other-versions"> Modified: incubator/singa/site/trunk/en/docs/optimizer.html URL: http://svn.apache.org/viewvc/incubator/singa/site/trunk/en/docs/optimizer.html?rev=1780083&r1=1780082&r2=1780083&view=diff ============================================================================== --- incubator/singa/site/trunk/en/docs/optimizer.html (original) +++ incubator/singa/site/trunk/en/docs/optimizer.html Tue Jan 24 14:49:41 2017 @@ -9,7 +9,7 @@ <meta name="viewport" content="width=device-width, initial-scale=1.0"> - <title>Optimizer — incubator-singa 1.0.1 documentation</title> + <title>Optimizer — incubator-singa 1.1.0 documentation</title> @@ -31,7 +31,7 @@ - <link rel="top" title="incubator-singa 1.0.1 documentation" href="../index.html"/> + <link rel="top" title="incubator-singa 1.1.0 documentation" href="../index.html"/> <link rel="up" title="Documentation" href="index.html"/> <link rel="next" title="Data" href="data.html"/> <link rel="prev" title="Metric" href="metric.html"/> @@ -67,7 +67,7 @@ <div class="version"> - 1.0 + 1.1 </div> @@ -570,7 +570,7 @@ updating rules (including regularizer an <script type="text/javascript"> var DOCUMENTATION_OPTIONS = { URL_ROOT:'../', - VERSION:'1.0.1', + VERSION:'1.1.0', COLLAPSE_INDEX:false, FILE_SUFFIX:'.html', HAS_SOURCE: true @@ -603,7 +603,7 @@ updating rules (including regularizer an <span class="rst-current-version" data-toggle="rst-current-version"> <span class="fa fa-book"> incubator-singa </span> - v: 1.0 + v: 1.1 <span class="fa fa-caret-down"></span> </span> <div class="rst-other-versions"> Modified: incubator/singa/site/trunk/en/docs/snapshot.html URL: http://svn.apache.org/viewvc/incubator/singa/site/trunk/en/docs/snapshot.html?rev=1780083&r1=1780082&r2=1780083&view=diff ============================================================================== --- incubator/singa/site/trunk/en/docs/snapshot.html (original) +++ incubator/singa/site/trunk/en/docs/snapshot.html Tue Jan 24 14:49:41 2017 @@ -9,7 +9,7 @@ <meta name="viewport" content="width=device-width, initial-scale=1.0"> - <title>Snapshot — incubator-singa 1.0.1 documentation</title> + <title>Snapshot — incubator-singa 1.1.0 documentation</title> @@ -31,7 +31,7 @@ - <link rel="top" title="incubator-singa 1.0.1 documentation" href="../index.html"/> + <link rel="top" title="incubator-singa 1.1.0 documentation" href="../index.html"/> <link rel="up" title="Documentation" href="index.html"/> <link rel="next" title="Caffe Converter" href="converter.html"/> <link rel="prev" title="Image Tool" href="image_tool.html"/> @@ -67,7 +67,7 @@ <div class="version"> - 1.0 + 1.1 </div> @@ -170,6 +170,17 @@ <div class="section" id="module-singa.snapshot"> <span id="snapshot"></span><h1>Snapshot<a class="headerlink" href="#module-singa.snapshot" title="Permalink to this headline">¶</a></h1> <p>This script includes io::snapshot class and its methods.</p> +<p>Example usages:</p> +<div class="highlight-python"><div class="highlight"><pre><span class="kn">from</span> <span class="nn">singa</span> <span class="kn">import</span> <span class="n">snapshot</span> + +<span class="n">sn1</span> <span class="o">=</span> <span class="n">snapshot</span><span class="o">.</span><span class="n">Snapshot</span><span class="p">(</span><span class="s1">'param'</span><span class="p">,</span> <span class="bp">False</span><span class="p">)</span> +<span class="n">params</span> <span class="o">=</span> <span class="n">sn1</span><span class="o">.</span><span class="n">read</span><span class="p">()</span> <span class="c1"># read all params as a dictionary</span> + +<span class="n">sn2</span> <span class="o">=</span> <span class="n">snapshot</span><span class="o">.</span><span class="n">Snapshot</span><span class="p">(</span><span class="s1">'param_new'</span><span class="p">,</span> <span class="bp">False</span><span class="p">)</span> +<span class="k">for</span> <span class="n">k</span><span class="p">,</span> <span class="n">v</span> <span class="ow">in</span> <span class="n">params</span><span class="o">.</span><span class="n">iteritems</span><span class="p">():</span> + <span class="n">sn2</span><span class="o">.</span><span class="n">write</span><span class="p">(</span><span class="n">k</span><span class="p">,</span> <span class="n">v</span><span class="p">)</span> +</pre></div> +</div> <dl class="class"> <dt id="singa.snapshot.Snapshot"> <em class="property">class </em><code class="descclassname">singa.snapshot.</code><code class="descname">Snapshot</code><span class="sig-paren">(</span><em>f</em>, <em>mode</em>, <em>buffer_size=10</em><span class="sig-paren">)</span><a class="headerlink" href="#singa.snapshot.Snapshot" title="Permalink to this definition">¶</a></dt> @@ -251,7 +262,7 @@ <script type="text/javascript"> var DOCUMENTATION_OPTIONS = { URL_ROOT:'../', - VERSION:'1.0.1', + VERSION:'1.1.0', COLLAPSE_INDEX:false, FILE_SUFFIX:'.html', HAS_SOURCE: true @@ -284,7 +295,7 @@ <span class="rst-current-version" data-toggle="rst-current-version"> <span class="fa fa-book"> incubator-singa </span> - v: 1.0 + v: 1.1 <span class="fa fa-caret-down"></span> </span> <div class="rst-other-versions"> Modified: incubator/singa/site/trunk/en/docs/software_stack.html URL: http://svn.apache.org/viewvc/incubator/singa/site/trunk/en/docs/software_stack.html?rev=1780083&r1=1780082&r2=1780083&view=diff ============================================================================== --- incubator/singa/site/trunk/en/docs/software_stack.html (original) +++ incubator/singa/site/trunk/en/docs/software_stack.html Tue Jan 24 14:49:41 2017 @@ -9,7 +9,7 @@ <meta name="viewport" content="width=device-width, initial-scale=1.0"> - <title>Software Stack — incubator-singa 1.0.1 documentation</title> + <title>Software Stack — incubator-singa 1.1.0 documentation</title> @@ -31,7 +31,7 @@ - <link rel="top" title="incubator-singa 1.0.1 documentation" href="../index.html"/> + <link rel="top" title="incubator-singa 1.1.0 documentation" href="../index.html"/> <link rel="up" title="Documentation" href="index.html"/> <link rel="next" title="Device" href="device.html"/> <link rel="prev" title="Installation" href="installation.html"/> @@ -67,7 +67,7 @@ <div class="version"> - 1.0 + 1.1 </div> @@ -303,7 +303,7 @@ model parameter values using parameter g <script type="text/javascript"> var DOCUMENTATION_OPTIONS = { URL_ROOT:'../', - VERSION:'1.0.1', + VERSION:'1.1.0', COLLAPSE_INDEX:false, FILE_SUFFIX:'.html', HAS_SOURCE: true @@ -336,7 +336,7 @@ model parameter values using parameter g <span class="rst-current-version" data-toggle="rst-current-version"> <span class="fa fa-book"> incubator-singa </span> - v: 1.0 + v: 1.1 <span class="fa fa-caret-down"></span> </span> <div class="rst-other-versions"> Modified: incubator/singa/site/trunk/en/docs/tensor.html URL: http://svn.apache.org/viewvc/incubator/singa/site/trunk/en/docs/tensor.html?rev=1780083&r1=1780082&r2=1780083&view=diff ============================================================================== --- incubator/singa/site/trunk/en/docs/tensor.html (original) +++ incubator/singa/site/trunk/en/docs/tensor.html Tue Jan 24 14:49:41 2017 @@ -9,7 +9,7 @@ <meta name="viewport" content="width=device-width, initial-scale=1.0"> - <title>Tensor — incubator-singa 1.0.1 documentation</title> + <title>Tensor — incubator-singa 1.1.0 documentation</title> @@ -31,7 +31,7 @@ - <link rel="top" title="incubator-singa 1.0.1 documentation" href="../index.html"/> + <link rel="top" title="incubator-singa 1.1.0 documentation" href="../index.html"/> <link rel="up" title="Documentation" href="index.html"/> <link rel="next" title="Layer" href="layer.html"/> <link rel="prev" title="Device" href="device.html"/> @@ -67,7 +67,7 @@ <div class="version"> - 1.0 + 1.1 </div> @@ -191,27 +191,33 @@ type of Device.</p> </div> <div class="section" id="module-singa.tensor"> <span id="python-api"></span><h2>Python API<a class="headerlink" href="#module-singa.tensor" title="Permalink to this headline">¶</a></h2> -<dl class="docutils"> -<dt>Example usage::</dt> -<dd>import numpy as np -from singa import tensor -from singa import device</dd> -<dt># create a tensor with shape (2,3), default CppCPU device and float32</dt> -<dd>x = tensor.Tensor((2, 3)) -x.set_value(0.4)</dd> -<dt># create a tensor from a numpy array</dt> -<dd><p class="first">npy = np.zeros((3, 3), dtype=np.float32) -y = tensor.from_numpy(npy)</p> -<p>y.uniform(-1, 1) # sample values from the uniform distribution</p> -<p>z = tensor.mult(x, y) # gemm -> z of shape (2, 3)</p> -<p>x += z # element-wise addition</p> -<p>dev = device.get_default_device() -x.to_device(dev) # move the data to a gpu device</p> -<p>r = tensor.relu(x)</p> -<p class="last">r.to_host() # move the data back to host cpu -s = tensor.to_numpy(r) # tensor -> numpy array, r must be on cpu</p> -</dd> -</dl> +<p>Example usage:</p> +<div class="highlight-python"><div class="highlight"><pre><span class="kn">import</span> <span class="nn">numpy</span> <span class="kn">as</span> <span class="nn">np</span> +<span class="kn">from</span> <span class="nn">singa</span> <span class="kn">import</span> <span class="n">tensor</span> +<span class="kn">from</span> <span class="nn">singa</span> <span class="kn">import</span> <span class="n">device</span> + +<span class="c1"># create a tensor with shape (2,3), default CppCPU device and float32</span> +<span class="n">x</span> <span class="o">=</span> <span class="n">tensor</span><span class="o">.</span><span class="n">Tensor</span><span class="p">((</span><span class="mi">2</span><span class="p">,</span> <span class="mi">3</span><span class="p">))</span> +<span class="n">x</span><span class="o">.</span><span class="n">set_value</span><span class="p">(</span><span class="mf">0.4</span><span class="p">)</span> + +<span class="c1"># create a tensor from a numpy array</span> +<span class="n">npy</span> <span class="o">=</span> <span class="n">np</span><span class="o">.</span><span class="n">zeros</span><span class="p">((</span><span class="mi">3</span><span class="p">,</span> <span class="mi">3</span><span class="p">),</span> <span class="n">dtype</span><span class="o">=</span><span class="n">np</span><span class="o">.</span><span class="n">float32</span><span class="p">)</span> +<span class="n">y</span> <span class="o">=</span> <span class="n">tensor</span><span class="o">.</span><span class="n">from_numpy</span><span class="p">(</span><span class="n">npy</span><span class="p">)</span> + +<span class="n">y</span><span class="o">.</span><span class="n">uniform</span><span class="p">(</span><span class="o">-</span><span class="mi">1</span><span class="p">,</span> <span class="mi">1</span><span class="p">)</span> <span class="c1"># sample values from the uniform distribution</span> + +<span class="n">z</span> <span class="o">=</span> <span class="n">tensor</span><span class="o">.</span><span class="n">mult</span><span class="p">(</span><span class="n">x</span><span class="p">,</span> <span class="n">y</span><span class="p">)</span> <span class="c1"># gemm -> z of shape (2, 3)</span> + +<span class="n">x</span> <span class="o">+=</span> <span class="n">z</span> <span class="c1"># element-wise addition</span> + +<span class="n">dev</span> <span class="o">=</span> <span class="n">device</span><span class="o">.</span><span class="n">get_default_device</span><span class="p">()</span> +<span class="n">x</span><span class="o">.</span><span class="n">to_device</span><span class="p">(</span><span class="n">dev</span><span class="p">)</span> <span class="c1"># move the data to a gpu device</span> + +<span class="n">r</span> <span class="o">=</span> <span class="n">tensor</span><span class="o">.</span><span class="n">relu</span><span class="p">(</span><span class="n">x</span><span class="p">)</span> + +<span class="n">s</span> <span class="o">=</span> <span class="n">tensor</span><span class="o">.</span><span class="n">to_numpy</span><span class="p">(</span><span class="n">r</span><span class="p">)</span> <span class="c1"># tensor -> numpy array</span> +</pre></div> +</div> <p>There are two sets of tensor functions,</p> <dl class="docutils"> <dt>Tensor member functions</dt> @@ -1158,6 +1164,21 @@ old shape.</li> </dd></dl> <dl class="function"> +<dt id="singa.tensor.sign"> +<code class="descclassname">singa.tensor.</code><code class="descname">sign</code><span class="sig-paren">(</span><em>t</em><span class="sig-paren">)</span><a class="headerlink" href="#singa.tensor.sign" title="Permalink to this definition">¶</a></dt> +<dd><table class="docutils field-list" frame="void" rules="none"> +<col class="field-name" /> +<col class="field-body" /> +<tbody valign="top"> +<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>t</strong> (<a class="reference internal" href="#singa.tensor.Tensor" title="singa.tensor.Tensor"><em>Tensor</em></a>) – input Tensor</td> +</tr> +<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">a new Tensor whose element y = sign(x)</td> +</tr> +</tbody> +</table> +</dd></dl> + +<dl class="function"> <dt id="singa.tensor.sizeof"> <code class="descclassname">singa.tensor.</code><code class="descname">sizeof</code><span class="sig-paren">(</span><em>dtype</em><span class="sig-paren">)</span><a class="headerlink" href="#singa.tensor.sizeof" title="Permalink to this definition">¶</a></dt> <dd><table class="docutils field-list" frame="void" rules="none"> @@ -1315,11 +1336,15 @@ e.g. 0 – sum each column; 1 – </dd></dl> <dl class="function"> +<dt id="singa.tensor.to_host"> +<code class="descclassname">singa.tensor.</code><code class="descname">to_host</code><span class="sig-paren">(</span><em>t</em><span class="sig-paren">)</span><a class="headerlink" href="#singa.tensor.to_host" title="Permalink to this definition">¶</a></dt> +<dd><p>Copy the data to a host tensor.</p> +</dd></dl> + +<dl class="function"> <dt id="singa.tensor.to_numpy"> <code class="descclassname">singa.tensor.</code><code class="descname">to_numpy</code><span class="sig-paren">(</span><em>t</em><span class="sig-paren">)</span><a class="headerlink" href="#singa.tensor.to_numpy" title="Permalink to this definition">¶</a></dt> -<dd><p>Convert the tensor into a numpy array.</p> -<p>Since numpy array is allocated on CPU devices, the input Tensor instance -must be on the default CppCPU device.</p> +<dd><p>Copy the tensor into a numpy array.</p> <table class="docutils field-list" frame="void" rules="none"> <col class="field-name" /> <col class="field-body" /> @@ -1401,7 +1426,7 @@ must be on the default CppCPU device.</p <script type="text/javascript"> var DOCUMENTATION_OPTIONS = { URL_ROOT:'../', - VERSION:'1.0.1', + VERSION:'1.1.0', COLLAPSE_INDEX:false, FILE_SUFFIX:'.html', HAS_SOURCE: true @@ -1434,7 +1459,7 @@ must be on the default CppCPU device.</p <span class="rst-current-version" data-toggle="rst-current-version"> <span class="fa fa-book"> incubator-singa </span> - v: 1.0 + v: 1.1 <span class="fa fa-caret-down"></span> </span> <div class="rst-other-versions"> Modified: incubator/singa/site/trunk/en/docs/utils.html URL: http://svn.apache.org/viewvc/incubator/singa/site/trunk/en/docs/utils.html?rev=1780083&r1=1780082&r2=1780083&view=diff ============================================================================== --- incubator/singa/site/trunk/en/docs/utils.html (original) +++ incubator/singa/site/trunk/en/docs/utils.html Tue Jan 24 14:49:41 2017 @@ -9,7 +9,7 @@ <meta name="viewport" content="width=device-width, initial-scale=1.0"> - <title>Utils — incubator-singa 1.0.1 documentation</title> + <title>Utils — incubator-singa 1.1.0 documentation</title> @@ -31,7 +31,7 @@ - <link rel="top" title="incubator-singa 1.0.1 documentation" href="../index.html"/> + <link rel="top" title="incubator-singa 1.1.0 documentation" href="../index.html"/> <link rel="up" title="Documentation" href="index.html"/> <link rel="next" title="Model Zoo" href="model_zoo/index.html"/> <link rel="prev" title="Caffe Converter" href="converter.html"/> @@ -67,7 +67,7 @@ <div class="version"> - 1.0 + 1.1 </div> @@ -230,7 +230,7 @@ <script type="text/javascript"> var DOCUMENTATION_OPTIONS = { URL_ROOT:'../', - VERSION:'1.0.1', + VERSION:'1.1.0', COLLAPSE_INDEX:false, FILE_SUFFIX:'.html', HAS_SOURCE: true @@ -263,7 +263,7 @@ <span class="rst-current-version" data-toggle="rst-current-version"> <span class="fa fa-book"> incubator-singa </span> - v: 1.0 + v: 1.1 <span class="fa fa-caret-down"></span> </span> <div class="rst-other-versions"> Modified: incubator/singa/site/trunk/en/downloads.html URL: http://svn.apache.org/viewvc/incubator/singa/site/trunk/en/downloads.html?rev=1780083&r1=1780082&r2=1780083&view=diff ============================================================================== --- incubator/singa/site/trunk/en/downloads.html (original) +++ incubator/singa/site/trunk/en/downloads.html Tue Jan 24 14:49:41 2017 @@ -9,7 +9,7 @@ <meta name="viewport" content="width=device-width, initial-scale=1.0"> - <title>Download SINGA — incubator-singa 1.0.1 documentation</title> + <title>Download SINGA — incubator-singa 1.1.0 documentation</title> @@ -31,7 +31,7 @@ - <link rel="top" title="incubator-singa 1.0.1 documentation" href="index.html"/> + <link rel="top" title="incubator-singa 1.1.0 documentation" href="index.html"/> <link rel="next" title="Documentation" href="docs/index.html"/> <link rel="prev" title="Welcome to Apache Singa" href="index.html"/> <link href="_static/style.css" rel="stylesheet" type="text/css"> @@ -66,7 +66,7 @@ <div class="version"> - 1.0 + 1.1 </div> @@ -288,7 +288,7 @@ ASF.</p> <script type="text/javascript"> var DOCUMENTATION_OPTIONS = { URL_ROOT:'./', - VERSION:'1.0.1', + VERSION:'1.1.0', COLLAPSE_INDEX:false, FILE_SUFFIX:'.html', HAS_SOURCE: true @@ -321,7 +321,7 @@ ASF.</p> <span class="rst-current-version" data-toggle="rst-current-version"> <span class="fa fa-book"> incubator-singa </span> - v: 1.0 + v: 1.1 <span class="fa fa-caret-down"></span> </span> <div class="rst-other-versions"> Modified: incubator/singa/site/trunk/en/genindex.html URL: http://svn.apache.org/viewvc/incubator/singa/site/trunk/en/genindex.html?rev=1780083&r1=1780082&r2=1780083&view=diff ============================================================================== --- incubator/singa/site/trunk/en/genindex.html (original) +++ incubator/singa/site/trunk/en/genindex.html Tue Jan 24 14:49:41 2017 @@ -10,7 +10,7 @@ <meta name="viewport" content="width=device-width, initial-scale=1.0"> - <title>Index — incubator-singa 1.0.1 documentation</title> + <title>Index — incubator-singa 1.1.0 documentation</title> @@ -32,7 +32,7 @@ - <link rel="top" title="incubator-singa 1.0.1 documentation" href="index.html"/> + <link rel="top" title="incubator-singa 1.1.0 documentation" href="index.html"/> <link href="_static/style.css" rel="stylesheet" type="text/css"> @@ -65,7 +65,7 @@ <div class="version"> - 1.0 + 1.1 </div> @@ -133,7 +133,7 @@ <ul class="wy-breadcrumbs"> <li><a href="index.html">Docs</a> »</li> - <li></li> + <li>Index</li> <li class="wy-breadcrumbs-aside"> @@ -1026,6 +1026,10 @@ </dt> + <dt><a href="docs/tensor.html#singa.tensor.sign">sign() (in module singa.tensor)</a> + </dt> + + <dt><a href="docs/converter.html#module-singa.converter">singa.converter (module)</a> </dt> @@ -1069,12 +1073,12 @@ <dt><a href="docs/snapshot.html#module-singa.snapshot">singa.snapshot (module)</a> </dt> + </dl></td> + <td style="width: 33%" valign="top"><dl> <dt><a href="docs/tensor.html#module-singa.tensor">singa.tensor (module)</a> </dt> - </dl></td> - <td style="width: 33%" valign="top"><dl> <dt><a href="docs/utils.html#module-singa.utils">singa.utils (module)</a> </dt> @@ -1174,9 +1178,15 @@ </dl></td> <td style="width: 33%" valign="top"><dl> - <dt><a href="docs/tensor.html#singa.tensor.Tensor.to_host">to_host() (singa.tensor.Tensor method)</a> + <dt><a href="docs/tensor.html#singa.tensor.to_host">to_host() (in module singa.tensor)</a> + </dt> + + <dd><dl> + + <dt><a href="docs/tensor.html#singa.tensor.Tensor.to_host">(singa.tensor.Tensor method)</a> </dt> + </dl></dd> <dt><a href="docs/tensor.html#singa.tensor.to_numpy">to_numpy() (in module singa.tensor)</a> </dt> @@ -1261,7 +1271,7 @@ <script type="text/javascript"> var DOCUMENTATION_OPTIONS = { URL_ROOT:'./', - VERSION:'1.0.1', + VERSION:'1.1.0', COLLAPSE_INDEX:false, FILE_SUFFIX:'.html', HAS_SOURCE: true @@ -1294,7 +1304,7 @@ <span class="rst-current-version" data-toggle="rst-current-version"> <span class="fa fa-book"> incubator-singa </span> - v: 1.0 + v: 1.1 <span class="fa fa-caret-down"></span> </span> <div class="rst-other-versions"> Modified: incubator/singa/site/trunk/en/index.html URL: http://svn.apache.org/viewvc/incubator/singa/site/trunk/en/index.html?rev=1780083&r1=1780082&r2=1780083&view=diff ============================================================================== --- incubator/singa/site/trunk/en/index.html (original) +++ incubator/singa/site/trunk/en/index.html Tue Jan 24 14:49:41 2017 @@ -9,7 +9,7 @@ <meta name="viewport" content="width=device-width, initial-scale=1.0"> - <title>Welcome to Apache Singa — incubator-singa 1.0.1 documentation</title> + <title>Welcome to Apache Singa — incubator-singa 1.1.0 documentation</title> @@ -31,7 +31,7 @@ - <link rel="top" title="incubator-singa 1.0.1 documentation" href="#"/> + <link rel="top" title="incubator-singa 1.1.0 documentation" href="#"/> <link rel="next" title="Download SINGA" href="downloads.html"/> <link href="_static/style.css" rel="stylesheet" type="text/css"> @@ -65,7 +65,7 @@ <div class="version"> - 1.0 + 1.1 </div> @@ -263,7 +263,7 @@ <script type="text/javascript"> var DOCUMENTATION_OPTIONS = { URL_ROOT:'./', - VERSION:'1.0.1', + VERSION:'1.1.0', COLLAPSE_INDEX:false, FILE_SUFFIX:'.html', HAS_SOURCE: true @@ -296,7 +296,7 @@ <span class="rst-current-version" data-toggle="rst-current-version"> <span class="fa fa-book"> incubator-singa </span> - v: 1.0 + v: 1.1 <span class="fa fa-caret-down"></span> </span> <div class="rst-other-versions"> Modified: incubator/singa/site/trunk/en/objects.inv URL: http://svn.apache.org/viewvc/incubator/singa/site/trunk/en/objects.inv?rev=1780083&r1=1780082&r2=1780083&view=diff ============================================================================== Binary files - no diff available. Modified: incubator/singa/site/trunk/en/py-modindex.html URL: http://svn.apache.org/viewvc/incubator/singa/site/trunk/en/py-modindex.html?rev=1780083&r1=1780082&r2=1780083&view=diff ============================================================================== --- incubator/singa/site/trunk/en/py-modindex.html (original) +++ incubator/singa/site/trunk/en/py-modindex.html Tue Jan 24 14:49:41 2017 @@ -9,7 +9,7 @@ <meta name="viewport" content="width=device-width, initial-scale=1.0"> - <title>Python Module Index — incubator-singa 1.0.1 documentation</title> + <title>Python Module Index — incubator-singa 1.1.0 documentation</title> @@ -31,7 +31,7 @@ - <link rel="top" title="incubator-singa 1.0.1 documentation" href="index.html"/> + <link rel="top" title="incubator-singa 1.1.0 documentation" href="index.html"/> <link href="_static/style.css" rel="stylesheet" type="text/css"> @@ -67,7 +67,7 @@ <div class="version"> - 1.0 + 1.1 </div> @@ -135,7 +135,7 @@ <ul class="wy-breadcrumbs"> <li><a href="index.html">Docs</a> »</li> - <li></li> + <li>Python Module Index</li> <li class="wy-breadcrumbs-aside"> @@ -263,7 +263,7 @@ <script type="text/javascript"> var DOCUMENTATION_OPTIONS = { URL_ROOT:'./', - VERSION:'1.0.1', + VERSION:'1.1.0', COLLAPSE_INDEX:false, FILE_SUFFIX:'.html', HAS_SOURCE: true @@ -296,7 +296,7 @@ <span class="rst-current-version" data-toggle="rst-current-version"> <span class="fa fa-book"> incubator-singa </span> - v: 1.0 + v: 1.1 <span class="fa fa-caret-down"></span> </span> <div class="rst-other-versions"> Modified: incubator/singa/site/trunk/en/releases/RELEASE_NOTES_0.1.0.html URL: http://svn.apache.org/viewvc/incubator/singa/site/trunk/en/releases/RELEASE_NOTES_0.1.0.html?rev=1780083&r1=1780082&r2=1780083&view=diff ============================================================================== --- incubator/singa/site/trunk/en/releases/RELEASE_NOTES_0.1.0.html (original) +++ incubator/singa/site/trunk/en/releases/RELEASE_NOTES_0.1.0.html Tue Jan 24 14:49:41 2017 @@ -9,7 +9,7 @@ <meta name="viewport" content="width=device-width, initial-scale=1.0"> - <title><no title> — incubator-singa 1.0.1 documentation</title> + <title><no title> — incubator-singa 1.1.0 documentation</title> @@ -31,7 +31,7 @@ - <link rel="top" title="incubator-singa 1.0.1 documentation" href="../index.html"/> + <link rel="top" title="incubator-singa 1.1.0 documentation" href="../index.html"/> <link href="../_static/style.css" rel="stylesheet" type="text/css"> @@ -64,7 +64,7 @@ <div class="version"> - 1.0 + 1.1 </div> @@ -287,7 +287,7 @@ deep learning models.</p> <script type="text/javascript"> var DOCUMENTATION_OPTIONS = { URL_ROOT:'../', - VERSION:'1.0.1', + VERSION:'1.1.0', COLLAPSE_INDEX:false, FILE_SUFFIX:'.html', HAS_SOURCE: true @@ -320,7 +320,7 @@ deep learning models.</p> <span class="rst-current-version" data-toggle="rst-current-version"> <span class="fa fa-book"> incubator-singa </span> - v: 1.0 + v: 1.1 <span class="fa fa-caret-down"></span> </span> <div class="rst-other-versions"> Modified: incubator/singa/site/trunk/en/releases/RELEASE_NOTES_0.2.0.html URL: http://svn.apache.org/viewvc/incubator/singa/site/trunk/en/releases/RELEASE_NOTES_0.2.0.html?rev=1780083&r1=1780082&r2=1780083&view=diff ============================================================================== --- incubator/singa/site/trunk/en/releases/RELEASE_NOTES_0.2.0.html (original) +++ incubator/singa/site/trunk/en/releases/RELEASE_NOTES_0.2.0.html Tue Jan 24 14:49:41 2017 @@ -9,7 +9,7 @@ <meta name="viewport" content="width=device-width, initial-scale=1.0"> - <title><no title> — incubator-singa 1.0.1 documentation</title> + <title><no title> — incubator-singa 1.1.0 documentation</title> @@ -31,7 +31,7 @@ - <link rel="top" title="incubator-singa 1.0.1 documentation" href="../index.html"/> + <link rel="top" title="incubator-singa 1.1.0 documentation" href="../index.html"/> <link href="../_static/style.css" rel="stylesheet" type="text/css"> @@ -64,7 +64,7 @@ <div class="version"> - 1.0 + 1.1 </div> @@ -276,7 +276,7 @@ of popular deep learning models.</p> <script type="text/javascript"> var DOCUMENTATION_OPTIONS = { URL_ROOT:'../', - VERSION:'1.0.1', + VERSION:'1.1.0', COLLAPSE_INDEX:false, FILE_SUFFIX:'.html', HAS_SOURCE: true @@ -309,7 +309,7 @@ of popular deep learning models.</p> <span class="rst-current-version" data-toggle="rst-current-version"> <span class="fa fa-book"> incubator-singa </span> - v: 1.0 + v: 1.1 <span class="fa fa-caret-down"></span> </span> <div class="rst-other-versions"> Modified: incubator/singa/site/trunk/en/releases/RELEASE_NOTES_0.3.0.html URL: http://svn.apache.org/viewvc/incubator/singa/site/trunk/en/releases/RELEASE_NOTES_0.3.0.html?rev=1780083&r1=1780082&r2=1780083&view=diff ============================================================================== --- incubator/singa/site/trunk/en/releases/RELEASE_NOTES_0.3.0.html (original) +++ incubator/singa/site/trunk/en/releases/RELEASE_NOTES_0.3.0.html Tue Jan 24 14:49:41 2017 @@ -9,7 +9,7 @@ <meta name="viewport" content="width=device-width, initial-scale=1.0"> - <title><no title> — incubator-singa 1.0.1 documentation</title> + <title><no title> — incubator-singa 1.1.0 documentation</title> @@ -31,7 +31,7 @@ - <link rel="top" title="incubator-singa 1.0.1 documentation" href="../index.html"/> + <link rel="top" title="incubator-singa 1.1.0 documentation" href="../index.html"/> <link href="../_static/style.css" rel="stylesheet" type="text/css"> @@ -64,7 +64,7 @@ <div class="version"> - 1.0 + 1.1 </div> @@ -216,7 +216,7 @@ of popular deep learning models.</p> <script type="text/javascript"> var DOCUMENTATION_OPTIONS = { URL_ROOT:'../', - VERSION:'1.0.1', + VERSION:'1.1.0', COLLAPSE_INDEX:false, FILE_SUFFIX:'.html', HAS_SOURCE: true @@ -249,7 +249,7 @@ of popular deep learning models.</p> <span class="rst-current-version" data-toggle="rst-current-version"> <span class="fa fa-book"> incubator-singa </span> - v: 1.0 + v: 1.1 <span class="fa fa-caret-down"></span> </span> <div class="rst-other-versions"> Modified: incubator/singa/site/trunk/en/releases/RELEASE_NOTES_1.0.0.html URL: http://svn.apache.org/viewvc/incubator/singa/site/trunk/en/releases/RELEASE_NOTES_1.0.0.html?rev=1780083&r1=1780082&r2=1780083&view=diff ============================================================================== --- incubator/singa/site/trunk/en/releases/RELEASE_NOTES_1.0.0.html (original) +++ incubator/singa/site/trunk/en/releases/RELEASE_NOTES_1.0.0.html Tue Jan 24 14:49:41 2017 @@ -9,7 +9,7 @@ <meta name="viewport" content="width=device-width, initial-scale=1.0"> - <title><no title> — incubator-singa 1.0.1 documentation</title> + <title><no title> — incubator-singa 1.1.0 documentation</title> @@ -31,7 +31,7 @@ - <link rel="top" title="incubator-singa 1.0.1 documentation" href="../index.html"/> + <link rel="top" title="incubator-singa 1.1.0 documentation" href="../index.html"/> <link href="../_static/style.css" rel="stylesheet" type="text/css"> @@ -64,7 +64,7 @@ <div class="version"> - 1.0 + 1.1 </div> @@ -275,7 +275,7 @@ of popular deep learning models.</p> <script type="text/javascript"> var DOCUMENTATION_OPTIONS = { URL_ROOT:'../', - VERSION:'1.0.1', + VERSION:'1.1.0', COLLAPSE_INDEX:false, FILE_SUFFIX:'.html', HAS_SOURCE: true @@ -308,7 +308,7 @@ of popular deep learning models.</p> <span class="rst-current-version" data-toggle="rst-current-version"> <span class="fa fa-book"> incubator-singa </span> - v: 1.0 + v: 1.1 <span class="fa fa-caret-down"></span> </span> <div class="rst-other-versions"> Modified: incubator/singa/site/trunk/en/search.html URL: http://svn.apache.org/viewvc/incubator/singa/site/trunk/en/search.html?rev=1780083&r1=1780082&r2=1780083&view=diff ============================================================================== --- incubator/singa/site/trunk/en/search.html (original) +++ incubator/singa/site/trunk/en/search.html Tue Jan 24 14:49:41 2017 @@ -9,7 +9,7 @@ <meta name="viewport" content="width=device-width, initial-scale=1.0"> - <title>Search — incubator-singa 1.0.1 documentation</title> + <title>Search — incubator-singa 1.1.0 documentation</title> @@ -31,7 +31,7 @@ - <link rel="top" title="incubator-singa 1.0.1 documentation" href="index.html"/> + <link rel="top" title="incubator-singa 1.1.0 documentation" href="index.html"/> <link href="_static/style.css" rel="stylesheet" type="text/css"> @@ -64,7 +64,7 @@ <div class="version"> - 1.0 + 1.1 </div> @@ -132,7 +132,7 @@ <ul class="wy-breadcrumbs"> <li><a href="index.html">Docs</a> »</li> - <li></li> + <li>Search</li> <li class="wy-breadcrumbs-aside"> </li> @@ -187,7 +187,7 @@ <script type="text/javascript"> var DOCUMENTATION_OPTIONS = { URL_ROOT:'./', - VERSION:'1.0.1', + VERSION:'1.1.0', COLLAPSE_INDEX:false, FILE_SUFFIX:'.html', HAS_SOURCE: true @@ -227,7 +227,7 @@ <span class="rst-current-version" data-toggle="rst-current-version"> <span class="fa fa-book"> incubator-singa </span> - v: 1.0 + v: 1.1 <span class="fa fa-caret-down"></span> </span> <div class="rst-other-versions">
