theislab / scarches

Reference mapping for single-cell genomics
https://docs.scarches.org/en/latest/
BSD 3-Clause "New" or "Revised" License
323 stars 50 forks source link

AttributeError: module 'scanpy.neighbors' has no attribute 'compute_neighbors_umap' #234

Open bitcometz opened 2 months ago

bitcometz commented 2 months ago

hello, thanks for this great tool. But I met a error when using scarches to redo SageNet analysis:

image

Erros:

---------------------------------------------------------------------------
AttributeError                            Traceback (most recent call last)
[<ipython-input-19-4c70d58c03d5>](https://localhost:8080/#) in <cell line: 2>()
      1 dist_adata = ad.AnnData(adata_scRNAseq.obsm['dist_map'], obs = adata_scRNAseq.obs)
----> 2 knn_indices, knn_dists, forest = sc.neighbors.compute_neighbors_umap(dist_adata.X, n_neighbors=50, metric='precomputed')
      3 dist_adata.obsp['distances'], dist_adata.obsp['connectivities'] = sc.neighbors._compute_connectivities_umap(
      4     knn_indices,
      5     knn_dists,

AttributeError: module 'scanpy.neighbors' has no attribute 'compute_neighbors_umap'

How should I use the new scanpy version to do the anlysis ?

Thanks !!!