AnnDataSet can not be converted to AnnData when the X is empty
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 323
- Forks
- 43
- PR merge metrics
- No merged PRs in 30d
Description
Hi Kai,
I have several AnnData created directly from fragment files. If I did not add any matrix to AnnData's X, and combine them into AnnDataSet (this step is OK).
- I find that it always report Errors when I used
to_adatafunction for the merged AnnDataSet object.
thread '' panicked at /root/.cargo/registry/src/index.crates.io-6f17d22bba15001f/anndata-0.3.1/src/anndata/dataset.rs:302:81:
calledOption::unwrap()on aNonevalue
note: run withRUST_BACKTRACE=1environment variable to display a backtrace
- if I run
a.X(a: AnnDataSet), it also reports error:
PanicException: called
Option::unwrap()on aNonevalue. (this is the last line of the Error, the whole stacks are about using pretty method to print the results in IPython.)
But AnnData is OK if X is empty. Just nothing is showed in my IPython REPL.
Thanks!
Songpeng
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the issue with an AnnDataSet whose AnnData objects have empty X, using the to_adata and X entry points. Inspect the reported anndata dataset.py location and verify that conversion and X access no longer panic while preserving the empty-X behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python, rust
- Domain
- bioinformatics
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100