title: tensorflow conditions: check if the values inside the tensor is zero or greater
body: <p>If I have the following tensor:</p>
  
  <pre><code>pmi=tf.constant([[1.5,0.0,0.0],[0.0,0.0,2.9],[1.001,5,1]])
  </code></pre>
  
  <p>I want to have a corresponding tensor Fpmi (or a scaler) such that when the element inside the PMI tensor greater than 0 the element in the Fpmi should be one and when the element in the pmi=0 the element in the Fpmi =0.0005.</p>
  
  <p>I would appreciate any advice.</p>