Sum axes of the array such that the resulting shape is as given.
Thus, the shape of the result will be s or an error is raised.