title: What does "ValueError: object too deep for desired array" mean and how to fix it?
body: <p>I'm trying to do this:</p>
  <pre><code>h = [0.2, 0.2, 0.2, 0.2, 0.2]
  
  Y = np.convolve(Y, h, &quot;same&quot;)
  </code></pre>
  <p><code>Y</code> looks like this:</p>
  <p><img src="https://i.stack.imgur.com/bVYmZ.jpg" alt="screenshot" /></p>
  <p>While doing this I get this error:</p>
  <pre class="lang-none prettyprint-override"><code>ValueError: object too deep for desired array
  </code></pre>
  <p>Why is this?</p>
  <p>My guess is because somehow the <code>convolve</code> function does not see <code>Y</code> as a 1D array.</p>