home / github / issues

Menu
  • GraphQL API
  • Search all tables

issues: 2101296696

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
2101296696 I_kwDOAMm_X859Pz44 8671 FutureWarning when using open_mfdataset() 1211103 closed 0     7 2024-01-25T22:56:34Z 2024-01-26T21:02:21Z 2024-01-26T20:28:52Z NONE      

What is your issue?

When I attempt to use open_mfdataset() with a GLOB expression, to open multiple files:

```python import xarray as xr

ds = xr.open_mfdataset('data_raw/NLDAS/NOAH.nc') ```

This works but generates a FutureWarning:

/usr/local/python-env/ScienceCore/lib/python3.10/site-packages/xarray/core/concat.py:532: FutureWarning: unique with argument that is not not a Series, Index, ExtensionArray, or np.ndarray is deprecated and will raise in a future version. common_dims = tuple(pd.unique([d for v in vars for d in v.dims]))

My concern about the FutureWarning is that this will, at best, confuse my students and, at worst, potentially break my curriculum after some "future version." However, it's not clear that I have any control over what to do differently here.

I'm using xarray version '2023.1.0'. The netCDF4 files I'm using could be downloaded automatically (given a NASA Earthdata account) with:

```python import earthaccess import xarray as xr

Log-in, presumably using a .netrc file

auth = earthaccess.login()

Get data from August for every year from 2008 up to (but not including) 2018

results = [] for year in range(2008, 2018): search = earthaccess.search_data( short_name = 'NLDAS_NOAH0125_M', version = '2.0', temporal = (f'{year}-08', f'{year}-08')) results.extend(search)

earthaccess.download(results, 'data_raw/NLDAS') ```

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

Links from other tables

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