Files
cellxgene/docs/_site/posts/install.html
2020-07-29 12:38:46 -07:00

204 lines
8.8 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.6.1 -->
<title>Install | cellxgene</title>
<meta name="generator" content="Jekyll v3.8.7" />
<meta property="og:title" content="Install" />
<meta property="og:locale" content="en_US" />
<meta name="description" content="An interactive explorer for single-cell transcriptomics data" />
<meta property="og:description" content="An interactive explorer for single-cell transcriptomics data" />
<link rel="canonical" href="https://chanzuckerberg.github.io/cellxgene/posts/install.html" />
<meta property="og:url" content="https://chanzuckerberg.github.io/cellxgene/posts/install.html" />
<meta property="og:site_name" content="cellxgene" />
<script type="application/ld+json">
{"publisher":{"@type":"Organization","logo":{"@type":"ImageObject","url":"https://chanzuckerberg.github.io/cellxgene/cellxgene-logo.png"}},"url":"https://chanzuckerberg.github.io/cellxgene/posts/install.html","headline":"Install","description":"An interactive explorer for single-cell transcriptomics data","@type":"WebPage","@context":"https://schema.org"}</script>
<!-- End Jekyll SEO tag -->
<link rel="stylesheet" href="/cellxgene/assets/css/style.css?v=bbef27b8c9c0dc97e0fb70506c783e93683dae95">
<!--[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/cellxgene-logo.png" alt="cellxgene" />
<p>An interactive explorer for single-cell transcriptomics data</p>
<p>
<a href="/cellxgene/" class="btn">Quick start</a><br>
<a href="/cellxgene/posts/install" class="btn"><b>Installation</b></a><br>
<a href="/cellxgene/posts/gallery" class="btn">Gallery</a><br>
<a href="/cellxgene/posts/demo-data" class="btn">Demo datasets</a><br>
<a href="/cellxgene/posts/prepare" class="btn">Preparing your data</a><br>
<a href="/cellxgene/posts/launch" class="btn">Launching cellxgene</a><br>
<a href="/cellxgene/posts/hosted" class="btn">Hosting cellxgene</a><br>
<a href="/cellxgene/posts/annotations" class="btn">Annotating data</a><br>
<a href="/cellxgene/posts/methods" class="btn">Methods</a><br>
<a href="/cellxgene/posts/troubleshooting" class="btn">Troubleshooting</a><br>
<a href="/cellxgene/posts/roadmap" class="btn">Roadmap</a><br>
<a href="/cellxgene/posts/contribute" class="btn">Contributing (ideas or code)</a><br>
<a href="/cellxgene/posts/contact" class="btn">Contact & finding help</a><br>
<a href="/cellxgene/posts/cellxgene_cziscience_com" class="btn">cellxgene.cziscience.com</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="language-plaintext highlighter-rouge">cellxgene</code></a> is the main explorer application, which takes an already-processed <code class="language-plaintext highlighter-rouge">h5ad</code> file as input. This is installed by default.</li>
<li><a href="prepare"><code class="language-plaintext 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="language-plaintext highlighter-rouge">cellxgene</code> explorer alone, run:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>pip install cellxgene
</code></pre></div></div>
<p>To install <code class="language-plaintext highlighter-rouge">cellxgene</code> and the optional <code class="language-plaintext highlighter-rouge">cellxgene prepare</code>, run:</p>
<div class="language-plaintext 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="language-plaintext highlighter-rouge">prepare</code> package installation fails, you can also install these packages directly:</em></p>
<div class="language-plaintext 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="language-plaintext 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="language-plaintext highlighter-rouge">cellxgene</code> installed, you can update to the most recent version by running:</p>
<div class="language-plaintext 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="language-plaintext highlighter-rouge">cellxgene</code> alone, run:</p>
<div class="language-plaintext 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="language-plaintext highlighter-rouge">cellxgene</code> and the optional <code class="language-plaintext highlighter-rouge">cellxgene prepare</code>, run:</p>
<div class="language-plaintext 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="language-plaintext highlighter-rouge">cellxgene</code> alone, run:</p>
<div class="language-plaintext 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="language-plaintext highlighter-rouge">cellxgene</code> and <code class="language-plaintext highlighter-rouge">cellxgene prepare</code>, run:</p>
<div class="language-plaintext 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="language-plaintext 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="language-plaintext highlighter-rouge">--port</code> and <code class="language-plaintext highlighter-rouge">--host</code> parameters as needed)</p>
<div class="language-plaintext 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="language-plaintext 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="/cellxgene/assets/js/scale.fix.js"></script>
</body>
</html>