code: def _interleave(a, b):
      
      b = np.column_stack([b]) # Turn b into a column array.
      nx, ny = b.shape
      c = np.zeros((nx + 1, ny + 1))
      c[:, 0] = a
      c[:-1, 1:] = b
      return c.ravel()[:-(c.shape[1] - 1)]
docs: Interleave arrays a and b; b may have multiple columns and must be
      shorter by 1.