home / github

Menu
  • Search all tables
  • GraphQL API

issue_comments

Table actions
  • GraphQL API for issue_comments

8 rows where author_association = "MEMBER", issue = 524043729 and user = 5821660 sorted by updated_at descending

✎ View and edit SQL

This data as json, CSV (advanced)

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

user 1

  • kmuehlbauer · 8 ✖

issue 1

  • Add defaults during concat 508 · 8 ✖

author_association 1

  • MEMBER · 8 ✖
id html_url issue_url node_id user created_at updated_at ▲ author_association body reactions performed_via_github_app issue
1362936825 https://github.com/pydata/xarray/pull/3545#issuecomment-1362936825 https://api.github.com/repos/pydata/xarray/issues/3545 IC_kwDOAMm_X85RPMP5 kmuehlbauer 5821660 2022-12-22T14:56:44Z 2022-12-22T14:56:44Z MEMBER

@scottcha @keewis I've tried hard, but finally decided to start from scratch, see #7400.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Add defaults during concat 508 524043729
1306229983 https://github.com/pydata/xarray/pull/3545#issuecomment-1306229983 https://api.github.com/repos/pydata/xarray/issues/3545 IC_kwDOAMm_X85N23zf kmuehlbauer 5821660 2022-11-07T21:37:11Z 2022-11-07T21:37:11Z MEMBER

Thanks @keewis for the heads up. I'll have a look and if things get too complicated a reimplementation might be our best option.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Add defaults during concat 508 524043729
1306157550 https://github.com/pydata/xarray/pull/3545#issuecomment-1306157550 https://api.github.com/repos/pydata/xarray/issues/3545 IC_kwDOAMm_X85N2mHu kmuehlbauer 5821660 2022-11-07T20:38:21Z 2022-11-07T20:38:21Z MEMBER

Great @scottcha, I was coming back here too every once in an while to just refresh my mind with the ideas pursued here. I can try to rebase the PR onto latest main, if I can free some cycles in the following days for starters.

{
    "total_count": 1,
    "+1": 1,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Add defaults during concat 508 524043729
1306147080 https://github.com/pydata/xarray/pull/3545#issuecomment-1306147080 https://api.github.com/repos/pydata/xarray/issues/3545 IC_kwDOAMm_X85N2jkI kmuehlbauer 5821660 2022-11-07T20:26:57Z 2022-11-07T20:26:57Z MEMBER

@scottcha Are you still around and interested to bring this along? If not I could try to dive again into this.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Add defaults during concat 508 524043729
579203497 https://github.com/pydata/xarray/pull/3545#issuecomment-579203497 https://api.github.com/repos/pydata/xarray/issues/3545 MDEyOklzc3VlQ29tbWVudDU3OTIwMzQ5Nw== kmuehlbauer 5821660 2020-01-28T11:33:41Z 2020-01-28T11:52:02Z MEMBER

@scottcha @shoyer below is a minimal example where one variable is missing in each file.

```python import random random.seed(123) random.randint(0, 10)

create var names list with one missing value

orig = [f'd{i:02}' for i in range(10)] datasets = [] for i in range(1, 9): l1 = orig.copy() l1.remove(f'd{i:02}') datasets.append(l1)

create files

for i, dsl in enumerate(datasets): foo_data = np.arange(24).reshape(2, 3, 4) with nc.Dataset(f'test{i:02}.nc', 'w') as ds: ds.createDimension('x', size=2) ds.createDimension('y', size=3) ds.createDimension('z', size=4) for k in dsl: ds.createVariable(k, int, ('x', 'y', 'z')) ds.variables[k][:] = foo_data

flist = glob.glob('test*.nc') dslist = [] for f in flist: dslist.append(xr.open_dataset(f))

ds2 = xr.concat(dslist, dim='time') ds2 ``` Output:

<xarray.Dataset> Dimensions: (time: 8, x: 2, y: 3, z: 4) Dimensions without coordinates: time, x, y, z Data variables: d01 (x, y, z) int64 0 1 2 3 4 5 6 7 8 9 ... 15 16 17 18 19 20 21 22 23 d00 (time, x, y, z) int64 0 1 2 3 4 5 6 7 8 ... 16 17 18 19 20 21 22 23 d02 (time, x, y, z) float64 0.0 1.0 2.0 3.0 4.0 ... 20.0 21.0 22.0 23.0 d03 (time, x, y, z) float64 0.0 1.0 2.0 3.0 4.0 ... 20.0 21.0 22.0 23.0 d04 (time, x, y, z) float64 0.0 1.0 2.0 3.0 4.0 ... 20.0 21.0 22.0 23.0 d05 (time, x, y, z) float64 0.0 1.0 2.0 3.0 4.0 ... 20.0 21.0 22.0 23.0 d06 (time, x, y, z) float64 0.0 1.0 2.0 3.0 4.0 ... 20.0 21.0 22.0 23.0 d07 (time, x, y, z) float64 0.0 1.0 2.0 3.0 4.0 ... 20.0 21.0 22.0 23.0 d08 (time, x, y, z) float64 0.0 1.0 2.0 3.0 4.0 ... nan nan nan nan nan d09 (time, x, y, z) int64 0 1 2 3 4 5 6 7 8 ... 16 17 18 19 20 21 22 23

Three cases here:

  • d00 and d09 are available in all datasets, and they are concatenated correctly (keeping dtype)
  • d02 to d08 are missing in one dataset and are filled with the created dummy variable, but the dtype is converted to float64
  • d01 is not handled properly, because it is missing in the first dataset, this is due to checking only variables of first dataset in _calc_concat_over

python elif opt == "all": concat_over.update( set(getattr(datasets[0], subset)) - set(datasets[0].dims) ) and from putting d01 in result_vars before iterating to find missing variables.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Add defaults during concat 508 524043729
577745924 https://github.com/pydata/xarray/pull/3545#issuecomment-577745924 https://api.github.com/repos/pydata/xarray/issues/3545 MDEyOklzc3VlQ29tbWVudDU3Nzc0NTkyNA== kmuehlbauer 5821660 2020-01-23T15:59:47Z 2020-01-23T15:59:47Z MEMBER

@dcherian Just to clarify, the concatenation is done along a new dimension (which has to be created by expand_dims). What do you mean by short-clrcuit in this context?

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Add defaults during concat 508 524043729
577696741 https://github.com/pydata/xarray/pull/3545#issuecomment-577696741 https://api.github.com/repos/pydata/xarray/issues/3545 MDEyOklzc3VlQ29tbWVudDU3NzY5Njc0MQ== kmuehlbauer 5821660 2020-01-23T14:08:57Z 2020-01-23T14:08:57Z MEMBER

@scottcha @shoyer For one of my use cases (240 datasets, 1 with missing variables) I do not see any performance penalties using this implementation compared to the current. But this might be due to the fact, that the most time consuming part is the expand_dims for every dataset, which accounts for roughly 80% overall concat runtime.

If I can be of any help to push this over the line, please ping me.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Add defaults during concat 508 524043729
577530863 https://github.com/pydata/xarray/pull/3545#issuecomment-577530863 https://api.github.com/repos/pydata/xarray/issues/3545 MDEyOklzc3VlQ29tbWVudDU3NzUzMDg2Mw== kmuehlbauer 5821660 2020-01-23T06:52:06Z 2020-01-23T07:29:37Z MEMBER

@scottcha If found this while searching. Have the same requirements, means missing DataArrays in some Datasets of a timeseries to be concatenated. I've already some hacks and workarounds in place for my specific use cases, but it would be really great if this could be handled by xarray.

I'll try to test your current implementation against my source data and will report my findings here.

Update: I've rebased locally on latest master and this works smoothly with my data (which uses packed data). I'll now look into performance.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  Add defaults during concat 508 524043729

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