Do the product of the arrays.
import numpy as np
a = np.array([[5, 50, 10],[20,-10,1]])
np.prod(a) # Product of all elements
⇒ -500000 # 5*50*10*20*-10*1
np.prod(a,axis=0) # Product of elements between columns
⇒ array([ 100, -500, 10]) # [5*20, 50*-10 , 10*1]
np.prod(a,axis=1) # Product of elements between rows
⇒ array([2500, -200]) # [5*50*10 , 20*-10*1]