Skip to content

Commit 00e3425

Browse files
author
array-api-bot
committed
Deploy: e906ba8
1 parent f4bbc55 commit 00e3425

File tree

7 files changed

+39
-37
lines changed

7 files changed

+39
-37
lines changed

draft/API_specification/generated/array_api.argmax.html

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -474,22 +474,22 @@ <h1 id="api-specification-generated-array-api-argmax--page-root">argmax<a class=
474474
<span class="sig-name descname"><span class="pre">argmax</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">x</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">array</span></span></em>, <em class="sig-param"><span class="o"><span class="pre">/</span></span></em>, <em class="sig-param"><span class="o"><span class="pre">*</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">axis</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">int</span><span class="w"> </span><span class="p"><span class="pre">|</span></span><span class="w"> </span><span class="pre">None</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">None</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">keepdims</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">bool</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">False</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon"></span> <span class="sig-return-typehint"><span class="pre">array</span></span></span><a class="headerlink" href="#array_api.argmax" title="Link to this definition"></a></dt>
475475
<dd><p>Returns the indices of the maximum values along a specified axis.</p>
476476
<p>When the maximum value occurs multiple times, only the indices corresponding to the first occurrence are returned.</p>
477-
<div class="admonition note">
478-
<p class="admonition-title">Note</p>
479-
<p>For backward compatibility, conforming implementations may support complex numbers; however, inequality comparison of complex numbers is unspecified and thus implementation-dependent (see <a class="reference internal" href="../../design_topics/complex_numbers.html#complex-number-ordering"><span class="std std-ref">Complex Number Ordering</span></a>).</p>
480-
</div>
481477
<dl class="field-list simple">
482478
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
483479
<dd class="field-odd"><ul class="simple">
484-
<li><p><strong>x</strong> (<em>array</em>) – input array. Should have a real-valued data type.</p></li>
485-
<li><p><strong>axis</strong> (<em>Optional</em><em>[</em><em>int</em><em>]</em>) – axis along which to search. If <code class="docutils literal notranslate"><span class="pre">None</span></code>, the function must return the index of the maximum value of the flattened array. Default: <code class="docutils literal notranslate"><span class="pre">None</span></code>.</p></li>
486-
<li><p><strong>keepdims</strong> (<em>bool</em>) – if <code class="docutils literal notranslate"><span class="pre">True</span></code>, the reduced axes (dimensions) must be included in the result as singleton dimensions, and, accordingly, the result must be compatible with the input array (see <a class="reference internal" href="../broadcasting.html#broadcasting"><span class="std std-ref">Broadcasting</span></a>). Otherwise, if <code class="docutils literal notranslate"><span class="pre">False</span></code>, the reduced axes (dimensions) must not be included in the result. Default: <code class="docutils literal notranslate"><span class="pre">False</span></code>.</p></li>
480+
<li><p><strong>x</strong> (<em>array</em>) – input array. <strong>Should</strong> have a real-valued data type.</p></li>
481+
<li><p><strong>axis</strong> (<em>Optional</em><em>[</em><em>int</em><em>]</em>) – axis along which to search. If <code class="docutils literal notranslate"><span class="pre">None</span></code>, the function <strong>must</strong> return the index of the maximum value of the flattened array. If not <code class="docutils literal notranslate"><span class="pre">None</span></code>, a valid axis <strong>must</strong> be an integer on the interval <code class="docutils literal notranslate"><span class="pre">[-N,</span> <span class="pre">N)</span></code>, where <code class="docutils literal notranslate"><span class="pre">N</span></code> is the number of axes in <code class="docutils literal notranslate"><span class="pre">x</span></code>. If an axis is specified as a negative integer, the function <strong>must</strong> determine the axis along which to perform the operation by counting backward from the last axis (where <code class="docutils literal notranslate"><span class="pre">-1</span></code> refers to the last axis). If provided an invalid axis, the function <strong>must</strong> raise an exception. Default: <code class="docutils literal notranslate"><span class="pre">None</span></code>.</p></li>
482+
<li><p><strong>keepdims</strong> (<em>bool</em>) – if <code class="docutils literal notranslate"><span class="pre">True</span></code>, the reduced axes <strong>must</strong> be included in the result as singleton dimensions, and, accordingly, the result <strong>must</strong> be broadcast-compatible with the input array (see <a class="reference internal" href="../broadcasting.html#broadcasting"><span class="std std-ref">Broadcasting</span></a>). Otherwise, if <code class="docutils literal notranslate"><span class="pre">False</span></code>, the reduced axes <strong>must not</strong> be included in the result. Default: <code class="docutils literal notranslate"><span class="pre">False</span></code>.</p></li>
487483
</ul>
488484
</dd>
489485
<dt class="field-even">Returns<span class="colon">:</span></dt>
490-
<dd class="field-even"><p><strong>out</strong> (<em>array</em>) – if <code class="docutils literal notranslate"><span class="pre">axis</span></code> is <code class="docutils literal notranslate"><span class="pre">None</span></code>, a zero-dimensional array containing the index of the first occurrence of the maximum value; otherwise, a non-zero-dimensional array containing the indices of the maximum values. The returned array must have be the default array index data type.</p>
486+
<dd class="field-even"><p><strong>out</strong> (<em>array</em>) – if <code class="docutils literal notranslate"><span class="pre">axis</span></code> is <code class="docutils literal notranslate"><span class="pre">None</span></code>, a zero-dimensional array containing the index of the first occurrence of the maximum value; otherwise, a non-zero-dimensional array containing the indices of the maximum values. The returned array <strong>must</strong> have be the default array index data type.</p>
491487
</dd>
492488
</dl>
489+
<p class="rubric">Notes</p>
490+
<ul class="simple">
491+
<li><p>For backward compatibility, conforming implementations <strong>may</strong> support complex numbers; however, inequality comparison of complex numbers is unspecified and thus implementation-dependent (see <a class="reference internal" href="../../design_topics/complex_numbers.html#complex-number-ordering"><span class="std std-ref">Complex Number Ordering</span></a>).</p></li>
492+
</ul>
493493
</dd></dl>
494494
</section>
495495

draft/API_specification/generated/array_api.argmin.html

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -474,22 +474,22 @@ <h1 id="api-specification-generated-array-api-argmin--page-root">argmin<a class=
474474
<span class="sig-name descname"><span class="pre">argmin</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">x</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">array</span></span></em>, <em class="sig-param"><span class="o"><span class="pre">/</span></span></em>, <em class="sig-param"><span class="o"><span class="pre">*</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">axis</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">int</span><span class="w"> </span><span class="p"><span class="pre">|</span></span><span class="w"> </span><span class="pre">None</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">None</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">keepdims</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">bool</span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">False</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon"></span> <span class="sig-return-typehint"><span class="pre">array</span></span></span><a class="headerlink" href="#array_api.argmin" title="Link to this definition"></a></dt>
475475
<dd><p>Returns the indices of the minimum values along a specified axis.</p>
476476
<p>When the minimum value occurs multiple times, only the indices corresponding to the first occurrence are returned.</p>
477-
<div class="admonition note">
478-
<p class="admonition-title">Note</p>
479-
<p>For backward compatibility, conforming implementations may support complex numbers; however, inequality comparison of complex numbers is unspecified and thus implementation-dependent (see <a class="reference internal" href="../../design_topics/complex_numbers.html#complex-number-ordering"><span class="std std-ref">Complex Number Ordering</span></a>).</p>
480-
</div>
481477
<dl class="field-list simple">
482478
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
483479
<dd class="field-odd"><ul class="simple">
484-
<li><p><strong>x</strong> (<em>array</em>) – input array. Should have a real-valued data type.</p></li>
485-
<li><p><strong>axis</strong> (<em>Optional</em><em>[</em><em>int</em><em>]</em>) – axis along which to search. If <code class="docutils literal notranslate"><span class="pre">None</span></code>, the function must return the index of the minimum value of the flattened array. Default: <code class="docutils literal notranslate"><span class="pre">None</span></code>.</p></li>
486-
<li><p><strong>keepdims</strong> (<em>bool</em>) – if <code class="docutils literal notranslate"><span class="pre">True</span></code>, the reduced axes (dimensions) must be included in the result as singleton dimensions, and, accordingly, the result must be compatible with the input array (see <a class="reference internal" href="../broadcasting.html#broadcasting"><span class="std std-ref">Broadcasting</span></a>). Otherwise, if <code class="docutils literal notranslate"><span class="pre">False</span></code>, the reduced axes (dimensions) must not be included in the result. Default: <code class="docutils literal notranslate"><span class="pre">False</span></code>.</p></li>
480+
<li><p><strong>x</strong> (<em>array</em>) – input array. <strong>Should</strong> have a real-valued data type.</p></li>
481+
<li><p><strong>axis</strong> (<em>Optional</em><em>[</em><em>int</em><em>]</em>) – axis along which to search. If <code class="docutils literal notranslate"><span class="pre">None</span></code>, the function <strong>must</strong> return the index of the minimum value of the flattened array. If not <code class="docutils literal notranslate"><span class="pre">None</span></code>, a valid axis <strong>must</strong> be an integer on the interval <code class="docutils literal notranslate"><span class="pre">[-N,</span> <span class="pre">N)</span></code>, where <code class="docutils literal notranslate"><span class="pre">N</span></code> is the number of axes in <code class="docutils literal notranslate"><span class="pre">x</span></code>. If an axis is specified as a negative integer, the function <strong>must</strong> determine the axis along which to perform the operation by counting backward from the last axis (where <code class="docutils literal notranslate"><span class="pre">-1</span></code> refers to the last axis). If provided an invalid axis, the function <strong>must</strong> raise an exception. Default: <code class="docutils literal notranslate"><span class="pre">None</span></code>.</p></li>
482+
<li><p><strong>keepdims</strong> (<em>bool</em>) – if <code class="docutils literal notranslate"><span class="pre">True</span></code>, the reduced axes <strong>must</strong> be included in the result as singleton dimensions, and, accordingly, the result <strong>must</strong> be broadcast-compatible with the input array (see <a class="reference internal" href="../broadcasting.html#broadcasting"><span class="std std-ref">Broadcasting</span></a>). Otherwise, if <code class="docutils literal notranslate"><span class="pre">False</span></code>, the reduced axes <strong>must not</strong> be included in the result. Default: <code class="docutils literal notranslate"><span class="pre">False</span></code>.</p></li>
487483
</ul>
488484
</dd>
489485
<dt class="field-even">Returns<span class="colon">:</span></dt>
490-
<dd class="field-even"><p><strong>out</strong> (<em>array</em>) – if <code class="docutils literal notranslate"><span class="pre">axis</span></code> is <code class="docutils literal notranslate"><span class="pre">None</span></code>, a zero-dimensional array containing the index of the first occurrence of the minimum value; otherwise, a non-zero-dimensional array containing the indices of the minimum values. The returned array must have the default array index data type.</p>
486+
<dd class="field-even"><p><strong>out</strong> (<em>array</em>) – if <code class="docutils literal notranslate"><span class="pre">axis</span></code> is <code class="docutils literal notranslate"><span class="pre">None</span></code>, a zero-dimensional array containing the index of the first occurrence of the minimum value; otherwise, a non-zero-dimensional array containing the indices of the minimum values. The returned array <strong>must</strong> have the default array index data type.</p>
491487
</dd>
492488
</dl>
489+
<p class="rubric">Notes</p>
490+
<ul class="simple">
491+
<li><p>For backward compatibility, conforming implementations <strong>may</strong> support complex numbers; however, inequality comparison of complex numbers is unspecified and thus implementation-dependent (see <a class="reference internal" href="../../design_topics/complex_numbers.html#complex-number-ordering"><span class="std std-ref">Complex Number Ordering</span></a>).</p></li>
492+
</ul>
493493
</dd></dl>
494494
</section>
495495

draft/API_specification/generated/array_api.count_nonzero.html

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -477,12 +477,12 @@ <h1 id="api-specification-generated-array-api-count-nonzero--page-root">count_no
477477
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
478478
<dd class="field-odd"><ul class="simple">
479479
<li><p><strong>x</strong> (<em>array</em>) – input array.</p></li>
480-
<li><p><strong>axis</strong> (<em>Optional</em><em>[</em><em>Union</em><em>[</em><em>int</em><em>, </em><em>Tuple</em><em>[</em><em>int</em><em>, </em><em>...</em><em>]</em><em>]</em><em>]</em>) – axis or axes along which to count non-zero values. By default, the number of non-zero values must be computed over the entire array. If a tuple of integers, the number of non-zero values must be computed over multiple axes. Default: <code class="docutils literal notranslate"><span class="pre">None</span></code>.</p></li>
481-
<li><p><strong>keepdims</strong> (<em>bool</em>) – if <code class="docutils literal notranslate"><span class="pre">True</span></code>, the reduced axes (dimensions) must be included in the result as singleton dimensions, and, accordingly, the result must be compatible with the input array (see <a class="reference internal" href="../broadcasting.html#broadcasting"><span class="std std-ref">Broadcasting</span></a>). Otherwise, if <code class="docutils literal notranslate"><span class="pre">False</span></code>, the reduced axes (dimensions) must not be included in the result. Default: <code class="docutils literal notranslate"><span class="pre">False</span></code>.</p></li>
480+
<li><p><strong>axis</strong> (<em>Optional</em><em>[</em><em>Union</em><em>[</em><em>int</em><em>, </em><em>Tuple</em><em>[</em><em>int</em><em>, </em><em>...</em><em>]</em><em>]</em><em>]</em>) – axis or axes along which to count non-zero values. By default, the number of non-zero values must be computed over the entire array. If a tuple of integers, the number of non-zero values must be computed over multiple axes. A valid axis <strong>must</strong> be an integer on the interval <code class="docutils literal notranslate"><span class="pre">[-N,</span> <span class="pre">N)</span></code>, where <code class="docutils literal notranslate"><span class="pre">N</span></code> is the number of axes in <code class="docutils literal notranslate"><span class="pre">x</span></code>. If an axis is specified as a negative integer, the function <strong>must</strong> determine the axis along which to perform the operation by counting backward from the last axis (where <code class="docutils literal notranslate"><span class="pre">-1</span></code> refers to the last axis). If provided an invalid axis, the function <strong>must</strong> raise an exception. Default: <code class="docutils literal notranslate"><span class="pre">None</span></code>.</p></li>
481+
<li><p><strong>keepdims</strong> (<em>bool</em>) – if <code class="docutils literal notranslate"><span class="pre">True</span></code>, the reduced axes <strong>must</strong> be included in the result as singleton dimensions, and, accordingly, the result <strong>must</strong> be broadcast-compatible with the input array (see <a class="reference internal" href="../broadcasting.html#broadcasting"><span class="std std-ref">Broadcasting</span></a>). Otherwise, if <code class="docutils literal notranslate"><span class="pre">False</span></code>, the reduced axes <strong>must not</strong> be included in the result. Default: <code class="docutils literal notranslate"><span class="pre">False</span></code>.</p></li>
482482
</ul>
483483
</dd>
484484
<dt class="field-even">Returns<span class="colon">:</span></dt>
485-
<dd class="field-even"><p><strong>out</strong> (<em>array</em>) – if the number of non-zeros values was computed over the entire array, a zero-dimensional array containing the total number of non-zero values; otherwise, a non-zero-dimensional array containing the counts along the specified axes. The returned array must have the default array index data type.</p>
485+
<dd class="field-even"><p><strong>out</strong> (<em>array</em>) – if the number of non-zeros values was computed over the entire array, a zero-dimensional array containing the total number of non-zero values; otherwise, a non-zero-dimensional array containing the counts along the specified axes. The returned array <strong>must</strong> have the default array index data type.</p>
486486
</dd>
487487
</dl>
488488
<p class="rubric">Notes</p>

0 commit comments

Comments
 (0)