Browse Source

Progress bar, index

pull/83/head
Jure Šorn 3 years ago
parent
commit
c93c7002f3
5 changed files with 27 additions and 25 deletions
  1. 2
      README.md
  2. 2
      index.html
  3. 2
      parse.js
  4. 23
      pdf/index_for_pdf.html
  5. 23
      pdf/index_for_pdf_print.html

2
README.md

@ -2337,7 +2337,7 @@ Progress Bar
>>> from time import sleep >>> from time import sleep
>>> for el in tqdm([1, 2, 3], desc='Processing'): >>> for el in tqdm([1, 2, 3], desc='Processing'):
... sleep(1) ... sleep(1)
Processing: 100%|████████████████████| 3/3 [00:03<00:00, 1.00s/it]
Processing: 100%|████████████████████| 3/3 [00:03<00:00, 1.00s/it]
``` ```

2
index.html

@ -2041,7 +2041,7 @@ curses.wrapper(main)
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> time <span class="hljs-keyword">import</span> sleep <span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> time <span class="hljs-keyword">import</span> sleep
<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>): <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>):
<span class="hljs-meta">... </span> sleep(<span class="hljs-number">1</span>) <span class="hljs-meta">... </span> sleep(<span class="hljs-number">1</span>)
Processing: 100%|████████████████████| 3/3 [00:03&lt;00:00, 1.00s/it]
Processing: 100%|████████████████████| 3/3 [00:03&lt;00:00, 1.00s/it]
</code></pre></div></div> </code></pre></div></div>

2
parse.js

@ -69,7 +69,7 @@ const PROGRESS_BAR =
'<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> time <span class="hljs-keyword">import</span> sleep\n' + '<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> time <span class="hljs-keyword">import</span> sleep\n' +
'<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' + '<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' +
'<span class="hljs-meta">... </span> sleep(<span class="hljs-number">1</span>)\n' + '<span class="hljs-meta">... </span> sleep(<span class="hljs-number">1</span>)\n' +
'Processing: 100%|████████████████████| 3/3 [00:03&lt;00:00, 1.00s/it]\n';
'Processing: 100%|████████████████████| 3/3 [00:03&lt;00:00, 1.00s/it]\n';
const PYINSTALLER = const PYINSTALLER =
'$ pip3 install pyinstaller\n' + '$ pip3 install pyinstaller\n' +

23
pdf/index_for_pdf.html

@ -7,7 +7,7 @@
<p><strong>abstract base classes, <a href="#abstractbaseclasses">4</a>, <a href="#abcsequence">19</a></strong><br> <p><strong>abstract base classes, <a href="#abstractbaseclasses">4</a>, <a href="#abcsequence">19</a></strong><br>
<strong>animation, <a href="#animation">40</a>, <a href="#pygame">42</a>-<a href="#basicmariobrothersexample">43</a></strong><br> <strong>animation, <a href="#animation">40</a>, <a href="#pygame">42</a>-<a href="#basicmariobrothersexample">43</a></strong><br>
<strong>argparse module, <a href="#argumentparser">22</a></strong><br> <strong>argparse module, <a href="#argumentparser">22</a></strong><br>
<strong>arguments, <a href="#arguments">10</a>, <a href="#partial">12</a></strong><br>
<strong>arguments, <a href="#arguments">10</a>, <a href="#partial">12</a>, <a href="#commandlinearguments">22</a></strong><br>
<strong>arrays, <a href="#array">29</a>, <a href="#numpy">37</a>-<a href="#indexing">38</a></strong><br> <strong>arrays, <a href="#array">29</a>, <a href="#numpy">37</a>-<a href="#indexing">38</a></strong><br>
<strong>asyncio module, <a href="#coroutines">33</a></strong><br> <strong>asyncio module, <a href="#coroutines">33</a></strong><br>
<strong>audio, <a href="#audio">40</a>-<a href="#writefloatsamplestowavfile">41</a>, <a href="#sound">42</a></strong> </p> <strong>audio, <a href="#audio">40</a>-<a href="#writefloatsamplestowavfile">41</a>, <a href="#sound">42</a></strong> </p>
@ -21,18 +21,18 @@
<p><strong>cache, <a href="#lrucache">13</a></strong><br> <p><strong>cache, <a href="#lrucache">13</a></strong><br>
<strong>callable, <a href="#callable">17</a></strong><br> <strong>callable, <a href="#callable">17</a></strong><br>
<strong>class, <a href="#type">4</a>, <a href="#class">14</a>-<a href="#abcsequence">19</a>, <a href="#metaprograming">31</a>-<a href="#metaclass">32</a></strong><br> <strong>class, <a href="#type">4</a>, <a href="#class">14</a>-<a href="#abcsequence">19</a>, <a href="#metaprograming">31</a>-<a href="#metaclass">32</a></strong><br>
<strong>closure, <a href="#closure">12</a></strong><br>
<strong>closure, <a href="#closure">12</a>-<a href="#decorator">13</a></strong><br>
<strong>collection, <a href="#abstractbaseclasses">4</a>, <a href="#collection">18</a>, <a href="#tableofrequiredandautomaticallyavailablespecialmethods">19</a></strong><br> <strong>collection, <a href="#abstractbaseclasses">4</a>, <a href="#collection">18</a>, <a href="#tableofrequiredandautomaticallyavailablespecialmethods">19</a></strong><br>
<strong>collections module, <a href="#dictionary">2</a>, <a href="#namedtuple">3</a>, <a href="#abstractbaseclasses">4</a>, <a href="#abcsequence">19</a>, <a href="#deque">29</a></strong><br> <strong>collections module, <a href="#dictionary">2</a>, <a href="#namedtuple">3</a>, <a href="#abstractbaseclasses">4</a>, <a href="#abcsequence">19</a>, <a href="#deque">29</a></strong><br>
<strong>combinatorics, <a href="#combinatorics">8</a></strong><br> <strong>combinatorics, <a href="#combinatorics">8</a></strong><br>
<strong>command line arguments, <a href="#commandlinearguments">22</a></strong><br> <strong>command line arguments, <a href="#commandlinearguments">22</a></strong><br>
<strong>comparable, <a href="#comparable">16</a></strong><br> <strong>comparable, <a href="#comparable">16</a></strong><br>
<strong>comprehensions, <a href="#comprehensions">11</a></strong><br> <strong>comprehensions, <a href="#comprehensions">11</a></strong><br>
<strong>context manager, <a href="#contextmanager">17</a></strong><br>
<strong>context manager, <a href="#contextmanager">17</a>, <a href="#readtextfromfile">23</a>, <a href="#or">27</a>, <a href="#or-1">30</a></strong><br>
<strong>copy function, <a href="#copy">15</a></strong><br> <strong>copy function, <a href="#copy">15</a></strong><br>
<strong>coroutine, <a href="#coroutines">33</a></strong><br> <strong>coroutine, <a href="#coroutines">33</a></strong><br>
<strong>counter, <a href="#counter">2</a>, <a href="#generator">4</a>, <a href="#nonlocal">12</a>, <a href="#iterator-1">17</a></strong><br> <strong>counter, <a href="#counter">2</a>, <a href="#generator">4</a>, <a href="#nonlocal">12</a>, <a href="#iterator-1">17</a></strong><br>
<strong>csv module, <a href="#csv">26</a>, <a href="#printsacsvfileasanasciitable">34</a>, <a href="#encodedecode">46</a></strong><br>
<strong>csv, <a href="#csv">26</a>, <a href="#printsacsvfileasanasciitable">34</a>, <a href="#encodedecode">46</a></strong><br>
<strong>curses module, <a href="#runsaterminalgamewhereyoucontrolanasteriskthatmustavoidnumbers">33</a>, <a href="#curses">34</a></strong><br> <strong>curses module, <a href="#runsaterminalgamewhereyoucontrolanasteriskthatmustavoidnumbers">33</a>, <a href="#curses">34</a></strong><br>
<strong>cython, <a href="#cython">49</a></strong> </p> <strong>cython, <a href="#cython">49</a></strong> </p>
<h3 id="d">D</h3> <h3 id="d">D</h3>
@ -40,13 +40,13 @@
<strong>datetime module, <a href="#datetime">8</a>-<a href="#constructors">9</a></strong><br> <strong>datetime module, <a href="#datetime">8</a>-<a href="#constructors">9</a></strong><br>
<strong>decorator, <a href="#decorator">13</a></strong><br> <strong>decorator, <a href="#decorator">13</a></strong><br>
<strong>deques, <a href="#deque">29</a></strong><br> <strong>deques, <a href="#deque">29</a></strong><br>
<strong>dictionaries, <a href="#dictionary">2</a>, <a href="#otheruses">11</a></strong><br>
<strong>dictionaries, <a href="#dictionary">2</a>, <a href="#abstractbaseclasses">4</a>, <a href="#otheruses">11</a>, <a href="#tableofrequiredandautomaticallyavailablespecialmethods">19</a>, <a href="#collectionsandtheirexceptions">21</a></strong><br>
<strong>duck types, <a href="#ducktypes">16</a>-<a href="#abcsequence">19</a></strong> </p> <strong>duck types, <a href="#ducktypes">16</a>-<a href="#abcsequence">19</a></strong> </p>
<h3 id="e">E</h3> <h3 id="e">E</h3>
<p><strong>enum module, <a href="#enum">19</a>-<a href="#inline-2">20</a></strong><br> <p><strong>enum module, <a href="#enum">19</a>-<a href="#inline-2">20</a></strong><br>
<strong>enumerate function, <a href="#enumerate">3</a></strong><br> <strong>enumerate function, <a href="#enumerate">3</a></strong><br>
<strong>eval function, <a href="#eval">33</a></strong><br> <strong>eval function, <a href="#eval">33</a></strong><br>
<strong>exceptions, <a href="#exceptions">20</a>-<a href="#exceptionobject">21</a>, <a href="#exceptions-1">23</a></strong> </p>
<strong>exceptions, <a href="#exceptions">20</a>-<a href="#exceptionobject">21</a>, <a href="#exceptions-1">23</a>, <a href="#exceptions-2">35</a></strong> </p>
<h3 id="f">F</h3> <h3 id="f">F</h3>
<p><strong>files, <a href="#fileobject">23</a></strong><br> <p><strong>files, <a href="#fileobject">23</a></strong><br>
<strong>filter function, <a href="#mapfilterreduce">11</a></strong><br> <strong>filter function, <a href="#mapfilterreduce">11</a></strong><br>
@ -56,16 +56,17 @@
<strong>futures, <a href="#threadpoolexecutor">30</a></strong> </p> <strong>futures, <a href="#threadpoolexecutor">30</a></strong> </p>
<h3 id="g">G</h3> <h3 id="g">G</h3>
<p><strong>generators, <a href="#generator">4</a>, <a href="#comprehensions">11</a></strong><br> <p><strong>generators, <a href="#generator">4</a>, <a href="#comprehensions">11</a></strong><br>
<strong>global keyword, <a href="#nonlocal">12</a></strong></p>
<strong>global keyword, <a href="#nonlocal">12</a></strong><br>
<strong>gui, <a href="#pysimplegui">48</a></strong> </p>
<h3 id="h">H</h3> <h3 id="h">H</h3>
<p><strong>hashable, <a href="#hashable">16</a></strong><br>
<strong>hexadecimal representation, <a href="#binhex">8</a></strong> </p>
<p><strong>hashable, <a href="#dataclass">15</a>, <a href="#hashable">16</a></strong><br>
<strong>hexadecimal representation, <a href="#ints">7</a>, <a href="#binhex">8</a>, <a href="#encode-1">28</a></strong> </p>
<h3 id="i">I</h3> <h3 id="i">I</h3>
<p><strong>image, <a href="#image">39</a></strong><br> <p><strong>image, <a href="#image">39</a></strong><br>
<strong>inline, <a href="#inline">11</a>-<a href="#namedtupleenumdataclass">12</a></strong><br>
<strong>inline, <a href="#otheruses">11</a>-<a href="#namedtupleenumdataclass">12</a>, <a href="#inline-1">15</a>, <a href="#inline-2">20</a></strong><br>
<strong>input function, <a href="#input">22</a></strong><br> <strong>input function, <a href="#input">22</a></strong><br>
<strong>introspection, <a href="#introspection">31</a></strong><br> <strong>introspection, <a href="#introspection">31</a></strong><br>
<strong>ints, <a href="#abstractbaseclasses">4</a>, <a href="#types">7</a>, <a href="#binhex">8</a></strong><br>
<strong>ints, <a href="#abstractbaseclasses">4</a>, <a href="#ints">7</a>, <a href="#binhex">8</a>, <a href="#encode-1">28</a></strong><br>
<strong>is operator, <a href="#comparable">16</a></strong><br> <strong>is operator, <a href="#comparable">16</a></strong><br>
<strong>iterable, <a href="#abstractbaseclasses">4</a>, <a href="#iterable">18</a></strong><br> <strong>iterable, <a href="#abstractbaseclasses">4</a>, <a href="#iterable">18</a></strong><br>
<strong>iterator, <a href="#iterator">3</a>, <a href="#iterator-1">17</a></strong><br> <strong>iterator, <a href="#iterator">3</a>, <a href="#iterator-1">17</a></strong><br>

23
pdf/index_for_pdf_print.html

@ -7,7 +7,7 @@
<p><strong>abstract base classes, 4, 19</strong><br> <p><strong>abstract base classes, 4, 19</strong><br>
<strong>animation, 40, 42-43</strong><br> <strong>animation, 40, 42-43</strong><br>
<strong>argparse module, 22</strong><br> <strong>argparse module, 22</strong><br>
<strong>arguments, 10, 12</strong><br>
<strong>arguments, 10, 12, 22</strong><br>
<strong>arrays, 29, 37-38</strong><br> <strong>arrays, 29, 37-38</strong><br>
<strong>asyncio module, 33</strong><br> <strong>asyncio module, 33</strong><br>
<strong>audio, 40-41, 42</strong> </p> <strong>audio, 40-41, 42</strong> </p>
@ -21,18 +21,18 @@
<p><strong>cache, 13</strong><br> <p><strong>cache, 13</strong><br>
<strong>callable, 17</strong><br> <strong>callable, 17</strong><br>
<strong>class, 4, 14-19, 31-32</strong><br> <strong>class, 4, 14-19, 31-32</strong><br>
<strong>closure, 12</strong><br>
<strong>closure, 12-13</strong><br>
<strong>collection, 4, 18, 19</strong><br> <strong>collection, 4, 18, 19</strong><br>
<strong>collections module, 2, 3, 4, 19, 29</strong><br> <strong>collections module, 2, 3, 4, 19, 29</strong><br>
<strong>combinatorics, 8</strong><br> <strong>combinatorics, 8</strong><br>
<strong>command line arguments, 22</strong><br> <strong>command line arguments, 22</strong><br>
<strong>comparable, 16</strong><br> <strong>comparable, 16</strong><br>
<strong>comprehensions, 11</strong><br> <strong>comprehensions, 11</strong><br>
<strong>context manager, 17</strong><br>
<strong>context manager, 17, 23, 27, 30</strong><br>
<strong>copy function, 15</strong><br> <strong>copy function, 15</strong><br>
<strong>coroutine, 33</strong><br> <strong>coroutine, 33</strong><br>
<strong>counter, 2, 4, 12, 17</strong><br> <strong>counter, 2, 4, 12, 17</strong><br>
<strong>csv module, 26, 34, 46</strong><br>
<strong>csv, 26, 34, 46</strong><br>
<strong>curses module, 33, 34</strong><br> <strong>curses module, 33, 34</strong><br>
<strong>cython, 49</strong> </p> <strong>cython, 49</strong> </p>
<h3 id="d">D</h3> <h3 id="d">D</h3>
@ -40,13 +40,13 @@
<strong>datetime module, 8-9</strong><br> <strong>datetime module, 8-9</strong><br>
<strong>decorator, 13</strong><br> <strong>decorator, 13</strong><br>
<strong>deques, 29</strong><br> <strong>deques, 29</strong><br>
<strong>dictionaries, 2, 11</strong><br>
<strong>dictionaries, 2, 4, 11, 19, 21</strong><br>
<strong>duck types, 16-19</strong> </p> <strong>duck types, 16-19</strong> </p>
<h3 id="e">E</h3> <h3 id="e">E</h3>
<p><strong>enum module, 19-20</strong><br> <p><strong>enum module, 19-20</strong><br>
<strong>enumerate function, 3</strong><br> <strong>enumerate function, 3</strong><br>
<strong>eval function, 33</strong><br> <strong>eval function, 33</strong><br>
<strong>exceptions, 20-21, 23</strong> </p>
<strong>exceptions, 20-21, 23, 35</strong> </p>
<h3 id="f">F</h3> <h3 id="f">F</h3>
<p><strong>files, 23</strong><br> <p><strong>files, 23</strong><br>
<strong>filter function, 11</strong><br> <strong>filter function, 11</strong><br>
@ -56,16 +56,17 @@
<strong>futures, 30</strong> </p> <strong>futures, 30</strong> </p>
<h3 id="g">G</h3> <h3 id="g">G</h3>
<p><strong>generators, 4, 11</strong><br> <p><strong>generators, 4, 11</strong><br>
<strong>global keyword, 12</strong></p>
<strong>global keyword, 12</strong><br>
<strong>gui, 48</strong> </p>
<h3 id="h">H</h3> <h3 id="h">H</h3>
<p><strong>hashable, 16</strong><br>
<strong>hexadecimal representation, 8</strong> </p>
<p><strong>hashable, 15, 16</strong><br>
<strong>hexadecimal representation, 7, 8, 28</strong> </p>
<h3 id="i">I</h3> <h3 id="i">I</h3>
<p><strong>image, 39</strong><br> <p><strong>image, 39</strong><br>
<strong>inline, 11-12</strong><br>
<strong>inline, 11-12, 15, 20</strong><br>
<strong>input function, 22</strong><br> <strong>input function, 22</strong><br>
<strong>introspection, 31</strong><br> <strong>introspection, 31</strong><br>
<strong>ints, 4, 7, 8</strong><br>
<strong>ints, 4, 7, 8, 28</strong><br>
<strong>is operator, 16</strong><br> <strong>is operator, 16</strong><br>
<strong>iterable, 4, 18</strong><br> <strong>iterable, 4, 18</strong><br>
<strong>iterator, 3, 17</strong><br> <strong>iterator, 3, 17</strong><br>

Loading…
Cancel
Save