Skip to content

Commit

Permalink
chunk dense arrays in same chunk_size as sparse arrays
Browse files Browse the repository at this point in the history
  • Loading branch information
nayib-jose-gloria committed Dec 20, 2024
1 parent f33e3c3 commit fa25f40
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion cellxgene_schema_cli/cellxgene_schema/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,8 @@ def callback(func, elem_name: str, elem, iospec):
n_vars = elem.attrs.get("shape")[1]
return read_elem_as_dask(elem, chunks=(chunk_size, n_vars))
elif iospec.encoding_type == "array" and len(elem.shape) > 1:
return read_elem_as_dask(elem)
n_vars = elem.shape[1]
return read_elem_as_dask(elem, chunks=(chunk_size, n_vars))

Check warning on line 138 in cellxgene_schema_cli/cellxgene_schema/utils.py

View check run for this annotation

Codecov / codecov/patch

cellxgene_schema_cli/cellxgene_schema/utils.py#L137-L138

Added lines #L137 - L138 were not covered by tests
else:
return func(elem)
else:
Expand Down

0 comments on commit fa25f40

Please sign in to comment.