home / github / issue_comments

Menu
  • GraphQL API
  • Search all tables

issue_comments: 334251264

This data as json

html_url issue_url id node_id user created_at updated_at author_association body reactions performed_via_github_app issue
https://github.com/pydata/xarray/issues/1215#issuecomment-334251264 https://api.github.com/repos/pydata/xarray/issues/1215 334251264 MDEyOklzc3VlQ29tbWVudDMzNDI1MTI2NA== 2443309 2017-10-04T18:40:39Z 2017-10-04T18:40:39Z MEMBER

@fmaussion and @shoyer - I have a use case that could use this. I'm wondering if either of you have looked at this any further since January?

If not, I'll propose a path forward that fits my use case and we can iterate on the details until we're satisfied:

Do we load existing variable values to check them for equality with the new values, or alternatively always skip or override them?

I don't think loading variables already written to disk is practical. My preference would be to only append missing variables/coordinates.

How do we handle cases where dims, attrs or encoding differs from the exiting variable? Do we attempt to delete and replace the existing variable, update it inplace or error?

differing dims: raise an error

I'd like to implement this but to keep it as simple as possible. A trivial use case like this should work:

```Python fname = 'out.nc' dates = pd.date_range('2016-01-01', freq='1D', periods=45) ds = xr.Dataset() for var in ['A', 'B', 'C']: ds[var] = xr.DataArray(np.random.random((len(dates), 4, 5)), dims=('time', 'x', 'y'), coords={'time': dates})

for var in ds.data_vars: ds[[var]].to_netcdf(fname, mode='a') ```

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  201428093
Powered by Datasette · Queries took 0.635ms · About: xarray-datasette