jaakkopasanen/Impulcifer

Single Speaker Recording Issue

rpx91 opened this issue · 3 comments

rpx91 commented

Trying out the single speaker method for a very near field (arms length) measurement but getting the following error:

(venv) c:\Users\dushy\Impulcifer>python impulcifer.py --test_signal="data/sweep-6.15s-48000Hz-32bit-2.93Hz-24000Hz.pkl" --dir_path="data/my_hrir" --channel_balance=trend
Traceback (most recent call last):
  File "impulcifer.py", line 492, in <module>
    main(**create_cli())
  File "impulcifer.py", line 74, in main
    write_readme(os.path.join(dir_path, 'README.md'), hrir, fs)
  File "impulcifer.py", line 440, in write_readme
    f'{ir.reverberation_time(target_level=-60) * 1000:.1f} ms'
TypeError: unsupported operand type(s) for *: 'NoneType' and 'int'

I've uploaded my speaker and headphone recording here.

Thanks. I'll investigate. Some the algorithms are quite simple and might not be able to handle all edge cases. Reverberation time calculation is probably one.

rpx91 commented

I re-did the recordings - I had a hunch they were too low and I left too much headroom. When I recorded louder it processes fine.

This is solved now. The noise floor in these recordings is above -60dB on some speaker-ear pairs so the -60dB level for RT60 was never reached. There was a bug too in my code which caused a crash in some cases. Now the RT60 in README.md says "-" when -60dB cannot be reached and does not throw an error anymore.