From 19359413e69ac16dd952283083d90fb86d03f195 Mon Sep 17 00:00:00 2001 From: Leland McInnes Date: Wed, 24 Jan 2018 18:10:13 -0500 Subject: [PATCH] Random initialization should support arbitrary embedding dimension. --- umap/umap_.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/umap/umap_.py b/umap/umap_.py index 6803beac..0a7e98b7 100644 --- a/umap/umap_.py +++ b/umap/umap_.py @@ -1111,7 +1111,7 @@ def simplicial_set_embedding(graph, n_components, if isinstance(init, str) and init == 'random': embedding = random_state.uniform(low=-10.0, high=10.0, - size=(graph.shape[0], 2)) + size=(graph.shape[0], n_components)) elif isinstance(init, str) and init == 'spectral': # We add a little noise to avoid local minima for optimization to come initialisation = spectral_layout(graph, n_components, random_state)