home / github

Menu
  • Search all tables
  • GraphQL API

issue_comments

Table actions
  • GraphQL API for issue_comments

3 rows where issue = 124441012 and user = 1217238 sorted by updated_at descending

✎ View and edit SQL

This data as json, CSV (advanced)

These facets timed out: issue

user 1

  • shoyer · 3 ✖

author_association 1

  • MEMBER 3
id html_url issue_url node_id user created_at updated_at ▲ author_association body reactions performed_via_github_app issue
168516553 https://github.com/pydata/xarray/issues/692#issuecomment-168516553 https://api.github.com/repos/pydata/xarray/issues/692 MDEyOklzc3VlQ29tbWVudDE2ODUxNjU1Mw== shoyer 1217238 2016-01-03T16:35:57Z 2016-01-03T16:35:57Z MEMBER

Am I missing something more fundamental?

You're right that this won't come up in many circumstances. It's only that, like with numpy, we try to make xray operations always generalize to multi-dimensional arrays.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Transpose modifies dtype of index, when a PeriodIndex 124441012
168354211 https://github.com/pydata/xarray/issues/692#issuecomment-168354211 https://api.github.com/repos/pydata/xarray/issues/692 MDEyOklzc3VlQ29tbWVudDE2ODM1NDIxMQ== shoyer 1217238 2016-01-02T01:11:13Z 2016-01-02T01:11:37Z MEMBER

The challenge is that the pandas Index has a much smaller API than numpy/dask.array. For example, it doesn't have a transpose method that accepts an axis argument. As another example, there's no equivalent of numpy.stack that would expand the contents of an Index to multiple dimensions. So we're pretty much stuck converting to numpy for these sort of situations.

I'm all for preserving indexes (including all their quirks) in situations where it's possible. And in other cases, we should fall back to numpy arrays with dtype=object holding appropriate scalars.

As for this particular issue, have you tested this after the changes in https://github.com/xray/xray/pull/691? I actually can't reproduce this issue on master.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Transpose modifies dtype of index, when a PeriodIndex 124441012
168345966 https://github.com/pydata/xarray/issues/692#issuecomment-168345966 https://api.github.com/repos/pydata/xarray/issues/692 MDEyOklzc3VlQ29tbWVudDE2ODM0NTk2Ng== shoyer 1217238 2016-01-01T22:53:24Z 2016-01-01T22:53:24Z MEMBER

Hmm. One possible fix would be adjust Variable.transpose so it's a complete no-op (just returning a shallow copy) for variables with ndim < 2. Right now, it will convert everything into a numpy or dask array to do the transpose.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Transpose modifies dtype of index, when a PeriodIndex 124441012

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 4724.673ms · About: xarray-datasette