Currently, creating a new Edf with e.g. 8001 samples at 1000Hz and a data_record_duration of 0.001 fails, even though the signal duration of 8.001 would be divisible by 0.001. This PR introduces a fallback using decimal.Decimal to make the calculation of num_data_records more robust.
Currently, creating a new Edf with e.g. 8001 samples at 1000Hz and a
data_record_duration
of 0.001 fails, even though the signal duration of 8.001 would be divisible by 0.001. This PR introduces a fallback usingdecimal.Decimal
to make the calculation ofnum_data_records
more robust.