Minor fix: need to convert data to darray before checking its shape.