home / github / issue_comments

Menu
  • Search all tables
  • GraphQL API

issue_comments: 302949290

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/1260#issuecomment-302949290 https://api.github.com/repos/pydata/xarray/issues/1260 302949290 MDEyOklzc3VlQ29tbWVudDMwMjk0OTI5MA== 10050469 2017-05-21T17:04:33Z 2017-05-21T17:04:33Z MEMBER

Thanks for looking into this!

I'm a slightly reluctant to add a dedicated method for convert rasterio CRS objects into lat/lon arrays. It feels a little overly specialized.

OK, so this corresponds to my solution 3 above (do nothing). I will however add the relevant lines of code to the documentation so that users wanting to add lons and lats to their data can do so. This will leave room for solution 2 is someone has the time to do it later. (side note: "rasterio CRS objects" are in fact strings corresponding to a PROJ4 string that will always be understood by pyproj, rasterio, gdal, etc. Examples: '+proj=aea +lat_1=-18 +lat_2=-32 +lat_0=0 +lon_0=24 +x_0=0 +y_0=0 +datum=WGS84 +units=m +no_defs ' or 'EPSG:4326')

Why return a Dataset rather than a DataArray? The later feels a little more natural to me, given that a rasterio describes a single array.

Agreed. Again this is built out of discussions on https://github.com/pydata/xarray/issues/790, but now obsolete. This speaks even stronger against the use of a DataStore, right? Is there any class I should inherit from to create a DataArray from a rasterio file? I basically need an init() and a __getitem()...

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