title: How to convert sample program in tensorflow efficiently?
body: <p>My Code :</p>
  <pre><code>  data = [0, 2]
    f = numpy.array([[[1, 2], [3, 4]],
         [[4, 5], [7, 5]], 
         [[6, 3], [7, 9]]])
    l = []
    for i in data :
      l.append(f[i])
    return np.maximum.reduce(l)  
  </code></pre>
  <p>Output :
  [[6, 3], [7, 9]] Element wise maximum between f[0] and f[2] as data is 0 and 2<br />
  All i need is to implement the same code in tensorflow format using tf.while_loop and any other tensorflow function</p>