public static long [ ] getMaxShape ( INDArray ... inputs ) { if ( inputs == null ) return null ; else if ( inputs . length < 2 ) return inputs [ 0 ] . shape ( ) ; else { long [ ] currMax = inputs [ 0 ] . shape ( ) ; for ( int i = 1 ; i < inputs . length ; i ++ ) { if ( inputs [ i ] == null ) { continue ; } if ( ArrayUtil . prod ( currMax ) < inputs [ i ] . length ( ) ) { currMax = inputs [ i ] . shape ( ) ; } } return currMax ; } }
Return the shape of the largest length array based on the input