Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 06bcd03

Browse files
committed
ABC, progress bar
1 parent e2b3bb2 commit 06bcd03

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -261,7 +261,7 @@ from types import FunctionType, MethodType, LambdaType, GeneratorType
261261
```
262262

263263
### Abstract Base Classes
264-
**Each abstract base class specifies a set of virtual subclasses. These classes are then recognized by isinstance() and issubclass() as subclasses of the ABC, although they are really not. ABC can also manually decide whether or not a specific class is its virtual subclass.**
264+
**Each abstract base class specifies a set of virtual subclasses. These classes are then recognized by isinstance() and issubclass() as subclasses of the ABC, although they are really not. ABC can also manually decide whether or not a specific class is its virtual subclass, usually based on which methods the class has implemented (Collection, Iterable).**
265265

266266
```python
267267
>>> from collections.abc import Sequence, Collection, Iterable
@@ -2337,7 +2337,7 @@ Progress Bar
23372337
>>> from time import sleep
23382338
>>> for el in tqdm([1, 2, 3], desc='Processing'):
23392339
... sleep(1)
2340-
Processing: 100%|██████████████████| 3/3 [00:03<00:00, 1.00s/it]
2340+
Processing: 100%|████████████████████| 3/3 [00:03<00:00, 1.00s/it]
23412341
```
23422342

23432343

index.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -402,7 +402,7 @@
402402
<div><h4 id="sometypesdonothavebuiltinnamessotheymustbeimported">Some types do not have built-in names, so they must be imported:</h4><pre><code class="python language-python hljs"><span class="hljs-keyword">from</span> types <span class="hljs-keyword">import</span> FunctionType, MethodType, LambdaType, GeneratorType
403403
</code></pre></div>
404404

405-
<div><h3 id="abstractbaseclasses">Abstract Base Classes</h3><p><strong>Each abstract base class specifies a set of virtual subclasses. These classes are then recognized by isinstance() and issubclass() as subclasses of the ABC, although they are really not. ABC can also manually decide whether or not a specific class is its virtual subclass.</strong></p><pre><code class="python language-python hljs"><span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> collections.abc <span class="hljs-keyword">import</span> Sequence, Collection, Iterable
405+
<div><h3 id="abstractbaseclasses">Abstract Base Classes</h3><p><strong>Each abstract base class specifies a set of virtual subclasses. These classes are then recognized by isinstance() and issubclass() as subclasses of the ABC, although they are really not. ABC can also manually decide whether or not a specific class is its virtual subclass, usually based on which methods the class has implemented (Collection, Iterable).</strong></p><pre><code class="python language-python hljs"><span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> collections.abc <span class="hljs-keyword">import</span> Sequence, Collection, Iterable
406406
<span class="hljs-meta">&gt;&gt;&gt; </span>isinstance([<span class="hljs-number">1</span>, <span class="hljs-number">2</span>, <span class="hljs-number">3</span>], Iterable)
407407
<span class="hljs-keyword">True</span>
408408
</code></pre></div>
@@ -2041,7 +2041,7 @@
20412041
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> time <span class="hljs-keyword">import</span> sleep
20422042
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">for</span> el <span class="hljs-keyword">in</span> tqdm([<span class="hljs-number">1</span>, <span class="hljs-number">2</span>, <span class="hljs-number">3</span>], desc=<span class="hljs-string">'Processing'</span>):
20432043
<span class="hljs-meta">... </span> sleep(<span class="hljs-number">1</span>)
2044-
Processing: 100%|███████████████████| 3/3 [00:03&lt;00:00, 1.00s/it]
2044+
Processing: 100%|███████████████████| 3/3 [00:03&lt;00:00, 1.00s/it]
20452045
</code></pre></div></div>
20462046

20472047

parse.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ const PROGRESS_BAR =
6969
'<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> time <span class="hljs-keyword">import</span> sleep\n' +
7070
'<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">for</span> el <span class="hljs-keyword">in</span> tqdm([<span class="hljs-number">1</span>, <span class="hljs-number">2</span>, <span class="hljs-number">3</span>], desc=<span class="hljs-string">\'Processing\'</span>):\n' +
7171
'<span class="hljs-meta">... </span> sleep(<span class="hljs-number">1</span>)\n' +
72-
'Processing: 100%|███████████████████| 3/3 [00:03&lt;00:00, 1.00s/it]\n';
72+
'Processing: 100%|███████████████████| 3/3 [00:03&lt;00:00, 1.00s/it]\n';
7373

7474
const PYINSTALLER =
7575
'$ pip3 install pyinstaller\n' +

0 commit comments

Comments
 (0)