I have a 3d array of dimension (1000, 300, 3), my_3d_array.
I want to modify each sample if this array then replace the old version with the modified one. In another word, I want to take the 1st example (300, 3) (lets called it old sample) apply some modification to it by calling a function called my_function, then the obtained new one will replace the old sample in my_3d_array, and so on. How can we do it please?