title: pytorch: how to multiply 3d tensor with 2d tensor
body: <p>I got a 3D tensor <code>three</code> and a 2D tensor <code>two</code>, which need to be multiplied. For example, the dimensions are:</p>
  <pre><code>three.shape = 4x100x700
  two.shape = 4x100
  </code></pre>
  <p>Output shape should be:</p>
  <pre><code>output.shape = 4x100x700
  </code></pre>
  <p>So basically, in <code>output[a,b]</code> there should be 700 scalars which were computed by multiplying all 700 scalars from <code>three[a,b]</code> with the single scalar from <code>two[a,b]</code>.</p>