I have this piece of code that I'm using in my doc2vec model
distance_matrix_doc = pairwise_distances(X_doc_subset, X_doc_subset, metric='cosine', n_jobs=-1)
tsne_doc = TSNE(metric="precomputed", n_components=2, verbose=1, perplexity=30, n_iter=500)
tsne_results_doc = tsne_doc.fit_transform(distance_matrix_doc)
after running it I am getting the following error:
ValueError: Found array with 0 sample(s) (shape=(0, 0)) while a minimum of 2 is required by TSNE.
What might be the problem and how do I correct it?