Fast t-SNE using CUDA

T-SNE evaluation is sometime quite slow, in the order of minutes for relatively small datasets. Fortunately, Chan et al. have written a GPU base implementation of T-SNE that can be used as a drop-in replacement for the one provided by sklearn.

Installation is a bit tricky though. Here is a method that works! First, create a conda environment for Python 3.6.

conda create -n py36 python=3.6
conda activate py36

Then install CUDA Toolkit version 10.1 (The package does not support more recent version as of January 7, 2021.)

conda install cudatoolkit=10.1

Then, install tsne-cuda as explained in their installation instructions.

conda install tsnecuda cuda101 -c cannylab

You can then install whatever package required for your needs in that environment.