I'm working with numpy in Python3, I have 512X512 matrix, I need to read every value and send to the function - the function will do some calculation and will be return 3 values- now I need to add this 3 values in separate matrix- by the way my matrix will be 512X512X512.
for example : main matrix
a=[1,2,3,4,5…23] [23,24,33,….23]…(512)….[11,22,33,44,55,…66]
I want to pickup every element (e.g.: 1) then calculate in function and return 3 values- let’s call returned values are: a1,a2,a3 then I have add in separate matrix like in here:
tempA=[a1,…]
tempB=[a2,…]
tempC=[a3,…]
How I can do it with numpy in Python?