home / github / issue_comments

Menu
  • Search all tables
  • GraphQL API

issue_comments: 799635182

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/3185#issuecomment-799635182 https://api.github.com/repos/pydata/xarray/issues/3185 799635182 MDEyOklzc3VlQ29tbWVudDc5OTYzNTE4Mg== 30908904 2021-03-15T18:10:28Z 2021-03-15T18:10:28Z CONTRIBUTOR

Maybe this can be closed now, since #5021 changed the docs?

@naught101 Looks like those coordinates are now in the order as declared in the affine package (since rasterio >= 1.0). See also: https://rasterio.readthedocs.io/en/latest/topics/migrating-to-v1.html.

All coordinates are created correctly, so from my point of view, only the docs here have to be changed.

python from affine import Affine da = xr.open_rasterio('path_to_file.tif') transform = Affine(*da.attrs['transform']) nx, ny = da.sizes['x'], da.sizes['y'] x, y = np.meshgrid(np.arange(nx)+0.5, np.arange(ny)+0.5) * transform

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