home / github / issue_comments

Menu
  • Search all tables
  • GraphQL API

issue_comments: 149987937

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/630#issuecomment-149987937 https://api.github.com/repos/pydata/xarray/issues/630 149987937 MDEyOklzc3VlQ29tbWVudDE0OTk4NzkzNw== 1217238 2015-10-21T18:36:00Z 2015-10-21T19:51:46Z MEMBER

If you use the DataArray constructor instead of inserting an item in a Dataset, the array values will always be a view.

If you pre-align the array you are about to insert using xray.align, it is also guaranteed to be a view.

Unfortunately, it's impossible to make such automatically aligned arrays views in general, because of numpy's memory model.

One thing we could do is add an option to make inserted items always a copy. I would probably put this on the Dataset.merge method, which is what Dataset.__getitem__ uses under the hood.

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