How do I dissolve a pattern in a numpy array?,"array([[0, 1, 0], [1, 1, 1], [0, 1, 0]])"