def signal_window_spliter(signal, window_size, overlap):
    """Splits the signal into windows

    Parameters
    ----------
    signal : nd-array or pandas DataFrame
        input signal
    window_size :
        number of points of window size
    overlap :
        percentage of overlap, value between 0 and 1

    Returns
    -------
    list
        list of signal windows

    """

    step = int(round(window_size)) if overlap == 0 else int(round(window_size * (1 - overlap)))
    return [signal[i:i + window_size] for i in range(0, len(signal) - window_size, step)]