You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Bugs and problems in calculate_niche and in unreleased main. #1293
This is NOT AI generated, I wrote these one by one. I usually disclose when I do. So I am a bit confident with these but I kept it brief. So please consult your AI assistant for digging where these items are coming from in the code. I wanted to keep it high level here. This will be a ledger also for the changes #1284 introduces.
vs v1.8.3 here is the version before we started with this refactor. So these were what was already broken and require breaking changes:
n_hop_weights shorter than distance pads silently, my proposal raises
Hop rings in cellcharter tried to do BFS via thresholded matrix powers but it was wrong. I wrote a BFS in numba which made the features differ.
cellcharter GMM seed: now one rng spawned per clusterer
use_rep skipped the spatial aggregation entirely. (was in 1.8.3 also, hops were computed and ignored completely, now use_rep should only replace the default pca and shouldn't mean anything else, also matches cellcharter). Now it doesn't skip it and the spatial aggregation is done on the scvi embeddings etc when provided. Which should've been the case already
n_components used to set GMM(n_components) but also for some reason truncated adata.obsm[use_rep][:,:n_components]? but when use_rep wasn't given, we calculated sc.pp.pca with no n_components passing?? I basically decided to take n_pca_components and n_clusters and not use n_components in the new calculate_niche_cellcharter. Not technically breaking against released version but it is against main (related Add function for calculating niches #831 and Change niche flavor to cellcharter_simple and default distance = 3 #978)
mask was in the docs but was actually unused in all but neighborhood which is crazy and shows we are doing good with this splitting refactor.
duplicate, empty and cross-flavor resolutions failed silently or obscurely. [0.5, 0.5] produced one column instead of two with no warning, a tuple reached scanpy as must be real number, not tuple, and an ndarray as only 0-dimensional arrays...
vs main
remove prefix removed from calculate_niche_spatialleiden. Never released, so no deprecation
changed the title [-]Bugs and problems in calculate_niche in unreleased main.[/-][+]Bugs and problems in calculate_niche and in unreleased main.[/+]on Sep 17, 2026
Activity
[-]Bugs and problems in calculate_niche in unreleased main.[/-][+]Bugs and problems in calculate_niche and in unreleased main.[/+]