def num_owned_indices_from_unstructured(dd):
    """Given a dimension dictionary `dd` with dist_type 'u', return the number
    of indices owned.
    """
    indices_buffer = memoryview(dd['indices'])
    return len(indices_buffer)