function [feature_ids, scores] = cosmo_find_local_extrema(ds, nbrhood, varargin)
cosmo distatis hdr
cosmo flatten hdr