Skip to content

Commit

Permalink
Bugfix
Browse files Browse the repository at this point in the history
  • Loading branch information
pedrofale committed Apr 28, 2024
1 parent 5a0bdcc commit 44cd13f
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions scatrex/scatrex.py
Original file line number Diff line number Diff line change
Expand Up @@ -389,7 +389,7 @@ def update_anndata(self, adata):
adata.layers["scatrex_mean"] = mean_mat

def learn(self, adata, observed_tree=None, counts_layer='counts', allow_subtrees=True, allow_root_subtrees=False, root_cells=None,
batch_size=None, seed=42, weights_concentration=1e6, update_outer_ass=False,
batch_size=None, seed=42, weights_variance=1., update_outer_ass=False,
n_epochs=100, mc_samples=10, step_size=0.01, n_iters=10, n_merges=10, n_swaps=10, memoized=True, dp_alpha=.1, dp_gamma=.1):
"""
Complete NTSSB learning procedure.
Expand All @@ -401,7 +401,7 @@ def learn(self, adata, observed_tree=None, counts_layer='counts', allow_subtrees
self.ntssb = NTSSB(self.observed_tree,
node_hyperparams=self.model_args,
seed=seed,
weights_concentration=weights_concentration)
weights_variance=weights_variance)
self.ntssb.add_data(np.array(adata.layers[counts_layer]))
self.ntssb.make_batches(batch_size, seed)
self.ntssb.reset_variational_parameters()
Expand Down Expand Up @@ -1098,7 +1098,7 @@ def plot_tree(
mapper = self.ntssb.gene_node_colormaps[kwargs["genemode"]][
"mapper"
][gene_pos]
cbar = plt.colorbar(mapper, label=cbtitle)
cbar = plt.colorbar(mapper, ax=g, label=cbtitle)
if kwargs["genemode"] == "observed":
n_discrete_levels = self.ntssb.gene_node_colormaps["observed"][
"mapper"
Expand Down

0 comments on commit 44cd13f

Please sign in to comment.