Demo entry 6777045

K

   

Submitted by anonymous on Dec 06, 2018 at 17:58
Language: Python 3. Code size: 443 Bytes.

f = pyedflib.EdfReader("n16.edf")
n = f.signals_in_file
signal_labels = f.getSignalLabels()

n_min = f.getNSamples()[0]
sigbufs = [np.zeros(f.getNSamples()[i]) for i in np.arange(n)]

for i in np.arange(n):
	sigbufs[i] = f.readSignal(i)
    
f._close()
del f

n_pltot = np.min((n_min, 3000))
sigbufs_pltot = np.zeros((n, n_pltot))
for i in np.arange(n):
    sigbufs_pltot[i,:] = sigbufs[i][:n_pltot]
x = sigbufs_pltot[0][:] 

This snippet took 0.01 seconds to highlight.

Back to the Entry List or Home.

Delete this entry (admin only).