Skip to content

Commit

Permalink
Deploy preview for PR 344 🛫
Browse files Browse the repository at this point in the history
  • Loading branch information
Zethson committed Mar 9, 2025
1 parent f633a3e commit dd06d1f
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@
"`````\n",
"``````\n",
"\n",
"````{dropdown} Access to data and notebook\n",
"````{dropdown} <i class=\"fa-solid fa-database\"></i>&nbsp;&nbsp;&nbsp;Access to data and notebook\n",
"```{include} ../_static/default_text_lamindb_setup.md\n",
"```\n",
"````"
Expand Down
6 changes: 4 additions & 2 deletions pr-preview/pr-344/_static/default_text_lamindb_setup.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,11 +41,12 @@ We acknowledge free hosting from [Lamin Labs](https://lamin.ai/).

```python
import lamindb as ln
af = ln.Artifact.get(key="key_of_dataset", is_latest=True)
af = ln.Artifact.get(key="key_of_dataset", is_latest=True) # or ln.Artifact("SOMEID").get()
obj = af.load()
```

The object is now accessible in memory and is ready for analysis.
Adapt the `ln.Artifact("SOMEID").get()` suffix to get older versions like `ln.Artifact("SOMEID0001").get()` to get the second uploaded version.

6. **Accessing notebooks (Transforms)**

Expand All @@ -57,7 +58,8 @@ We acknowledge free hosting from [Lamin Labs](https://lamin.ai/).
```

which will download the notebook to the current working directory.
Analogously to `Artifacts`, you can adapt the suffix ID to get older versions.

7. \*\*On `ln.track()` and `ln.finish()`
7. **On `ln.track()` and `ln.finish()`**

- These functions are currently only available for users with write access and may error. Please comment them out for now.
2 changes: 1 addition & 1 deletion pr-preview/pr-344/searchindex.js

Large diffs are not rendered by default.

12 changes: 7 additions & 5 deletions pr-preview/pr-344/trajectories/pseudotemporal.html
Original file line number Diff line number Diff line change
Expand Up @@ -601,7 +601,7 @@ <h1><span class="section-number">13. </span>Pseudotemporal ordering<a class="hea
</div>
</details><details class="sd-sphinx-override sd-dropdown sd-card sd-mb-3">
<summary class="sd-summary-title sd-card-header">
<span class="sd-summary-text">Access to data and notebook</span><span class="sd-summary-state-marker sd-summary-chevron-right"><svg version="1.1" width="1.5em" height="1.5em" class="sd-octicon sd-octicon-chevron-right" viewBox="0 0 24 24" aria-hidden="true"><path d="M8.72 18.78a.75.75 0 0 1 0-1.06L14.44 12 8.72 6.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018l6.25 6.25a.75.75 0 0 1 0 1.06l-6.25 6.25a.75.75 0 0 1-1.06 0Z"></path></svg></span></summary><div class="sd-summary-content sd-card-body docutils">
<span class="sd-summary-text"><i class="fa-solid fa-database"></i>   Access to data and notebook</span><span class="sd-summary-state-marker sd-summary-chevron-right"><svg version="1.1" width="1.5em" height="1.5em" class="sd-octicon sd-octicon-chevron-right" viewBox="0 0 24 24" aria-hidden="true"><path d="M8.72 18.78a.75.75 0 0 1 0-1.06L14.44 12 8.72 6.28a.751.751 0 0 1 .018-1.042.751.751 0 0 1 1.042-.018l6.25 6.25a.75.75 0 0 1 0 1.06l-6.25 6.25a.75.75 0 0 1-1.06 0Z"></path></svg></span></summary><div class="sd-summary-content sd-card-body docutils">
<p class="sd-card-text">This book uses <a class="reference external" href="https://github.com/laminlabs/lamindb">lamindb</a> to store, share, and load datasets and notebooks using the <a class="reference external" href="https://lamin.ai/theislab/sc-best-practices">theislab/sc-best-practices instance</a>.
We acknowledge free hosting from <a class="reference external" href="https://lamin.ai/">Lamin Labs</a>.</p>
<ol class="arabic simple">
Expand Down Expand Up @@ -649,11 +649,12 @@ <h1><span class="section-number">13. </span>Pseudotemporal ordering<a class="hea
<li><p class="sd-card-text">Load an Artifact and the corresponding object:</p></li>
</ul>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="kn">import</span><span class="w"> </span><span class="nn">lamindb</span><span class="w"> </span><span class="k">as</span><span class="w"> </span><span class="nn">ln</span>
<span class="n">af</span> <span class="o">=</span> <span class="n">ln</span><span class="o">.</span><span class="n">Artifact</span><span class="o">.</span><span class="n">get</span><span class="p">(</span><span class="n">key</span><span class="o">=</span><span class="s2">&quot;key_of_dataset&quot;</span><span class="p">,</span> <span class="n">is_latest</span><span class="o">=</span><span class="kc">True</span><span class="p">)</span>
<span class="n">af</span> <span class="o">=</span> <span class="n">ln</span><span class="o">.</span><span class="n">Artifact</span><span class="o">.</span><span class="n">get</span><span class="p">(</span><span class="n">key</span><span class="o">=</span><span class="s2">&quot;key_of_dataset&quot;</span><span class="p">,</span> <span class="n">is_latest</span><span class="o">=</span><span class="kc">True</span><span class="p">)</span> <span class="c1"># or ln.Artifact(&quot;SOMEID&quot;).get()</span>
<span class="n">obj</span> <span class="o">=</span> <span class="n">af</span><span class="o">.</span><span class="n">load</span><span class="p">()</span>
</pre></div>
</div>
<p class="sd-card-text">The object is now accessible in memory and is ready for analysis.</p>
<p class="sd-card-text">The object is now accessible in memory and is ready for analysis.
Adapt the <code class="docutils literal notranslate"><span class="pre">ln.Artifact(&quot;SOMEID&quot;).get()</span></code> suffix to get older versions like <code class="docutils literal notranslate"><span class="pre">ln.Artifact(&quot;SOMEID0001&quot;).get()</span></code> to get the second uploaded version.</p>
</li>
<li><p class="sd-card-text"><strong>Accessing notebooks (Transforms)</strong></p>
<ul class="simple">
Expand All @@ -663,9 +664,10 @@ <h1><span class="section-number">13. </span>Pseudotemporal ordering<a class="hea
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>lamin<span class="w"> </span>load<span class="w"> </span>&lt;notebook<span class="w"> </span>url&gt;
</pre></div>
</div>
<p class="sd-card-text">which will download the notebook to the current working directory.</p>
<p class="sd-card-text">which will download the notebook to the current working directory.
Analogously to <code class="docutils literal notranslate"><span class="pre">Artifacts</span></code>, you can adapt the suffix ID to get older versions.</p>
</li>
<li><p class="sd-card-text">**On <code class="docutils literal notranslate"><span class="pre">ln.track()</span></code> and <code class="docutils literal notranslate"><span class="pre">ln.finish()</span></code></p>
<li><p class="sd-card-text"><strong>On <code class="docutils literal notranslate"><span class="pre">ln.track()</span></code> and <code class="docutils literal notranslate"><span class="pre">ln.finish()</span></code></strong></p>
<ul class="simple">
<li><p class="sd-card-text">These functions are currently only available for users with write access and may error. Please comment them out for now.</p></li>
</ul>
Expand Down

0 comments on commit dd06d1f

Please sign in to comment.