def _slice_src(src, like, matching_dims):
    """
    Make sure src matches dst in dims that do not have to be regridded
    """
    slices = {}
    for dim in matching_dims:
        x0 = like[dim][0]
        x1 = like[dim][-1]
        slices[dim] = slice(x0, x1)
    return src.sel(slices).compute()
