Skip to main content

openTSNE

Build Status Documentation Status Codacy Badge License Badge

openTSNE is a modular Python implementation of t-Distributed Stochasitc Neighbor Embedding (t-SNE) [1], a popular dimensionality-reduction algorithm for visualizing high-dimensional data sets. openTSNE incorporates the latest improvements to the t-SNE algorithm, including the ability to add new data points to existing embeddings [2], massive speed improvements [3] [4], enabling t-SNE to scale to millions of data points and various tricks to improve global alignment of the resulting visualizations [5].

Macosko 2015 mouse retina t-SNE embedding

A visualization of 44,808 single cell transcriptomes obtained from the mouse retina [6] embedded using the multiscale kernel trick to better preserve the global aligment of the clusters.

Installation

openTSNE requires Python 3.6 or higher in order to run.

Conda

openTSNE can be easily installed from conda-forge with

conda install --channel conda-forge opentsne

Conda package

PyPi

openTSNE is also available through pip and can be installed with

pip install opentsne

PyPi package

Installing from source

If you wish to install openTSNE from source, please run

python setup.py install

in the root directory to install the appropriate dependencies and compile the necessary binary files.

Please note that openTSNE requires a C/C++ compiler to be available on the system. Additionally, numpy must be pre-installed in the active environment.

In order for openTSNE to utilize multiple threads, the C/C++ compiler must support OpenMP. In practice, almost all compilers implement this with the exception of older version of clang on OSX systems.

To squeeze the most out of openTSNE, you may also consider installing FFTW3 prior to installation. FFTW3 implements the Fast Fourier Transform, which is heavily used in openTSNE. If FFTW3 is not available, openTSNE will use numpy’s implementation of the FFT, which is slightly slower than FFTW. The difference is only noticeable with large data sets containing millions of data points.

A hello world example

Getting started with openTSNE is very simple. First, we’ll load up some data using scikit-learn

from sklearn import datasets

iris = datasets.load_iris()
x, y = iris["data"], iris["target"]

then, we’ll import and run

from openTSNE import TSNE

embedding = TSNE().fit(x)

Citation

If you make use of openTSNE for your work we would appreciate it if you would cite the paper

@article {Poli{\v c}ar731877,
    author = {Poli{\v c}ar, Pavlin G. and Stra{\v z}ar, Martin and Zupan, Bla{\v z}},
    title = {openTSNE: a modular Python library for t-SNE dimensionality reduction and embedding},
    year = {2019},
    doi = {10.1101/731877},
    publisher = {Cold Spring Harbor Laboratory},
    URL = {https://www.biorxiv.org/content/early/2019/08/13/731877},
    eprint = {https://www.biorxiv.org/content/early/2019/08/13/731877.full.pdf},
    journal = {bioRxiv}
}

openTSNE implements two efficient algorithms for t-SNE. Please consider citing the original authors of the algorithm that you use. If you use FIt-SNE (default), then the citation is [4] below, but if you use Barnes-Hut the citation is [3].

References

Metadata

Release files for openTSNE 0.4.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for openTSNE 0.4.1
File Size Uploaded Provenance Actions
openTSNE-0.4.1.tar.gz 853.7 kB Without provenance Details for openTSNE-0.4.1.tar.gz

Built distributions (wheels)

Table of built distributions (wheels) for openTSNE 0.4.1
File Actions
openTSNE-0.4.1-cp37-cp37m-win_amd64.whl CPython 3.7 CPython 3.7 pymalloc Windows x86-64 Details for openTSNE-0.4.1-cp37-cp37m-win_amd64.whl
openTSNE-0.4.1-cp37-cp37m-manylinux1_x86_64.whl CPython 3.7 CPython 3.7 pymalloc Linux glibc 2.5+ x86-64 Details for openTSNE-0.4.1-cp37-cp37m-manylinux1_x86_64.whl
openTSNE-0.4.1-cp37-cp37m-macosx_10_13_x86_64.whl CPython 3.7 CPython 3.7 pymalloc macOS 10.13+ x86-64 Details for openTSNE-0.4.1-cp37-cp37m-macosx_10_13_x86_64.whl
openTSNE-0.4.1-cp36-cp36m-win_amd64.whl CPython 3.6 CPython 3.6 pymalloc Windows x86-64 Details for openTSNE-0.4.1-cp36-cp36m-win_amd64.whl
openTSNE-0.4.1-cp36-cp36m-manylinux1_x86_64.whl CPython 3.6 CPython 3.6 pymalloc Linux glibc 2.5+ x86-64 Details for openTSNE-0.4.1-cp36-cp36m-manylinux1_x86_64.whl
openTSNE-0.4.1-cp36-cp36m-macosx_10_13_x86_64.whl CPython 3.6 CPython 3.6 pymalloc macOS 10.13+ x86-64 Details for openTSNE-0.4.1-cp36-cp36m-macosx_10_13_x86_64.whl

Total release size: 5.4 MB

Release files / openTSNE-0.4.1.tar.gz

Download URL openTSNE-0.4.1.tar.gz
Size 853.7 kB
Tags Source
SHA-256 checksum
How to use checksums
850dbc82ab823fa4ad378ad37c4ad01e3e4c6b379226f6766c4d597c08b7919b
BLAKE2b-256 checksum
How to use checksums
622462996e052d545811cf063cd8ed287fe5eaa7ef38257a55e3d5e58c0eaa94
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.15.0 pkginfo/1.5.0.1 requests/2.23.0 setuptools/20.7.0 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/2.7.12

Release files / openTSNE-0.4.1-cp37-cp37m-win_amd64.whl

Download URL openTSNE-0.4.1-cp37-cp37m-win_amd64.whl
Size 384.5 kB
Tags CPython 3.7 CPython 3.7 pymalloc Windows x86-64
SHA-256 checksum
How to use checksums
7d9e9c77ea49220ab087a77c47036c81573b42fe961080ec7f940fac31a4fc5c
BLAKE2b-256 checksum
How to use checksums
4e62d9236edc2cb5aa3242a62a99f5cd56e8f000e00918c214b754ad7b99de34
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.15.0 pkginfo/1.5.0.1 requests/2.23.0 setuptools/20.7.0 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/2.7.12

Release files / openTSNE-0.4.1-cp37-cp37m-manylinux1_x86_64.whl

Download URL openTSNE-0.4.1-cp37-cp37m-manylinux1_x86_64.whl
Size 1.5 MB
Tags CPython 3.7 CPython 3.7 pymalloc Linux glibc 2.5+ x86-64
SHA-256 checksum
How to use checksums
b1de093da149eee5113aefc9a1212af5232cfd95850736ad3bd57199a4b0a954
BLAKE2b-256 checksum
How to use checksums
c988f989ebdea8368a40f7704c448c9c80dff73da8003a6a20367a844bd9da80
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.15.0 pkginfo/1.5.0.1 requests/2.23.0 setuptools/20.7.0 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/2.7.12

Release files / openTSNE-0.4.1-cp37-cp37m-macosx_10_13_x86_64.whl

Download URL openTSNE-0.4.1-cp37-cp37m-macosx_10_13_x86_64.whl
Size 404.6 kB
Tags CPython 3.7 CPython 3.7 pymalloc macOS 10.13+ x86-64
SHA-256 checksum
How to use checksums
3c040b7fb8906b9b42ec94da37ae3a15bf7fab625beeaf62672c11014d7e77a5
BLAKE2b-256 checksum
How to use checksums
a354c39106259f8eb212dbfaeb7042cc125812e6b85678b465de1fc4efc6eb21
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.15.0 pkginfo/1.5.0.1 requests/2.23.0 setuptools/20.7.0 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/2.7.12

Release files / openTSNE-0.4.1-cp36-cp36m-win_amd64.whl

Download URL openTSNE-0.4.1-cp36-cp36m-win_amd64.whl
Size 384.4 kB
Tags CPython 3.6 CPython 3.6 pymalloc Windows x86-64
SHA-256 checksum
How to use checksums
27dd0add84602ee7648d66118038e5d4e9f08c713b4ac4d3216f09362704c58b
BLAKE2b-256 checksum
How to use checksums
52491a8b4acbefc44034c870d2f27b5f824e59db16ca6f7c8fc1186de29b11db
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.15.0 pkginfo/1.5.0.1 requests/2.23.0 setuptools/20.7.0 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/2.7.12

Release files / openTSNE-0.4.1-cp36-cp36m-manylinux1_x86_64.whl

Download URL openTSNE-0.4.1-cp36-cp36m-manylinux1_x86_64.whl
Size 1.5 MB
Tags CPython 3.6 CPython 3.6 pymalloc Linux glibc 2.5+ x86-64
SHA-256 checksum
How to use checksums
177cdd441eb22867275809da2655a8ac364a7035b317abc8d29297947eb53d1a
BLAKE2b-256 checksum
How to use checksums
8e5583f1b5e32bd95488dd866480f603daefce87bfcaa63f8376c2315cd318f3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.15.0 pkginfo/1.5.0.1 requests/2.23.0 setuptools/20.7.0 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/2.7.12

Release files / openTSNE-0.4.1-cp36-cp36m-macosx_10_13_x86_64.whl

Download URL openTSNE-0.4.1-cp36-cp36m-macosx_10_13_x86_64.whl
Size 405.4 kB
Tags CPython 3.6 CPython 3.6 pymalloc macOS 10.13+ x86-64
SHA-256 checksum
How to use checksums
ad063e354bdb6875b3177e0d187e094c0cf00057bc93db81cf333b2e76269f26
BLAKE2b-256 checksum
How to use checksums
3ca79ee98c0fac91eb2bb33a286526009e14449ec50dfd3481a774d33630e071
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.15.0 pkginfo/1.5.0.1 requests/2.23.0 setuptools/20.7.0 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/2.7.12

Security for openTSNE 0.4.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page