Skip to content

Commit

Permalink
Backport PR #2344: Handle scalar datasets too (#2348)
Browse files Browse the repository at this point in the history
Co-authored-by: Gökçen Eraslan <[email protected]>
  • Loading branch information
meeseeksmachine and gokceneraslan authored Oct 11, 2022
1 parent 6b5f786 commit 97c2617
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion scanpy/readwrite.py
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ def _read_legacy_10x_h5(filename, *, genome=None, start=None):
def _collect_datasets(dsets: dict, group: h5py.Group):
for k, v in group.items():
if isinstance(v, h5py.Dataset):
dsets[k] = v[:]
dsets[k] = v[()]
else:
_collect_datasets(dsets, v)

Expand Down
Binary file modified scanpy/tests/_data/10x_data/1.2.0/multiple_genomes.h5
Binary file not shown.

0 comments on commit 97c2617

Please sign in to comment.