Sum multi-dimensional array along all axes using NumPy

numpy.sum(a)

Remarks:

The sum function from NumPy has an axes parameter which defaults to None, causing NumPy to sum over all axes.

References: