home / github

Menu
  • GraphQL API
  • Search all tables

issue_comments

Table actions
  • GraphQL API for issue_comments

3 rows where issue = 325436508 sorted by updated_at descending

✎ View and edit SQL

This data as json, CSV (advanced)

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

user 3

  • shoyer 1
  • aldanor 1
  • seth-p 1

author_association 3

  • CONTRIBUTOR 1
  • MEMBER 1
  • NONE 1

issue 1

  • keepdims=True for xarray reductions · 3 ✖
id html_url issue_url node_id user created_at updated_at ▲ author_association body reactions performed_via_github_app issue
474905548 https://github.com/pydata/xarray/issues/2170#issuecomment-474905548 https://api.github.com/repos/pydata/xarray/issues/2170 MDEyOklzc3VlQ29tbWVudDQ3NDkwNTU0OA== shoyer 1217238 2019-03-20T16:08:51Z 2019-03-20T16:08:51Z MEMBER

Pull requests would be very welcome here.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  keepdims=True for xarray reductions 325436508
474786687 https://github.com/pydata/xarray/issues/2170#issuecomment-474786687 https://api.github.com/repos/pydata/xarray/issues/2170 MDEyOklzc3VlQ29tbWVudDQ3NDc4NjY4Nw== aldanor 2418513 2019-03-20T11:13:40Z 2019-03-20T11:13:40Z NONE

Please!

It's really painful in some cases where keepdims option is not available, tons of unneeded boilerplate required to mimic the same thing.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  keepdims=True for xarray reductions 325436508
407159487 https://github.com/pydata/xarray/issues/2170#issuecomment-407159487 https://api.github.com/repos/pydata/xarray/issues/2170 MDEyOklzc3VlQ29tbWVudDQwNzE1OTQ4Nw== seth-p 7441788 2018-07-23T18:39:52Z 2018-07-23T18:39:52Z CONTRIBUTOR

I second this request.

The following may not be optimal, but seems to work for me as a keepdims=True version of reduce(): def dim_preserving_reduce(self, func, dim=None, axis=None, label=None, keep_attrs=False, **kwargs): if axis is not None: dim = np.take(self._obj.dims, axis, mode='wrap') dims = dim if isinstance(dim, (list, tuple)) else [dim] dims_coords = {dim: [lab] for dim, lab in zip(dims, (label if isinstance(label, list) else [label]))} return self._obj.reduce(func, dim=dims, keep_attrs=keep_attrs, **kwargs). \ expand_dims(dims, axis=[self._obj.dims.index(dim) for dim in dims]). \ assign_coords(**dims_coords)

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  keepdims=True for xarray reductions 325436508

Advanced export

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

CSV options:

CREATE TABLE [issue_comments] (
   [html_url] TEXT,
   [issue_url] TEXT,
   [id] INTEGER PRIMARY KEY,
   [node_id] TEXT,
   [user] INTEGER REFERENCES [users]([id]),
   [created_at] TEXT,
   [updated_at] TEXT,
   [author_association] TEXT,
   [body] TEXT,
   [reactions] TEXT,
   [performed_via_github_app] TEXT,
   [issue] INTEGER REFERENCES [issues]([id])
);
CREATE INDEX [idx_issue_comments_issue]
    ON [issue_comments] ([issue]);
CREATE INDEX [idx_issue_comments_user]
    ON [issue_comments] ([user]);
Powered by Datasette · Queries took 11.317ms · About: xarray-datasette