issues: 277441150
This data as json
| id | node_id | number | title | user | state | locked | assignee | milestone | comments | created_at | updated_at | closed_at | author_association | active_lock_reason | draft | pull_request | body | reactions | performed_via_github_app | state_reason | repo | type |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 277441150 | MDU6SXNzdWUyNzc0NDExNTA= | 1743 | Assigning data to vector-indexed data doesn't seem to work | 167802 | closed | 0 | 4 | 2017-11-28T16:06:56Z | 2022-02-23T12:23:42Z | 2017-12-09T03:29:35Z | CONTRIBUTOR | Code Sample```python import xarray as xr import numpy as np import dask.array as da arr = np.arange(25).reshape((5, 5)) l_indices = xr.DataArray(np.array(((0, 1), (2, 3))), dims=['lines', 'cols']) c_indices = xr.DataArray(np.array(((1, 3), (0, 2))), dims=['lines', 'cols']) xarr = xr.DataArray(da.from_array(arr, chunks=10), dims=['y', 'x']) print(xarr[l_indices, c_indices]) xarr[l_indices, c_indices] = 2 ``` Problem descriptionThis crashes on the last line with a
Expected OutputExpected output is the modified array with 2's in the indicated positions Output of
|
{
"url": "https://api.github.com/repos/pydata/xarray/issues/1743/reactions",
"total_count": 0,
"+1": 0,
"-1": 0,
"laugh": 0,
"hooray": 0,
"confused": 0,
"heart": 0,
"rocket": 0,
"eyes": 0
} |
completed | 13221727 | issue |