home / github / issues

Menu
  • GraphQL API
  • Search all tables

issues: 924722006

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
924722006 MDU6SXNzdWU5MjQ3MjIwMDY= 5491 rasterio backend not supporting complex_int16 type 14925067 closed 0     3 2021-06-18T09:29:27Z 2023-02-28T21:48:22Z 2023-02-28T21:48:21Z NONE      

Dear xarray team, problem : rasterio xarray's backend doesn't support complex_int16 dtype. cmd : xarray.open_rasterio(tiff) error : ```python ----> 4 xarray.open_rasterio(tiff)

/home1/datawork/agrouaze/conda_envs2/envs/xsar_gdal3.3_v2/lib/python3.8/site-packages/xarray/backends/rasterio_.py in open_rasterio(filename, parse_coordinates, chunks, cache, lock) 371 attrs[k] = v 372 --> 373 data = indexing.LazilyIndexedArray(RasterioArrayWrapper(manager, lock, vrt_params)) 374 375 # this lets you write arrays loaded with rasterio

/home1/datawork/agrouaze/conda_envs2/envs/xsar_gdal3.3_v2/lib/python3.8/site-packages/xarray/backends/rasterio_.py in init(self, manager, lock, vrt_params) 40 if not np.all(np.asarray(dtypes) == dtypes[0]): 41 raise ValueError("All bands should have the same dtype") ---> 42 self._dtype = np.dtype(dtypes[0]) 43 44 @property

TypeError: data type 'complex_int16' not understood ``` versions : rasterio == 1.2.4 gdal == 3.3.0 numpy == 1.20.4 xarray == 0.18.2 system : Linux Ubuntu 16.04.7 Python 3.8.10

possible patch in xarray/backends/rasterio_.py line 42: python if dtypes[0]!='complex_int16':#patch agrouaze June 2021 self._dtype = np.dtype(dtypes[0]) else: self._dtype = np.complex Thanks for your help!

{
    "url": "https://api.github.com/repos/pydata/xarray/issues/5491/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  completed 13221727 issue

Links from other tables

  • 0 rows from issues_id in issues_labels
  • 3 rows from issue in issue_comments
Powered by Datasette · Queries took 0.644ms · About: xarray-datasette