home / github

Menu
  • Search all tables
  • GraphQL API

issue_comments

Table actions
  • GraphQL API for issue_comments

6 rows where author_association = "MEMBER" and issue = 477081946 sorted by updated_at descending

✎ View and edit SQL

This data as json, CSV (advanced)

Suggested facets: created_at (date), updated_at (date)

user 4

  • shoyer 2
  • jhamman 2
  • kmuehlbauer 1
  • keewis 1

issue 1

  • open_rasterio does not read coordinates from netCDF file properly with netCDF4>=1.4.2 · 6 ✖

author_association 1

  • MEMBER · 6 ✖
id html_url issue_url node_id user created_at updated_at ▲ author_association body reactions performed_via_github_app issue
799657214 https://github.com/pydata/xarray/issues/3185#issuecomment-799657214 https://api.github.com/repos/pydata/xarray/issues/3185 MDEyOklzc3VlQ29tbWVudDc5OTY1NzIxNA== keewis 14808389 2021-03-15T18:38:58Z 2021-03-15T18:38:58Z MEMBER

yes, I would think so. Thanks for the reminder, @gabriel-abrahao.

The original issue was that libnetcdf picked up by netCDF4 didn't match the version installed by the netCDF4 wheels, which is not really xarray's fault.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  open_rasterio does not read coordinates from netCDF file properly with netCDF4>=1.4.2 477081946
574215734 https://github.com/pydata/xarray/issues/3185#issuecomment-574215734 https://api.github.com/repos/pydata/xarray/issues/3185 MDEyOklzc3VlQ29tbWVudDU3NDIxNTczNA== kmuehlbauer 5821660 2020-01-14T15:02:38Z 2020-01-14T15:02:38Z MEMBER

@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
}
  open_rasterio does not read coordinates from netCDF file properly with netCDF4>=1.4.2 477081946
520680549 https://github.com/pydata/xarray/issues/3185#issuecomment-520680549 https://api.github.com/repos/pydata/xarray/issues/3185 MDEyOklzc3VlQ29tbWVudDUyMDY4MDU0OQ== shoyer 1217238 2019-08-13T04:05:18Z 2019-08-13T04:05:18Z MEMBER

The clean xarray-tests conda environment that works with netcdf==1.5.1.2 has libnetcdf: 4.6.2, but for some strange reason, running xr.show_versions() on my setup shows libnetcdf: 4.6.3 even though conda list | grep libnetcdf shows that I've installed libnetcdf 4.6.2 h056eaf5_1002 conda-forge.

xr.show_versions() gets its libnetcdf version from netCDF4 (specially netCDF4.__netcdf4libversion__). So I'm guessing that somehow netCDF4 is picking up libnetcdf from somewhere else -- maybe you pip installed it? It might be worth trying another fresh conda environment...

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  open_rasterio does not read coordinates from netCDF file properly with netCDF4>=1.4.2 477081946
520234456 https://github.com/pydata/xarray/issues/3185#issuecomment-520234456 https://api.github.com/repos/pydata/xarray/issues/3185 MDEyOklzc3VlQ29tbWVudDUyMDIzNDQ1Ng== jhamman 2443309 2019-08-11T14:53:10Z 2019-08-11T14:53:10Z MEMBER

GDAL can open so many formats (https://gdal.org/drivers/raster/index.html). We've really only tested against TIFF like formats though. I think the assumption will need to be is that rasterio will provide standard metadata for each of these drivers.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  open_rasterio does not read coordinates from netCDF file properly with netCDF4>=1.4.2 477081946
520186738 https://github.com/pydata/xarray/issues/3185#issuecomment-520186738 https://api.github.com/repos/pydata/xarray/issues/3185 MDEyOklzc3VlQ29tbWVudDUyMDE4NjczOA== shoyer 1217238 2019-08-10T23:16:53Z 2019-08-10T23:16:53Z MEMBER

I guess GDAL can also read netCDF files :).

Indeed, we did not anticipate people using open_rasterio this way.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  open_rasterio does not read coordinates from netCDF file properly with netCDF4>=1.4.2 477081946
518690320 https://github.com/pydata/xarray/issues/3185#issuecomment-518690320 https://api.github.com/repos/pydata/xarray/issues/3185 MDEyOklzc3VlQ29tbWVudDUxODY5MDMyMA== jhamman 2443309 2019-08-06T14:20:29Z 2019-08-06T14:20:29Z MEMBER

Thanks @weiji14 for opening this issue. When we implemented open_rasterio, I don't think we intended this to be used for netCDF data so I'm surprised it works (worked) at all. I think we'll need someone to dig into the xarray implementation a bit to see if we can pull out the correct coordinates (metadata) using rasterio.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  open_rasterio does not read coordinates from netCDF file properly with netCDF4>=1.4.2 477081946

Advanced export

JSON shape: default, array, newline-delimited, object

CSV options:

CREATE TABLE [issue_comments] (
   [html_url] TEXT,
   [issue_url] TEXT,
   [id] INTEGER PRIMARY KEY,
   [node_id] TEXT,
   [user] INTEGER REFERENCES [users]([id]),
   [created_at] TEXT,
   [updated_at] TEXT,
   [author_association] TEXT,
   [body] TEXT,
   [reactions] TEXT,
   [performed_via_github_app] TEXT,
   [issue] INTEGER REFERENCES [issues]([id])
);
CREATE INDEX [idx_issue_comments_issue]
    ON [issue_comments] ([issue]);
CREATE INDEX [idx_issue_comments_user]
    ON [issue_comments] ([user]);
Powered by Datasette · Queries took 14.028ms · About: xarray-datasette