def testFileProxy2(filename):
    '[summary]\n\n    Args:\n        filename ([type]): [description]\n    '
    from mindaffectBCI.decoder.FileProxyHub import FileProxyHub
    U = FileProxyHub(filename)
    fs = 200
    fs_out = 200
    ppfn = butterfilt_and_downsample(order=4, stopband=((45, 65), (0, 3), (25, (- 1))), fs=fs, fs_out=fs_out)
    ui = UtopiaDataInterface(data_preprocessor=ppfn, stimulus_preprocessor=None, mintime_ms=0, U=U, fs=fs)
    ui.connect()
    data = []
    stim = []
    emptycount = 0
    while True:
        (newmsg, nsamp, nstim) = ui.update()
        if ((len(newmsg) == 0) and (nsamp == 0) and (nstim == 0)):
            emptycount = (emptycount + 1)
            if (emptycount > 10):
                break
        else:
            emptycount = 0
        if (nsamp > 0):
            data.append(ui.data_ringbuffer[(- nsamp):, :].copy())
        if (nstim > 0):
            stim.append(ui.stimulus_ringbuffer[(- nstim):, :].copy())
    data = np.vstack(data)
    stim = np.vstack(stim)
    import pickle
    if (ppfn is None):
        pickle.dump(dict(data=data, stim=stim), open('raw_udi.pk', 'wb'))
    else:
        pickle.dump(dict(data=data, stim=stim), open('pp_udi.pk', 'wb'))
[summary]

Args:
    filename ([type]): [description]
def testFileProxy2(filename):
    '[summary]\n\n    Args:\n        filename ([type]): [description]\n    '
    from mindaffectBCI.decoder.FileProxyHub import FileProxyHub
    U = FileProxyHub(filename)
    fs = 200
    fs_out = 200
    ppfn = butterfilt_and_downsample(order=4, stopband=((45, 65), (0, 3), (25, (- 1))), fs=fs, fs_out=fs_out)
    ui = UtopiaDataInterface(data_preprocessor=ppfn, stimulus_preprocessor=None, mintime_ms=0, U=U, fs=fs)
    ui.connect()
    data = []
    stim = []
    emptycount = 0
    while True:
        (newmsg, nsamp, nstim) = ui.update()
        if ((len(newmsg) == 0) and (nsamp == 0) and (nstim == 0)):
            emptycount = (emptycount + 1)
            if (emptycount > 10):
                break
        else:
            emptycount = 0
        if (nsamp > 0):
            data.append(ui.data_ringbuffer[(- nsamp):, :].copy())
        if (nstim > 0):
            stim.append(ui.stimulus_ringbuffer[(- nstim):, :].copy())
    data = np.vstack(data)
    stim = np.vstack(stim)
    import pickle
    if (ppfn is None):
        pickle.dump(dict(data=data, stim=stim), open('raw_udi.pk', 'wb'))
    else:
        pickle.dump(dict(data=data, stim=stim), open('pp_udi.pk', 'wb'))