From 53a20416a035d5b4268026e27d19c87f6689741c Mon Sep 17 00:00:00 2001 From: adkinsrs Date: Mon, 9 Sep 2024 14:12:59 -0400 Subject: [PATCH 1/3] (#827) removing code that prevents reading analysis adata object --- www/api/resources/tsne_data.py | 7 ------- 1 file changed, 7 deletions(-) diff --git a/www/api/resources/tsne_data.py b/www/api/resources/tsne_data.py index 5dba0344..ecaf17f5 100644 --- a/www/api/resources/tsne_data.py +++ b/www/api/resources/tsne_data.py @@ -306,13 +306,6 @@ def post(self, dataset_id): if flip_y: adata.obsm[key][:,1] = -1 * adata.obsm[key][:,1] - # We also need to change the adata's Raw var dataframe - # We can't explicitly reset its index so we reinitialize it with - # the newer adata object. - # https://github.com/theislab/anndata/blob/master/anndata/base.py#L1020-L1022 - if adata.raw is not None: - adata.raw = adata - # Reorder the categorical values in the observation dataframe # Currently in UI only "plot_by_group" has reordering capabilities if order: From b7b9f562ed39ee4827c99560a314f75967d467ef Mon Sep 17 00:00:00 2001 From: adkinsrs Date: Mon, 9 Sep 2024 14:26:37 -0400 Subject: [PATCH 2/3] #883 - Fixed bug with invalid analysis ID retrieval --- www/js/curator_common.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/www/js/curator_common.js b/www/js/curator_common.js index edcc2294..f7ad226d 100644 --- a/www/js/curator_common.js +++ b/www/js/curator_common.js @@ -490,7 +490,7 @@ const analysisSelectUpdate = async () => { */ const chooseAnalysis = async () => { const analysisValue = analysisSelect.selectedOptions.length ? getSelect2Value(analysisSelect) : undefined; - const analysisId = (analysisValue && analysisValue > 0) ? analysisValue : null; + const analysisId = analysisValue || null; const analysisText = (analysisId?.length) ? analysisId : "Primary Analysis"; // Display current selected analysis From a4513fb98470aba8484fe87531dc75aec340bd1a Mon Sep 17 00:00:00 2001 From: adkinsrs Date: Mon, 9 Sep 2024 15:19:34 -0400 Subject: [PATCH 3/3] Fixing issue where tSNE params would reset after running --- www/js/classes/analysis.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/www/js/classes/analysis.js b/www/js/classes/analysis.js index ecfc00c3..69863bc9 100644 --- a/www/js/classes/analysis.js +++ b/www/js/classes/analysis.js @@ -1811,6 +1811,8 @@ class AnalysisSteptSNE { this.tsneCalculated = Boolean(computeTsne); this.umapCalculated = Boolean(computeUmap); this.genesToColor = document.querySelector(UI.tsneGenesToColorElt).value; + this.nNeighbors = document.querySelector(UI.dimReductionNNeighborsElt).value; + this.nPcs = document.querySelector(UI.tsneNPcsElt).value; this.plotTsne = plotTsne; this.plotUmap = plotUmap; this.updateUIWithResults();