Closed dwfncar closed 1 year ago
It looks like this line of code worked with older versions of xarray and then with more recent updates it stopped working. On xarray's website it says reset_index is legacy code from pandas, so we should probably move away from it.
I think all that has to happen to get this working again with both older and newer versions of xarray is to replace this: dset = dset.reset_index(["XTIME", "datetime"], drop=True)
With this instead: dset = dset.reset_coords(["XTIME", "datetime"], drop=True)
The overall goal was just to remove XTIME and datetime as coordinates and it seems like the second option does this equally well and is the preferred method. I'm at a conference, but @zmoon I may be able to test this more tomorrow or if you agree with this change and just want to update this in MONETIO feel free.
This is fixed on the develop branch of MONETIO now (https://github.com/noaa-oar-arl/monetio/pull/95). I will close this once this fix is pushed to the stable branch of MONETIO.
This is updated in the stable branch of MONETIO now.
With leaving the line 192, “dset = dset.reset_index(["XTIME", "datetime"], drop=True)”, of monetio/models/_wrfchem_mm.py on, it will complain messages below when I read the sample wrf-chem data on Cheyenne.