forked from apachecn/numpy-doc-zh
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathroutines.bitwise.html
68 lines (66 loc) · 4.7 KB
/
routines.bitwise.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
<h1><span class="yiyi-st" id="yiyi-16">Binary operations</span></h1>
<blockquote>
<p>原文:<a href="https://docs.scipy.org/doc/numpy/reference/routines.bitwise.html">https://docs.scipy.org/doc/numpy/reference/routines.bitwise.html</a></p>
<p>译者:<a href="https://github.com/wizardforcel">飞龙</a> <a href="http://usyiyi.cn/">UsyiyiCN</a></p>
<p>校对:(虚位以待)</p>
</blockquote>
<div class="section" id="elementwise-bit-operations">
<h2><span class="yiyi-st" id="yiyi-17">Elementwise bit operations</span></h2>
<table border="1" class="longtable docutils">
<colgroup>
<col width="10%">
<col width="90%">
</colgroup>
<tbody valign="top">
<tr class="row-odd"><td><span class="yiyi-st" id="yiyi-18"><a class="reference internal" href="generated/numpy.bitwise_and.html#numpy.bitwise_and" title="numpy.bitwise_and"><code class="xref py py-obj docutils literal"><span class="pre">bitwise_and</span></code></a>(x1,x2 [,out])</span></td>
<td><span class="yiyi-st" id="yiyi-19">计算元素方面的两个数组的逐位AND。</span></td>
</tr>
<tr class="row-even"><td><span class="yiyi-st" id="yiyi-20"><a class="reference internal" href="generated/numpy.bitwise_or.html#numpy.bitwise_or" title="numpy.bitwise_or"><code class="xref py py-obj docutils literal"><span class="pre">bitwise_or</span></code></a>(x1,x2 [,out])</span></td>
<td><span class="yiyi-st" id="yiyi-21">计算元素方面的两个数组的逐位OR。</span></td>
</tr>
<tr class="row-odd"><td><span class="yiyi-st" id="yiyi-22"><a class="reference internal" href="generated/numpy.bitwise_xor.html#numpy.bitwise_xor" title="numpy.bitwise_xor"><code class="xref py py-obj docutils literal"><span class="pre">bitwise_xor</span></code></a>(x1,x2 [,out])</span></td>
<td><span class="yiyi-st" id="yiyi-23">按元素方式计算两个数组的逐位异或。</span></td>
</tr>
<tr class="row-even"><td><span class="yiyi-st" id="yiyi-24"><a class="reference internal" href="generated/numpy.invert.html#numpy.invert" title="numpy.invert"><code class="xref py py-obj docutils literal"><span class="pre">invert</span></code></a>(x [,out])</span></td>
<td><span class="yiyi-st" id="yiyi-25">逐位计算逐位反转,或逐位非单元。</span></td>
</tr>
<tr class="row-odd"><td><span class="yiyi-st" id="yiyi-26"><a class="reference internal" href="generated/numpy.left_shift.html#numpy.left_shift" title="numpy.left_shift"><code class="xref py py-obj docutils literal"><span class="pre">left_shift</span></code></a>(x1,x2 [,out])</span></td>
<td><span class="yiyi-st" id="yiyi-27">将整数的位向左移位。</span></td>
</tr>
<tr class="row-even"><td><span class="yiyi-st" id="yiyi-28"><a class="reference internal" href="generated/numpy.right_shift.html#numpy.right_shift" title="numpy.right_shift"><code class="xref py py-obj docutils literal"><span class="pre">right_shift</span></code></a>(x1,x2 [,out])</span></td>
<td><span class="yiyi-st" id="yiyi-29">将整数的位向右移位。</span></td>
</tr>
</tbody>
</table>
</div>
<div class="section" id="bit-packing">
<h2><span class="yiyi-st" id="yiyi-30">Bit packing</span></h2>
<table border="1" class="longtable docutils">
<colgroup>
<col width="10%">
<col width="90%">
</colgroup>
<tbody valign="top">
<tr class="row-odd"><td><span class="yiyi-st" id="yiyi-31"><a class="reference internal" href="generated/numpy.packbits.html#numpy.packbits" title="numpy.packbits"><code class="xref py py-obj docutils literal"><span class="pre">packbits</span></code></a>(myarray [,axis])</span></td>
<td><span class="yiyi-st" id="yiyi-32">将二进制值数组的元素包含在uint8数组中的位中。</span></td>
</tr>
<tr class="row-even"><td><span class="yiyi-st" id="yiyi-33"><a class="reference internal" href="generated/numpy.unpackbits.html#numpy.unpackbits" title="numpy.unpackbits"><code class="xref py py-obj docutils literal"><span class="pre">unpackbits</span></code></a>(myarray [,axis])</span></td>
<td><span class="yiyi-st" id="yiyi-34">将uint8数组的元素解包成二进制值输出数组。</span></td>
</tr>
</tbody>
</table>
</div>
<div class="section" id="output-formatting">
<h2><span class="yiyi-st" id="yiyi-35">Output formatting</span></h2>
<table border="1" class="longtable docutils">
<colgroup>
<col width="10%">
<col width="90%">
</colgroup>
<tbody valign="top">
<tr class="row-odd"><td><span class="yiyi-st" id="yiyi-36"><a class="reference internal" href="generated/numpy.binary_repr.html#numpy.binary_repr" title="numpy.binary_repr"><code class="xref py py-obj docutils literal"><span class="pre">binary_repr</span></code></a>(num [,width])</span></td>
<td><span class="yiyi-st" id="yiyi-37"></span></td>
</tr>
</tbody>
</table>
</div>