title: Tensorflow - Conditionally assign value to a tensor
body: <p>I have 2 tensors.</p>
  
  <pre><code>t1 = tf.constant([b'hi', b'#hh', b'hello', 'there', '#ii'], dtype=tf.string)
  
  t2 = tf.constant([1,2,3], dtype = tf.int64)
  </code></pre>
  
  <p>How can I replace the elements, initialized with #, in t1 to be 0 and all other elements in t1 to be the numbers in t2?</p>
  
  <p>Specifically, the output should be [1, 0, 2, 3, 0].</p>
  
  <p>Thanks,</p>