Remove consecutive duplicates in a NumPy array
<p>I would like to remove duplicates which follow each other, but not duplicates along the whole array. Also, I want to keep the ordering unchanged.</p>

<p>So if the input is <code>[0 0 1 3 2 2 3 3]</code> the output should be <code>[0 1 3 2 3]</code></p>

<p>I found a way using <code>itertools.groupby()</code> but I am looking for a faster NumPy solution.</p>