Files
cellxgene/docs/_site/posts/install.html
2019-11-22 14:59:40 -08:00

198 lines
7.6 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<!DOCTYPE html>
<html lang="en-US">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<!-- Begin Jekyll SEO tag v2.5.0 -->
<title>Install | cellxgene</title>
<meta name="generator" content="Jekyll v3.8.5" />
<meta property="og:title" content="Install" />
<meta property="og:locale" content="en_US" />
<link rel="canonical" href="http://localhost:4000/posts/install.html" />
<meta property="og:url" content="http://localhost:4000/posts/install.html" />
<meta property="og:site_name" content="cellxgene" />
<script type="application/ld+json">
{"publisher":{"@type":"Organization","logo":{"@type":"ImageObject","url":"http://localhost:4000/cellxgene-logo.png"}},"@type":"WebPage","url":"http://localhost:4000/posts/install.html","headline":"Install","@context":"http://schema.org"}</script>
<!-- End Jekyll SEO tag -->
<link rel="stylesheet" href="/assets/css/style.css?v=be9a415a4a06db270354d81837f6e78c71555064">
<!--[if lt IE 9]>
<script src="https://cdnjs.cloudflare.com/ajax/libs/html5shiv/3.7.3/html5shiv.min.js"></script>
<![endif]-->
</head>
<body>
<div class="wrapper">
<header>
<img src="/cellxgene-logo.png" alt="cellxgene" />
<p></p>
<p>
<a href="/" class="btn">Quick start</a><br>
<a href="/posts/install" class="btn"><b>Installation</b></a><br>
<a href="/posts/gallery" class="btn">Gallery</a><br>
<a href="/posts/demo-data" class="btn">Demo datasets</a><br>
<a href="/posts/prepare" class="btn">Preparing your data</a><br>
<a href="/posts/launch" class="btn">Launching cellxgene</a><br>
<a href="/posts/hosted" class="btn">Hosting cellxgene</a><br>
<a href="/posts/annotations" class="btn">Annotating data</a><br>
<a href="/posts/methods" class="btn">Methods</a><br>
<a href="/posts/troubleshooting" class="btn">Troubleshooting</a><br>
<a href="/posts/roadmap" class="btn">Roadmap</a><br>
<a href="/posts/contribute" class="btn">Contributing (ideas or code)</a><br>
<a href="/posts/contact" class="btn">Contact & finding help</a><br>
<a href="https://github.com/chanzuckerberg/cellxgene" class="btn" target="_blank">Code</a>
</p>
</header>
<section>
<h1 id="installing-cellxgene">Installing cellxgene</h1>
<p>Cellxgene has two parts:</p>
<ul>
<li><a href="launch"><code class="highlighter-rouge">cellxgene</code></a> is the main explorer application, which takes an already-processed <code class="highlighter-rouge">h5ad</code> file as input. This is installed by default.</li>
<li><a href="prepare"><code class="highlighter-rouge">cellxgene prepare</code></a> provides auxiliary functionality for preparing your dataset. This is <em>not</em> installed by default.</li>
</ul>
<h2 id="requirements">Requirements</h2>
<p>Youll need <strong>python 3.6+</strong> and an up-to-date version of <strong>Google Chrome</strong>.
The web UI is tested on OSX and Windows using Chrome, and the python CLI is tested on OSX and Ubuntu (via WSL/Windows).
It should work on other platforms, but if you run into trouble let us know.</p>
<p><a href="https://www.python.org/downloads/">Python.org</a> has help on installing a recent
version of Python, including the pip package manager. Chrome is available at
<a href="https://google.com/chrome">Google.com/chrome</a>.</p>
<h2 id="basic-install-using-pip">Basic install using pip</h2>
<p>To install the <code class="highlighter-rouge">cellxgene</code> explorer alone, run:</p>
<div class="highlighter-rouge"><div class="highlight"><pre class="highlight"><code>pip install cellxgene
</code></pre></div></div>
<p>To install <code class="highlighter-rouge">cellxgene</code> and the optional <code class="highlighter-rouge">cellxgene prepare</code>, run:</p>
<div class="highlighter-rouge"><div class="highlight"><pre class="highlight"><code>pip install cellxgene[prepare]
</code></pre></div></div>
<p><em>Note: if the aforementioned optional <code class="highlighter-rouge">prepare</code> package installation fails, you can also install these packages directly:</em></p>
<div class="highlighter-rouge"><div class="highlight"><pre class="highlight"><code>pip install scanpy&gt;=1.3.7 python-igraph louvain&gt;=0.6
</code></pre></div></div>
<p><em>On various Linux platforms, you may also need to install build dependencies first:</em></p>
<div class="highlighter-rouge"><div class="highlight"><pre class="highlight"><code>sudo apt-get install build-essential python-dev
pip install scanpy&gt;=1.3.7 python-igraph louvain&gt;=0.6
</code></pre></div></div>
<p>If you already have <code class="highlighter-rouge">cellxgene</code> installed, you can update to the most recent version by running:</p>
<div class="highlighter-rouge"><div class="highlight"><pre class="highlight"><code>pip install cellxgene --upgrade
</code></pre></div></div>
<h2 id="using-a-conda-environment">Using a conda environment</h2>
<p>To install <code class="highlighter-rouge">cellxgene</code> alone, run:</p>
<div class="highlighter-rouge"><div class="highlight"><pre class="highlight"><code>conda create --yes -n cellxgene python=3.7
conda activate cellxgene
pip install cellxgene
</code></pre></div></div>
<p>To install <code class="highlighter-rouge">cellxgene</code> and the optional <code class="highlighter-rouge">cellxgene prepare</code>, run:</p>
<div class="highlighter-rouge"><div class="highlight"><pre class="highlight"><code>conda create --yes -n cellxgene python=3.7
conda activate cellxgene
pip install cellxgene[prepare]
</code></pre></div></div>
<h2 id="using-a-virtual-environment">Using a virtual environment</h2>
<p>To install <code class="highlighter-rouge">cellxgene</code> alone, run:</p>
<div class="highlighter-rouge"><div class="highlight"><pre class="highlight"><code>ENV_NAME=cellxgene
python3.7 -m venv ${ENV_NAME}
source ${ENV_NAME}/bin/activate
pip install cellxgene
</code></pre></div></div>
<p>To install <code class="highlighter-rouge">cellxgene</code> and <code class="highlighter-rouge">cellxgene prepare</code>, run:</p>
<div class="highlighter-rouge"><div class="highlight"><pre class="highlight"><code>ENV_NAME=cellxgene
python3.7 -m venv ${ENV_NAME}
source ${ENV_NAME}/bin/activate
pip install cellxgene[prepare]
</code></pre></div></div>
<h2 id="using-docker">Using docker</h2>
<p>Build the image</p>
<div class="highlighter-rouge"><div class="highlight"><pre class="highlight"><code>docker build . -t cellxgene
</code></pre></div></div>
<p>Run the container and mount data (change data location, <code class="highlighter-rouge">--port</code> and <code class="highlighter-rouge">--host</code> parameters as needed)</p>
<div class="highlighter-rouge"><div class="highlight"><pre class="highlight"><code>docker run -v "$PWD/example-dataset/:/data/" -p 5005:5005 cellxgene launch --host 0.0.0.0 data/pbmc3k.h5ad
</code></pre></div></div>
<p>You will need to use <code class="highlighter-rouge">--host 0.0.0.0</code> to have the container listen to incoming requests from the browser</p>
</section>
<footer>
<p>This project is maintained by <a href="https://github.com/chanzuckerberg">chanzuckerberg</a></p>
</footer>
</div>
<script src="/assets/js/scale.fix.js"></script>
</body>
</html>