def METHOD_NAME(
    data: List[np.ndarray],
    axis: int = 0,
    is_right_pad: bool = True,
) -> List[np.ndarray]:
    assert isinstance(data[0], np.ndarray)
    # MxNet causes a segfault when persisting 0-length arrays. As such,
    # we add a dummy pad of length 1 to 0-length dims.
    max_len = max(1, functools.reduce(max, (x.shape[axis] for x in data)))
    return [
        pad_to_size(x, max_len, axis, is_right_pad=is_right_pad) for x in data
    ]