Skip to content

Commit

Permalink
deploy: 5d81141
Browse files Browse the repository at this point in the history
  • Loading branch information
isabelizimm committed Oct 30, 2023
1 parent 3d9e200 commit 05e0162
Show file tree
Hide file tree
Showing 4 changed files with 253 additions and 253 deletions.
6 changes: 3 additions & 3 deletions customize-pins-metadata.html
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ <h1>A function to store pandas Categoricals</h1>
<div class="cell-output cell-output-stderr">
<pre><code>Writing pin:
Name: 'some-cat'
Version: 20231011T123651Z-6ce8e</code></pre>
Version: 20231030T164651Z-6ce8e</code></pre>
</div>
</div>
<section id="a-function-to-read-categoricals" class="level2">
Expand All @@ -241,13 +241,13 @@ <h2 class="anchored" data-anchor-id="a-function-to-read-categoricals">A function
<div class="cell-output cell-output-stdout">
<pre><code>Meta(title='some-cat: a pinned list object',
description=None,
created='20231011T123651Z',
created='20231030T164651Z',
pin_hash='6ce8eaa9de0dfd54',
file='some-cat.json',
file_size=20,
type='json',
api_version=1,
version=Version(created=datetime.datetime(2023, 10, 11, 12, 36, 51),
version=Version(created=datetime.datetime(2023, 10, 30, 16, 46, 51),
hash='6ce8e'),
tags=None,
name='some-cat',
Expand Down
30 changes: 15 additions & 15 deletions get_started.html
Original file line number Diff line number Diff line change
Expand Up @@ -208,7 +208,7 @@ <h2 class="anchored" data-anchor-id="reading-and-writing-data">Reading and writi
<div class="cell-output cell-output-stderr">
<pre><code>Writing pin:
Name: 'mtcars'
Version: 20231011T123656Z-3b134</code></pre>
Version: 20231030T164634Z-3b134</code></pre>
</div>
</div>
<p>The first argument is the object to save (usually a data frame, but it can be any Python object), and the second argument gives the “name” of the pin. The name is basically equivalent to a file name; you’ll use it when you later want to read the data from the pin. The only rule for a pin name is that it can’t contain slashes.</p>
Expand Down Expand Up @@ -428,7 +428,7 @@ <h2 class="anchored" data-anchor-id="metadata">Metadata</h2>
<div class="cell" data-execution_count="6">
<div class="sourceCode cell-code" id="cb7"><pre class="sourceCode python code-with-copy"><code class="sourceCode python"><span id="cb7-1"><a href="#cb7-1" aria-hidden="true" tabindex="-1"></a>board.pin_meta(<span class="st">"mtcars"</span>)</span></code><button title="Copy to Clipboard" class="code-copy-button"><i class="bi"></i></button></pre></div>
<div class="cell-output cell-output-display" data-execution_count="6">
<pre><code>Meta(title='mtcars: a pinned 32 x 11 DataFrame', description=None, created='20231011T123656Z', pin_hash='3b134bae183b50c9', file='mtcars.csv', file_size=1333, type='csv', api_version=1, version=Version(created=datetime.datetime(2023, 10, 11, 12, 36, 56), hash='3b134'), tags=None, name='mtcars', user={}, local={})</code></pre>
<pre><code>Meta(title='mtcars: a pinned 32 x 11 DataFrame', description=None, created='20231030T164634Z', pin_hash='3b134bae183b50c9', file='mtcars.csv', file_size=1333, type='csv', api_version=1, version=Version(created=datetime.datetime(2023, 10, 30, 16, 46, 34), hash='3b134'), tags=None, name='mtcars', user={}, local={})</code></pre>
</div>
</div>
<p>This shows you the metadata that’s generated by default. This includes:</p>
Expand All @@ -453,16 +453,16 @@ <h2 class="anchored" data-anchor-id="metadata">Metadata</h2>
<div class="cell-output cell-output-stderr">
<pre><code>Writing pin:
Name: 'mtcars2'
Version: 20231011T123656Z-3b134</code></pre>
Version: 20231030T164634Z-3b134</code></pre>
</div>
<div class="cell-output cell-output-display" data-execution_count="7">
<pre><code>Meta(title='mtcars2: a pinned 32 x 11 DataFrame', description='Data extracted from the 1974 Motor Trend US magazine, and comprises fuel consumption and 10 aspects of automobile design and performance for 32 automobiles (1973–74 models).', created='20231011T123656Z', pin_hash='3b134bae183b50c9', file='mtcars2.csv', file_size=1333, type='csv', api_version=1, version=Version(created=datetime.datetime(2023, 10, 11, 12, 36, 56, 204841), hash='3b134bae183b50c9'), tags=None, name='mtcars2', user={'source': 'Henderson and Velleman (1981), Building multiple regression models interactively. Biometrics, 37, 391–411.'}, local={})</code></pre>
<pre><code>Meta(title='mtcars2: a pinned 32 x 11 DataFrame', description='Data extracted from the 1974 Motor Trend US magazine, and comprises fuel consumption and 10 aspects of automobile design and performance for 32 automobiles (1973–74 models).', created='20231030T164634Z', pin_hash='3b134bae183b50c9', file='mtcars2.csv', file_size=1333, type='csv', api_version=1, version=Version(created=datetime.datetime(2023, 10, 30, 16, 46, 34, 543352), hash='3b134bae183b50c9'), tags=None, name='mtcars2', user={'source': 'Henderson and Velleman (1981), Building multiple regression models interactively. Biometrics, 37, 391–411.'}, local={})</code></pre>
</div>
</div>
<div class="cell" data-execution_count="8">
<div class="sourceCode cell-code" id="cb12"><pre class="sourceCode python code-with-copy"><code class="sourceCode python"><span id="cb12-1"><a href="#cb12-1" aria-hidden="true" tabindex="-1"></a>board.pin_meta(<span class="st">"mtcars"</span>)</span></code><button title="Copy to Clipboard" class="code-copy-button"><i class="bi"></i></button></pre></div>
<div class="cell-output cell-output-display" data-execution_count="8">
<pre><code>Meta(title='mtcars: a pinned 32 x 11 DataFrame', description=None, created='20231011T123656Z', pin_hash='3b134bae183b50c9', file='mtcars.csv', file_size=1333, type='csv', api_version=1, version=Version(created=datetime.datetime(2023, 10, 11, 12, 36, 56), hash='3b134'), tags=None, name='mtcars', user={}, local={})</code></pre>
<pre><code>Meta(title='mtcars: a pinned 32 x 11 DataFrame', description=None, created='20231030T164634Z', pin_hash='3b134bae183b50c9', file='mtcars.csv', file_size=1333, type='csv', api_version=1, version=Version(created=datetime.datetime(2023, 10, 30, 16, 46, 34), hash='3b134'), tags=None, name='mtcars', user={}, local={})</code></pre>
</div>
</div>
<p>While we’ll do our best to keep the automatically generated metadata consistent over time, I’d recommend manually capturing anything you really care about in metadata.</p>
Expand All @@ -479,13 +479,13 @@ <h2 class="anchored" data-anchor-id="versioning">Versioning</h2>
<div class="cell-output cell-output-stderr">
<pre><code>Writing pin:
Name: 'x'
Version: 20231011T123656Z-2bc5d
Version: 20231030T164634Z-2bc5d
Writing pin:
Name: 'x'
Version: 20231011T123656Z-c24c0
Version: 20231030T164634Z-c24c0
Writing pin:
Name: 'x'
Version: 20231011T123656Z-91d9a</code></pre>
Version: 20231030T164634Z-91d9a</code></pre>
</div>
<div class="cell-output cell-output-display" data-execution_count="9">
<div>
Expand All @@ -503,21 +503,21 @@ <h2 class="anchored" data-anchor-id="versioning">Versioning</h2>
<tbody>
<tr class="odd">
<td data-quarto-table-cell-role="th">0</td>
<td>2023-10-11 12:36:56</td>
<td>2023-10-30 16:46:34</td>
<td>2bc5d</td>
<td>20231011T123656Z-2bc5d</td>
<td>20231030T164634Z-2bc5d</td>
</tr>
<tr class="even">
<td data-quarto-table-cell-role="th">1</td>
<td>2023-10-11 12:36:56</td>
<td>2023-10-30 16:46:34</td>
<td>91d9a</td>
<td>20231011T123656Z-91d9a</td>
<td>20231030T164634Z-91d9a</td>
</tr>
<tr class="odd">
<td data-quarto-table-cell-role="th">2</td>
<td>2023-10-11 12:36:56</td>
<td>2023-10-30 16:46:34</td>
<td>c24c0</td>
<td>20231011T123656Z-c24c0</td>
<td>20231030T164634Z-c24c0</td>
</tr>
</tbody>
</table>
Expand Down Expand Up @@ -579,7 +579,7 @@ <h2 class="anchored" data-anchor-id="storing-models">Storing models</h2>
<div class="cell-output cell-output-stderr">
<pre><code>Writing pin:
Name: 'my_coords'
Version: 20231011T123656Z-d5e4a</code></pre>
Version: 20231030T164634Z-d5e4a</code></pre>
</div>
<div class="cell-output cell-output-display" data-execution_count="13">
<pre><code>Coords(x=1, y=2)</code></pre>
Expand Down
4 changes: 2 additions & 2 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -206,10 +206,10 @@ <h2 class="anchored" data-anchor-id="usage">Usage</h2>
<div class="cell-output cell-output-stderr">
<pre><code>Writing pin:
Name: 'mtcars'
Version: 20231011T123708Z-120a5</code></pre>
Version: 20231030T164628Z-120a5</code></pre>
</div>
<div class="cell-output cell-output-display" data-execution_count="2">
<pre><code>Meta(title='mtcars: a pinned 5 x 11 DataFrame', description=None, created='20231011T123708Z', pin_hash='120a54f7e0818041', file='mtcars.csv', file_size=249, type='csv', api_version=1, version=Version(created=datetime.datetime(2023, 10, 11, 12, 37, 8, 599286), hash='120a54f7e0818041'), tags=None, name='mtcars', user={}, local={})</code></pre>
<pre><code>Meta(title='mtcars: a pinned 5 x 11 DataFrame', description=None, created='20231030T164628Z', pin_hash='120a54f7e0818041', file='mtcars.csv', file_size=249, type='csv', api_version=1, version=Version(created=datetime.datetime(2023, 10, 30, 16, 46, 28, 130371), hash='120a54f7e0818041'), tags=None, name='mtcars', user={}, local={})</code></pre>
</div>
</div>
<p>Above, we saved the data as a CSV, but depending on what you’re saving and who else you want to read it, you might use the <code>type</code> argument to instead save it as a <code>joblib</code>, <code>parquet</code>, or <code>json</code> file.</p>
Expand Down
Loading

0 comments on commit 05e0162

Please sign in to comment.