Consider setting name=False in Variable.chunk()
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 4.2k
- Forks
- 1.4k
- Avg merge
- 2d 15h
- Merged PRs (30d)
- 14
Description
@mrocklin writes:
The following will be slower:
b = (a.chunk(...) + 1) + (a.chunk(...) + 1)
In current operation this will be optimized to
tmp = a.chunk(...) + 1
b = tmp + tmp
So you'll lose that, but I suspect that in your case chunking the same dataset many times is somewhat rare.
See here for discussion: https://github.com/pydata/xarray/pull/1517#issuecomment-324722153
Whether this is worth doing really depends on on what people would find most useful -- and what is the most intuitive behavior.
Contributor guide
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
Start by reading the implementation and behavior of Variable.chunk(), then review the discussion in pydata/xarray#1517 linked from the issue. Clarify whether setting name=False is the desired default and how that affects repeated chunking and optimization; the issue is complete only after that behavior is agreed and covered by appropriate tests.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- data
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100