I am solving quite trivial problem. I can solve it through iteration, but its too slow.
My problem:
import numpy as np
arr3 = np.zeros(shape=[4, 4, 3])
arr2 = np.zeros(shape=[4, 4])
#This is ok but I dont want
arr3[0,0]*arr2[0,0] # thats [0,0,0]*0
#This is not ok but I need
arr3[:,:]*arr2
Simply said, i need to multiply each element from arr3[:][:] which are in format [R,G,B]) with corresponding element in arr2 which are in float (distance) and all without iteration
Thanks