home / github / issue_comments

Menu
  • GraphQL API
  • Search all tables

issue_comments: 674578524

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/pull/4155#issuecomment-674578524 https://api.github.com/repos/pydata/xarray/issues/4155 674578524 MDEyOklzc3VlQ29tbWVudDY3NDU3ODUyNA== 1005109 2020-08-16T21:11:49Z 2020-08-16T21:11:49Z CONTRIBUTOR

@cyhsu I can answer this question.

For best performance you should chunk the input array on the non interpolated dimensions and chunk the destination. Aka :

``` datax = xr.DataArray(data=np.arange(0, 4), coords={"x": np.linspace(0, 1, 4)}, dims="x") datay = xr.DataArray(data=da.from_array(np.arange(0, 4), chunks=2), coords={"y": np.linspace(0, 1, 4)}, dims="y") data = datax * datay

x = xr.DataArray(data = da.from_array(np.linspace(0,1), chunks=2), dims='x')

res = data.interp(x=x) ```

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