Comments (5)
Hi, what kind of import error are you getting?
from scvi-tools.
Thank you for your fast reply. I copied it below. I am not sure why when I try to import scvi it attempts to read an h5ad file.
[sir@lm602-20 scvi_folder]$ conda activate py-env
(/user/conda-environments/py-env) [sir@lm602-20 scvi_folder]$ python
Python 3.8.6 | packaged by conda-forge | (default, Oct 7 2020, 19:08:05)
[GCC 7.5.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
import scanpy as sc
import scvi
Traceback (most recent call last):
File "/user/conda-environments/py-env/lib/python3.8/site-packages/anndata/_io/utils.py", line 156, in func_wrapper
return func(elem, *args, **kwargs)
File "/user/conda-environments/py-env/lib/python3.8/site-packages/anndata/_io/h5ad.py", line 510, in read_group
EncodingVersions[encoding_type].check(
File "/user/conda-environments/py-env/lib/python3.8/enum.py", line 355, in getitem
return cls.member_map[name]
KeyError: 'dict'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "", line 1, in
File "/user/brainref/scvi_folder/scvi.py", line 5, in
ref_adata=sc.read_h5ad('/user/brainref/a5463d8f-07df-4870-8cae-bc504de762c8.h5ad')
File "/user/conda-environments/py-env/lib/python3.8/site-packages/anndata/_io/h5ad.py", line 413, in read_h5ad
d[k] = read_attribute(f[k])
File "/user/conda-environments/py-env/lib/python3.8/functools.py", line 875, in wrapper
return dispatch(args[0].class)(*args, **kw)
File "/user/conda-environments/py-env/lib/python3.8/site-packages/anndata/_io/utils.py", line 162, in func_wrapper
raise AnnDataReadError(
anndata._io.utils.AnnDataReadError: Above error raised while reading key '/layers' of type <class 'h5py._hl.group.Group'> from /.
from scvi-tools.
What version of scvi-tools is it installing? We don't support Python 3.8 in our latest versions. This might be the source of the issue, I'd recommend making sure that you're installing scvi-tools>=1.1.0
from scvi-tools.
It says that you have a file called scvi in your folder. Please rename this file: /user/brainref/scvi_folder/scvi.py
. Local files have a higher priority during import than installed modules.
from scvi-tools.
To add, you currently can't read this file as there is a version conflict between anndata (likely your current environment has an older version of anndata than the one used to create the file).
from scvi-tools.
Related Issues (20)
- Question about the output of scVI and scANVI HOT 2
- Specifying cell types in the new MRVI tool HOT 1
- Discussion thread: New DestVI model that supports Visium HD (single-cell spatial transcriptomics) data - Timeline, releases and alternatives HOT 2
- Error in py_call_impl(callable, call_args$unnamed, call_args$named) HOT 2
- AttributeError: module 'numpy' has no attribute 'str'. HOT 5
- How to modify scANVI to handle continuous cell labels? HOT 1
- solo.predict() should take an argument to return Non-softmax transformed values, and return logits like previous iterations to allow for non-breaking change that was implemented in 1.1.3 HOT 2
- Update release checklist and documentation for new release workflow HOT 1
- scvi-tools 1.2.0 HOT 3
- Autotuning with Ray: DeprecationWarning: The `RunConfig(local_dir)` argument is deprecated. You should set the `RunConfig(storage_path)` instead. HOT 2
- Use explicit configs instead of kwargs
- autotune throws error for ContrastiveVI (and possibly other external modules) HOT 1
- Fix custom dataloader registry
- ModelTuner.fit Returns error: The `RunConfig(local_dir)` argument is deprecated. HOT 8
- Error in model training HOT 2
- Reproducibility issue of MRVI HOT 4
- In Jupyter Notebook on Windows, the kernel keeps crashing when running Model hyperparameter tuning with scVI. HOT 22
- How to increase num_workers in pytorch DataLoader? HOT 1
- error in scanvi_ref HOT 7
- Memory error running CellAssign depending on size of marker gene set reference HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from scvi-tools.