Hello everybody!
I am wondering how we can average on the second dimension of a tensor without taking zero arrays into account. See below:
A = (tensor) [ [ [1, 2, 3], [0, 0 , 0], [3, 4, 5] ],
               [ [0, 0, 0], [5, 6, 7], [0, 1, 2] ]  
              ]

Avg(A) = (tensor) [  [ [2, 3, 4] ], 
                     [ [2.5, 3.5, 4.5] ]  
                  ]