Closed WenJ2018 closed 6 years ago
I think there have been some updates to the pandas
and/or numpy
packages, which affects the code that I used several months ago.
Can you install the following version:
numpy (1.11.1) pandas (0.18.1)
and have a try again?
Thanks
Thanks for replying. I used pip install pandas which I suppose would install the latest version. How can I specify the version numbers?
I used pip install numpy==1.11.1 which seemed to have worked. For numpy (1.11.1), it complained a lot but seems still ok. For pandas(0.18.1), it failed to install. If I use numpy (1.11.1) and pandas (0.23.0), I got the same error message about raw.to_data_frame().
You get the same error because you still use the new pandas version.
I am not sure why you got the error while installing the pandas version 0.18.1, but that's the installation problem (not the code).
Please refer to the following website: https://stackoverflow.com/questions/5226311/installing-specific-package-versions-with-pip
Hope this is helpful
Hello, Thanks for the link. I was able to install pandas-0.18.1 now, after installing visual studio 2015 build tools. But I still get the same error message about raw.to_data_frame(). So I checked numpy again. It seems that numpy 1.11.1 is too old for my tensorflow. Do you know which tensorflow version is needed?
Just to add that if I changed raw_ch_df = raw.to_data_frame(scale_time=100.0)[select_ch]
intoraw_ch_df = raw.to_data_frame()[select_ch]
It would pass that line but shows the following:python prepare_physionet.py --data_dir data --output_dir data/eeg_fpz_cz --select_ch "EEG Fpz-Cz"
Extracting EDF parameters from data\SC4001E0-PSG.edf...
EDF file detected
Setting channel info structure...
Creating raw.info structure...
Reading 0 ... 7949999 = 0.000 ... 79499.990 secs...
Converting time column to int64...
Traceback (most recent call last):
File "prepare_physionet.py", line 218, in
I decided not to change versions but instead to modify code so that the updated pandas and numpy would work. A lot to modify but I managed to run through the following without errors. They created eeg_fpz_cz and eeg_pz_oz subfolders under data folder. Should I see any files inside these subfolders? Thanks. python prepare_physionet.py --data_dir data --output_dir data/eeg_fpz_cz --select_ch 'EEG Fpz-Cz' python prepare_physionet.py --data_dir data --output_dir data/eeg_pz_oz --select_ch 'EEG Pz-Oz'
From: Wen <wj_lg@yahoo.com>
To: akaraspt/deepsleepnet reply@reply.github.com Sent: Tuesday, May 29, 2018 1:02 PM Subject: Re: [akaraspt/deepsleepnet] raw.to_data_frame() error (#13)
Just to add that if I changed raw_ch_df = raw.to_data_frame(scale_time=100.0)[select_ch]
intoraw_ch_df = raw.to_data_frame()[select_ch]
It would pass that line but shows the following:python prepare_physionet.py --data_dir data --output_dir data/eeg_fpz_cz --select_ch "EEG Fpz-Cz"
Extracting EDF parameters from data\SC4001E0-PSG.edf...
EDF file detected
Setting channel info structure...
Creating raw.info structure...
Reading 0 ... 7949999 = 0.000 ... 79499.990 secs...
Converting time column to int64...
Traceback (most recent call last):
File "prepare_physionet.py", line 218, in
I looked upon the mne documentation on to_data_frame(). The parameter name must have got updated. By replacing scale_time with scaling_time resolved the issue for me.
Link to the documentation : https://martinos.org/mne/dev/generated/mne.io.RawArray.html#mne.io.RawArray.to_data_frame
Hello, I got the following error on PC in Windows 10.
python prepare_physionet.py --data_dir data --output_dir data/eeg_fpz_cz --select_ch "EEG Fpz-Cz" Extracting EDF parameters from data\SC4001E0-PSG.edf... EDF file detected Setting channel info structure... Creating raw.info structure... Reading 0 ... 7949999 = 0.000 ... 79499.990 secs... Traceback (most recent call last): File "prepare_physionet.py", line 218, in main() File "prepare_physionet.py", line 95, in main raw_ch_df = raw.to_data_frame(scale_time=100.0)[select_ch] TypeError: to_data_frame() got an unexpected keyword argument 'scale_time'
hai, have you sloved this?
Hello, I got the following error on PC in Windows 10.
python prepare_physionet.py --data_dir data --output_dir data/eeg_fpz_cz --select_ch "EEG Fpz-Cz" Extracting EDF parameters from data\SC4001E0-PSG.edf... EDF file detected Setting channel info structure... Creating raw.info structure... Reading 0 ... 7949999 = 0.000 ... 79499.990 secs... Traceback (most recent call last): File "prepare_physionet.py", line 218, in main() File "prepare_physionet.py", line 95, in main raw_ch_df = raw.to_data_frame(scale_time=100.0)[select_ch] TypeError: to_data_frame() got an unexpected keyword argument 'scale_time'
I've got the same error
You may need to install : mne=='0.20.7 see: https://github.com/emadeldeen24/ADAST/issues/2
You may need to install : mne=='0.20.7 see: emadeldeen24/ADAST#2
Thank you! I 've got the same error ,I did what you said and solved the problem!
Hello, I got the following error on PC in Windows 10.