Open marctormo opened 5 months ago
It looks like this is coming down to something in anndata
, which is a package that cellbender imports and uses to read .h5ad
AnnData-format files.
I wonder if you can try the following: import anndata in python
(cellbender) bash-4.2$ python
>>> import anndata
Do you see the same error? Maybe you could look into different ways to install anndata. For example, you might be able to conda install
anndata (https://anaconda.org/conda-forge/anndata) rather than relying on cellbender to pip install
anndata as a dependency.
I will say: miniconda 4.9.2 looks like it's python 3.8. But cellbender only supports python 3.7 currently. I'd recommend making sure you're using python 3.7. If you don't it will cause problems for cellbender.
Hi and thanks for your answer.
Unfortunately, I'm obtaining the same error. What I'm doing is:
conda create -y -n cellbender python=3.7
source activate cellbender
conda install -y -c anaconda pytables
pip install torch==1.11.0
conda install -y anaconda::libstdcxx-ng
conda install -y anndata
export LD_LIBRARY_PATH=/homes/aplic/noarch/software/Miniconda3/4.9.2/envs/cellbender/lib/:$LD_LIBRARY_PATH
cd /aplic/noarch/build_custom/
git clone https://github.com/broadinstitute/CellBender.git
# modify requirements.txt: remove anndata>=0.7, add torch==1.11.0
pip install -e CellBender
And I'm obtaing the same errors:
(cellbender) bash-4.2$ python -c "import anndata"
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/homes/aplic/noarch/software/Miniconda3/4.9.2/envs/cellbender/lib/python3.7/site-packages/anndata/__init__.py", line 7, in <module>
from ._core.anndata import AnnData
File "/homes/aplic/noarch/software/Miniconda3/4.9.2/envs/cellbender/lib/python3.7/site-packages/anndata/_core/anndata.py", line 18, in <module>
from natsort import natsorted
File "/homes/aplic/noarch/software/Miniconda3/4.9.2/envs/cellbender/lib/python3.7/site-packages/natsort/__init__.py", line 3, in <module>
from natsort.natsort import (
File "/homes/aplic/noarch/software/Miniconda3/4.9.2/envs/cellbender/lib/python3.7/site-packages/natsort/natsort.py", line 757, in <module>
os_sort_key = os_sort_keygen()
File "/homes/aplic/noarch/software/Miniconda3/4.9.2/envs/cellbender/lib/python3.7/site-packages/natsort/natsort.py", line 725, in os_sort_keygen
loc = natsort.compat.locale.get_icu_locale()
File "/homes/aplic/noarch/software/Miniconda3/4.9.2/envs/cellbender/lib/python3.7/site-packages/natsort/compat/locale.py", line 44, in get_icu_locale
return icu.Locale(f"{language_code}.{encoding}")
AttributeError: module 'icu' has no attribute 'Locale'
(cellbender) bash-4.2$ python -V
Python 3.7.12
Thanks!
Hello,
I tried to install CellBender with conda but I'm getting this error when executing:
Do you have any clues on how to solve that? Many thanks!