title: python - KL divergence on numpy arrays with different lengths
body: <p>I am using the SciPy implementation of KL-divergence ([<a href="http://docs.scipy.org/doc/scipy-dev/reference/generated/scipy.stats.entropy.html]" rel="noreferrer">http://docs.scipy.org/doc/scipy-dev/reference/generated/scipy.stats.entropy.html]</a>) for two different numpy arrays.</p>
  
  <p>The first one , lets say <em>"base_freq"</em> has a standard length of 2000
  The second one, <em>"test_freq"</em> length can take different values depending on the sample. So let's say that its length is 8000.</p>
  
  <p>How can I compute the KL divergence when these two do not have the same length???</p>
  
  <p>My thought was to break down the second array (<em>"test_freq"</em>) to a number of arrays with 2000 length. But how is this done??
  And what happens when the <em>"test_freq"</em> gets a sample of 250 length ?</p>