Closed
Description
What happened:
TypeError: unhashable type: 'numpy.ndarray'
What you expected to happen:
No error
Minimal Complete Verifiable Example:
Take this for example:
import numpy as np
import pandas as pd
import xarray as xr
midx = pd.MultiIndex.from_arrays([["R", "R", "V", "V"], [0.1, 0.2, 0.7, 0.9]], names=("band", "wn"))
mda = xr.DataArray(np.random.rand(4), coords={"spec": midx}, dims="spec")
mda.loc[{'band': 'R', 'wn': 0.1}]
Environment:
xarray: 0.19.0,
pandas: 1.3.1,
numpy: 1.21.1,