add tsne optimizations