File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -100,7 +100,8 @@ def _parse_header(self):
100
100
for ch_idx , sig_dict in enumerate (self .signal_headers ):
101
101
ch_name = sig_dict ["label" ]
102
102
chan_id = ch_idx
103
- sr = sig_dict ["sample_rate" ] # Hz
103
+ # pyedf >= 0.1.39 uses sample_frequency, pyedf < 0.1.39 uses sample_rate
104
+ sr = sig_dict .get ("sample_frequency" ) or sig_dict .get ("sample_rate" ) # Hz
104
105
dtype = "int16" # assume general int16 based on edf documentation
105
106
units = sig_dict ["dimension" ]
106
107
physical_range = sig_dict ["physical_max" ] - sig_dict ["physical_min" ]
@@ -160,6 +161,7 @@ def _parse_header(self):
160
161
"label" ,
161
162
"dimension" ,
162
163
"sample_rate" ,
164
+ "sample_frequency" ,
163
165
"physical_min" ,
164
166
"physical_max" ,
165
167
"digital_min" ,
You can’t perform that action at this time.
0 commit comments