From 6cfa0ddd7f5774bf0044edfe390ea0efc37301e7 Mon Sep 17 00:00:00 2001 From: "avanti.shrikumar" Date: Sat, 27 Jan 2024 12:24:58 +1100 Subject: [PATCH] fix for issue 112 --- modisco/core.py | 2 +- setup.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/modisco/core.py b/modisco/core.py index af476ae..9886ee0 100644 --- a/modisco/core.py +++ b/modisco/core.py @@ -774,7 +774,7 @@ def compute_subclusters_and_embedding(self, pattern_comparison_settings, distmat_sp.sort_indices() if (compute_embedding): twod_embedding = sklearn.manifold.TSNE( - perplexity=perplexity, + perplexity=min(perplexity, distmat_sp.shape[0]), metric='precomputed', init="random", verbose=3, random_state=1234).fit_transform(distmat_sp) diff --git a/setup.py b/setup.py index 24273fc..ec33249 100644 --- a/setup.py +++ b/setup.py @@ -6,7 +6,7 @@ description='TF MOtif Discovery from Importance SCOres', long_description="""Algorithm for discovering consolidated patterns from base-pair-level importance scores""", url='https://github.com/kundajelab/tfmodisco', - version='0.5.16.3', + version='0.5.16.4', packages=find_packages(), package_data={ '': ['cluster/phenograph/louvain/*convert*', 'cluster/phenograph/louvain/*community*', 'cluster/phenograph/louvain/*hierarchy*']