Splitting Numpy array based on value
<p>Suppose I have this NumPy array: </p>

<pre><code>a = np.array([0, 3, 5, 5, 0, 10, 14, 15, 56, 0, 12, 23, 45, 23, 12, 45, 
              0, 1, 0, 2, 3, 4, 0, 0 ,0])
</code></pre>

<p>I would like to print all the numbers between 0s and automatically add them to a new <code>np.array</code> (see below):</p>

<pre><code>a1=[3, 5, 5]
a2=[10, 14, 15, 56]
a3=[12, 23, 45, 23, 12, 45]
a4=[1]
a5=[2, 3, 4]
</code></pre>

<p>Is there a built-in function to do this?</p>