home / github

Menu
  • GraphQL API
  • Search all tables

issues

Table actions
  • GraphQL API for issues

2 rows where repo = 13221727, state = "closed" and user = 883786 sorted by updated_at descending

✎ View and edit SQL

This data as json, CSV (advanced)

Suggested facets: created_at (date), updated_at (date), closed_at (date)

type 2

  • issue 1
  • pull 1

state 1

  • closed · 2 ✖

repo 1

  • xarray · 2 ✖
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
1936210577 I_kwDOAMm_X85zaDqR 8292 Different output for Dataset.groupby().mean() depending on whether flox is installed or not eendebakpt 883786 closed 0     7 2023-10-10T20:49:52Z 2023-11-24T23:10:42Z 2023-11-24T23:10:42Z CONTRIBUTOR      

What happened?

We execute ds.groupby('clifford').mean(). The resulting Dataset is different depending whether the optional package flox is installed or not.

What did you expect to happen?

The result should be the same

Minimal Complete Verifiable Example

```Python import xarray as xr d={'coords': {'bit_index': {'dims': ('bit_index',), 'attrs': {'name': 'bit_index', 'units': 'a.u.', 'standard_name': 'bit_index', 'long_name': 'bit_index', 'label': 'bit_index'}, 'data': [0, 1]}, 'index': {'dims': ('index',), 'attrs': {'name': 'index', 'units': '', 'standard_name': 'index', 'long_name': 'index', 'label': 'index'}, 'data': [0, 6, 8, 10, 14]}, 'clifford': {'dims': ('index',), 'attrs': {}, 'data': [1, 1, 4, 10, 4]}, 'pauli': {'dims': ('index',), 'attrs': {}, 'data': [12, 12, 6, 12, 6]}, 'pauli_value': {'dims': ('index',), 'attrs': {}, 'data': [1, 1, 1, 1, 1]}}, 'attrs': {}, 'dims': {'bit_index': 2, 'index': 5}, 'data_vars': {'counts': {'dims': ('bit_index', 'index'), 'attrs': {'name': 'counts', 'units': '', 'standard_name': 'Counts', 'long_name': 'Counts', 'label': 'Counts'}, 'data': [[18, 30, 45, 70, 38], [382, 370, 355, 330, 362]]}}}

ds=xr.Dataset.from_dict(d)
ds.groupby('clifford').mean() ```

(execute with both flox installed and flox not installed) ``` """ With flox <xarray.Dataset> Dimensions: (bit_index: 2, clifford: 3) Coordinates: * bit_index (bit_index) int32 0 1 * clifford (clifford) int64 1 4 10 Data variables: counts (bit_index, clifford) float64 24.0 41.5 70.0 376.0 358.5 330.0 """

""" No flox <xarray.Dataset> Dimensions: (bit_index: 2, clifford: 3) Coordinates: * bit_index (bit_index) int32 0 1 * clifford (clifford) int64 1 4 10 Data variables: counts (clifford, bit_index) float64 24.0 376.0 41.5 358.5 70.0 330.0 """ ```

MVCE confirmation

  • [X] Minimal example — the example is as focused as reasonably possible to demonstrate the underlying issue in xarray.
  • [X] Complete example — the example is self-contained, including all data and the text of any traceback.
  • [X] Verifiable example — the example copy & pastes into an IPython prompt or Binder notebook, returning the result.
  • [X] New issue — a search of GitHub Issues suggests this is not a duplicate.
  • [X] Recent environment — the issue occurs with the latest version of xarray and its dependencies.

Relevant log output

No response

Anything else we need to know?

This is probably related to #7546

Environment

INSTALLED VERSIONS ------------------ commit: None python: 3.11.0 (main, Oct 24 2022, 18:26:48) [MSC v.1933 64 bit (AMD64)] python-bits: 64 OS: Windows OS-release: 10 machine: AMD64 processor: Intel64 Family 6 Model 142 Stepping 12, GenuineIntel byteorder: little LC_ALL: None LANG: en LOCALE: ('Dutch_Netherlands', '1252') libhdf5: 1.12.2 libnetcdf: None xarray: 2023.9.0 pandas: 1.5.3 numpy: 1.26.0 scipy: 1.11.3 netCDF4: None pydap: None h5netcdf: 1.2.0 h5py: 3.9.0 Nio: None zarr: None cftime: None nc_time_axis: None PseudoNetCDF: None iris: None bottleneck: None dask: 2023.9.1 distributed: None matplotlib: 3.8.0 cartopy: None seaborn: None numbagg: None fsspec: 2023.9.0 cupy: None pint: 0.22 sparse: None flox: 0.7.2 numpy_groupies: 0.9.22 setuptools: 65.4.1 pip: 23.2 conda: None pytest: 7.4.2 mypy: 1.5.1 IPython: 8.15.0 sphinx: 7.2.6
{
    "url": "https://api.github.com/repos/pydata/xarray/issues/8292/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  completed xarray 13221727 issue
1922247853 PR_kwDOAMm_X85bsLt8 8261 Update type annotation for center argument of dataaray_plot methods eendebakpt 883786 closed 0     3 2023-10-02T16:28:55Z 2023-10-02T22:09:57Z 2023-10-02T22:09:54Z CONTRIBUTOR   0 pydata/xarray/pulls/8261

The documentation for xarray.plot.dataarray_plot.pcolormesh (and several other methods) states: ... center : float, optional The value at which to center the colormap. Passing this value implies use of a diverging colormap. Setting it to ``False`` prevents use of a diverging colormap. robust : bool, optional ... The False argument for center is a valid argument, but was not included in the type annotations. In this PR we update the type annotations.

{
    "url": "https://api.github.com/repos/pydata/xarray/issues/8261/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
    xarray 13221727 pull

Advanced export

JSON shape: default, array, newline-delimited, object

CSV options:

CREATE TABLE [issues] (
   [id] INTEGER PRIMARY KEY,
   [node_id] TEXT,
   [number] INTEGER,
   [title] TEXT,
   [user] INTEGER REFERENCES [users]([id]),
   [state] TEXT,
   [locked] INTEGER,
   [assignee] INTEGER REFERENCES [users]([id]),
   [milestone] INTEGER REFERENCES [milestones]([id]),
   [comments] INTEGER,
   [created_at] TEXT,
   [updated_at] TEXT,
   [closed_at] TEXT,
   [author_association] TEXT,
   [active_lock_reason] TEXT,
   [draft] INTEGER,
   [pull_request] TEXT,
   [body] TEXT,
   [reactions] TEXT,
   [performed_via_github_app] TEXT,
   [state_reason] TEXT,
   [repo] INTEGER REFERENCES [repos]([id]),
   [type] TEXT
);
CREATE INDEX [idx_issues_repo]
    ON [issues] ([repo]);
CREATE INDEX [idx_issues_milestone]
    ON [issues] ([milestone]);
CREATE INDEX [idx_issues_assignee]
    ON [issues] ([assignee]);
CREATE INDEX [idx_issues_user]
    ON [issues] ([user]);
Powered by Datasette · Queries took 29.62ms · About: xarray-datasette