home / github / issues

Menu
  • GraphQL API
  • Search all tables

issues: 966983801

This data as json

id node_id number title user state locked assignee milestone comments created_at updated_at closed_at author_association active_lock_reason draft pull_request body reactions performed_via_github_app state_reason repo type
966983801 MDExOlB1bGxSZXF1ZXN0NzA5MTg3NDY2 5692 Explicit indexes 4160723 closed 0     46 2021-08-11T15:57:41Z 2023-08-30T09:26:37Z 2022-03-17T17:11:44Z MEMBER   0 pydata/xarray/pulls/5692
  • [x] Closes many issues:
  • [x] closes #1366
  • [x] closes #1408
  • [x] closes #2489
  • [x] closes #3432
  • [x] closes #4542
  • [x] closes #4955
  • [x] closes #5202
  • [x] closes #5645
  • [x] closes #5691
  • [x] closes #5697
  • [x] closes #5700
  • [x] closes #5727
  • [x] closes #5953
  • [x] closes #6183
  • [x] closes #6313
  • [x] Tests added
  • [x] Passes pre-commit run --all-files
  • [x] User visible changes (including notable bug fixes) are documented in whats-new.rst
  • New functions/methods are listed in api.rst (new Index and Indexes API not public yet)

Follow-up on #5636 (work in progress), supersedes #2195.

This is likely to be going big, sorry in advance! It'll be safer to make a release before merging this PR.

Current progress:

  • [x] create (default) indexes using the Index classes
  • [x] refactor default indexes created when 1st accessing .xindexes or .indexes
  • [x] support for non-default indexes (no public API yet)
  • [x] remove multi-index virtual coordinates (replace it by regular coordinates)
  • [x] refactor internal (text / html) formatting functions
  • [x] internal refactor of location-based selection (.isel())
  • [x] internal refactor of label-based selection (.sel())
  • [x] internal refactor of .rename()
  • Some changes in behavior (see comments below)
    • see #4108
    • see #4107
    • see #4417
  • [x] internal refactor of set_index / reset_index
  • [x] internal refactor of stack / unstack
    • Some changes in behavior (see comments below)
  • [x] internal refactor of Dataset.to_stacked_array
  • [x] internal refactor of swap_dims
  • [x] internal refactor of expand_dims
  • [x] internal refactor of alignment
  • [x] internal refactor of reindex and reindex_like
  • [x] internal refactor of interp and interp_like
  • [x] internal refactor of merge
  • [x] internal refactor of concat
  • [x] internal refactor of computation
  • [x] internal refactor of copy
  • [x] internal refactor of update, assign, __setitem__, del, drop_vars, etc.
    • updates must not corrupt multi-coordinate indexes
  • [x] internal refactor of set_coords and reset_coords
  • internal refactor of drop_sel and drop_isel (maybe later)
  • [x] internal refactor of pad
  • [x] internal refactor of shift
  • [x] internal refactor of roll

TODO:

  • [x] Uniformize Index API with Xarray's API
    • [x] rename Index.query() -> Index.sel()?
    • [x] rename PandasMultiIndex.from_product() -> PandasMultiIndex.stack()? Add Index.stack() and Index.unstack().
    • [x] remove Index.union() and Index.intersection()
  • [x] Use Index.create_variables() internally
    • [x] remove PandasIndex.from_pandas_index() and PandasMultiIndex.from_pandas_index() (use constructor + .create_variables() instead)
  • [x] Review where .xindexes is used and use private API instead (._indexes) if possible for speed
    • [x] requires that _indexes always returns a mapping
  • [x] Use from __future__ import annotations in indexes.py
  • [x] Re-activate default indexes invariant check (with opt-out for some tests)

In next PRs:

  • custom Index.__repr__ and Index._repr_inline_
  • add an Indexes section in DataArray / Dataset reprs
  • update public API (set_index, reset_index, drop_indexes, Dataset and DataArray constructors, etc.)
  • allow multi-dimensional variables with name in var.dims
{
    "url": "https://api.github.com/repos/pydata/xarray/issues/5692/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
    13221727 pull

Links from other tables

  • 4 rows from issues_id in issues_labels
  • 46 rows from issue in issue_comments
Powered by Datasette · Queries took 0.682ms · About: xarray-datasette