cellgeni / sceasy

A package to help convert different single-cell data formats to each other
GNU General Public License v3.0
363 stars 53 forks source link

Installation issue with conda #7

Closed davemcg closed 4 years ago

davemcg commented 4 years ago

There's an issue with the anndata install.

I'm installing with: conda create --yes --name sceasy; conda activate sceasy; conda install -c bioconda r-sceasy==0.0.5

When I enter python and import anndata I get this error:

ImportError: cannot import name 'IndexMixin' from 'scipy.sparse.sputils'

This appears to be an scipy/anndata issue that was later resolved, but we have to use anndata 0.6.19 with sceasy. What should I do to ameliorate this?

nathanin commented 4 years ago

@davemcg I had the same error after following the install instructions. This line is the only place I saw the version of anndata matter for sceasy

https://github.com/cellgeni/sceasy/blob/e6800f8fb23416a2759c4f9940f5cb7814f7549d/R/functions.R#L121-L125

I just upgraded to the newest anndata (anndata==0.7.1) and the function sceasy::convertFormat(seurat_object, from="seurat", to="anndata", outFile='filename.h5ad') which appears to work just fine.

nh3 commented 4 years ago

@davemcg Dependency requirement in bioconda for anndata < 0.6.20 is largely for full conversion (carrying over almost all slots, including those in .uns) between anndata and loom. For other conversions, anndata >= 0.6.20 is fine. We haven't tested with anndata>=0.7, but good to know it works for your data @nathanin. We probably can relax the requirement for anndata in the next release.