Coder Social home page Coder Social logo

tsne's Introduction

Python-TSNE

Python library containing T-SNE algorithms, with significant performance improvement over the original projects from which this fork was created.

Note: Scikit-learn v0.17 includes TSNE algorithms and you should probably be using them instead of this.

Algorithms

Barnes-Hut-SNE

A python (cython) wrapper for Barnes-Hut-SNE aka fast-tsne.

I basically took osdf's code and made it pip compliant.

Requirements

Installation

You can install the package from the Github repository:

pip install git+https://github.com/rappdw/tsne.git

Or using docker (to build a wheel for linux):

$ bin/build-image jenkins
$ bin/run-image jenkins
$ (in container) python setup.py bdist_wheel

# This will generate a wheel in your project's dist directory

Or on OSX

First install gcc (for openmp support) via: brew install gcc --without-multilib. Then install CMake. Once that's in place you can run pip or setup.py to build a wheel or install locally, e.g.

  • export PATH="/Applications/CMake.app/Contents/bin/:$PATH"; export CC=/usr/local/bin/gcc-6; export CXX=/usr/local/bin/g++-6; python setup.py bdist_wheel
  • export PATH="/Applications/CMake.app/Contents/bin/:$PATH"; export CXX=/usr/local/bin/g++-6; export CC=/usr/local/bin/gcc-6; pip install -e .

Usage

Basic usage:

from tsne import bh_sne
X_2d = bh_sne(X)

Or, the wheels also contain an executable that can be used from the command-line as described in the original project.

Examples

More Information

See Barnes-Hut-SNE (2013), L.J.P. van der Maaten. It is available on arxiv.

Mulit-core

see: Python 3 - Multicore

Performance

This fork of the orignal project has a number of performance improvements resulting in an order of magnitude performance improvement when running on multi-core systems. See tsne-pref-test for performance comparisions of various branches of BH-t-SNE.

tsne's People

Contributors

danielfrg avatar osdf avatar pryvkin10x avatar rappdw avatar mattsooknah avatar elliottd avatar bayerj avatar rjrico10x avatar mschubert avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.