home / github / issue_comments

Menu
  • Search all tables
  • GraphQL API

issue_comments: 573008350

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/3680#issuecomment-573008350 https://api.github.com/repos/pydata/xarray/issues/3680 573008350 MDEyOklzc3VlQ29tbWVudDU3MzAwODM1MA== 5821660 2020-01-10T11:59:55Z 2020-01-10T11:59:55Z MEMBER

After a bit of further investigation, looks like this is indeed a problem with how h5netcdf retrieves the .name. While netCDF4 gives back just the name of a group h5netcdf gives back the hdf5 name which is the full path to the group.

```python

Your code here

import netCDF4 import h5netcdf import xarray from xarray.backends.common import find_root_and_group root = netCDF4.Dataset("testx.nc", "w", format="NETCDF4") test1 = root.createGroup("test1") test1.createGroup("test2") print(root['test1/test2'].name) root.close() h5n = h5netcdf.File('testx.nc') print(h5n['test1/test2'].name) h5n.close() ```

Output: test2 /test1/test2

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