title: tensorflow: how to perform element-wise multiplication between two sparse matrix
body: <p>I have two sparse matrices declared using the <code>tf.sparse_placeholder</code>. I need to perform the element-wise multiplication between the two matrices. But I cannot find such an implementation in <code>tensorflow</code>. The most related function is <code>tf.sparse_tensor_dense_matmul</code>, but this is a function performing matrix multiplication between one sparse matrix and one dense matrix.</p>
  
  <p>What I hope to find is to performing <strong>element-wise multiplication between two sparse matrices</strong>. Is there any implementation of this in <code>tensorflow</code>?</p>
  
  <p>I show the following example of performing multiplication between dense matrices. I'm looking forward to seeing a solution.</p>
  
  <pre><code>import tensorflow as tf
  import numpy as np
  
  # Element-wise multiplication, two dense matrices
  A = tf.placeholder(tf.float32, shape=(100, 100))
  B = tf.placeholder(tf.float32, shape=(100, 100))
  C = tf.multiply(A, B)
  sess = tf.InteractiveSession()
  RandA = np.random.rand(100, 100)
  RandB = np.random.rand(100, 100)
  print sess.run(C, feed_dict={A: RandA, B: RandB})
  
  # matrix multiplication, A is sparse and B is dense
  A = tf.sparse_placeholder(tf.float32)
  B = tf.placeholder(tf.float32, shape=(5,5))
  C = tf.sparse_tensor_dense_matmul(A, B)
  sess = tf.InteractiveSession()
  indices = np.array([[3, 2], [1, 2]], dtype=np.int64)
  values = np.array([1.0, 2.0], dtype=np.float32)
  shape = np.array([5,5], dtype=np.int64)
  Sparse_A = tf.SparseTensorValue(indices, values, shape)
  RandB = np.ones((5, 5))
  print sess.run(C, feed_dict={A: Sparse_A, B: RandB})
  </code></pre>
  
  <p>Thank you very much!!!</p>