[Mne_analysis] Crop function is behaving weirdly

Zuhaib Asad 19100201 at lums.edu.pk
Wed Nov 20 10:58:33 EST 2019
Search archives:

        External Email - Use Caution        

Hi All,

I was trying to crop .EDF data into a ten minute window with this code snippet:

if max(raw.times) < 660:
    raw.crop(tmin=60, tmax=max(raw.times))
else:
    raw.crop(tmin=60, tmax=660)

but what happens it, works for first iteration of loop normally but behaves weirdly for second iteration. (I am reading .EDF file in a loop .)
These are the info about how data loaded
1st Iteration:
before cropping :
<RawEDF  |  000007135.EDF, n_channels x n_times : 41 x 241000 (1205.0 sec), ~75.5 MB, data loaded>
After cropping :
<RawEDF  |  000007135.EDF, n_channels x n_times : 41 x 120001 (600.0 sec), ~37.6 MB, data loaded>

2nd Iteration:
Before cropping :
<RawEDF  |  6969.EDF, n_channels x n_times : 41 x 616000 (1232.0 sec), ~192.8 MB, data loaded>
After cropping :
<RawEDF  |  6969.EDF, n_channels x n_times : 41 x 300003 (1500.0 sec), ~93.9 MB, data loaded>

Please guide me through and ask me if any other thing is required to solve this.
Thanks!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.nmr.mgh.harvard.edu/pipermail/mne_analysis/attachments/20191120/06fab484/attachment-0001.html 


More information about the Mne_analysis mailing list