You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When running tnr_ecma_tv routine with the attached script and signal (runMoqito.py and signal.txt), I got the following issue:
""" _python3.10/site-packages/mosqito/sq_metrics/tonality/tone_to_noise_ecma/tnr_main_calc.py:188: RuntimeWarning: invalid value encountered in log10
Ln = 10 * np.log10(10 ** (Ltot / 10) - 10 ** (Lt / 10)) + 10 * np.log10(
"""
I have "played" a bit with the code and it seems that the routine is sensitive to the algorithm of peak detection _peak_level.
When I changed the 10dB criterium to 9.75, the exception disappear.
The exception is raised when Lt is larger than Ltot
The issue is machine dependent (some machine do not raise exception)
Thank for your help,
Regards
The text was updated successfully, but these errors were encountered:
Thanks for noticing this ! Indeed this error is sometimes raised, depending on the input spectrum. Please note that this adjustment of the peak level is not part of the ECMA, it was added to overcome the level approximation due to the spectrum resolution. We'll add a little test to check that Lt<Ltot in the next release, and explore this correction deeper to find a better model.
Feel free to contribute to MOSQITO if you have an idea :)
Hello,
runMoqito.py.txt
signal.txt
When running tnr_ecma_tv routine with the attached script and signal (runMoqito.py and signal.txt), I got the following issue:
"""
_python3.10/site-packages/mosqito/sq_metrics/tonality/tone_to_noise_ecma/tnr_main_calc.py:188: RuntimeWarning: invalid value encountered in log10
Ln = 10 * np.log10(10 ** (Ltot / 10) - 10 ** (Lt / 10)) + 10 * np.log10(
"""
I have "played" a bit with the code and it seems that the routine is sensitive to the algorithm of peak detection _peak_level.
When I changed the 10dB criterium to 9.75, the exception disappear.
The exception is raised when Lt is larger than Ltot
The issue is machine dependent (some machine do not raise exception)
Thank for your help,
Regards
The text was updated successfully, but these errors were encountered: