audio
audio copied to clipboard
Add power_to_db and db_to_power.
🚀 The feature
Convert power spectrogram into db and the reverse.
Motivation, pitch
I'm working on replacing my Librosa usage with torchaudio and this is a missing function in torchaudio that I would like to contribute.
Alternatives
https://librosa.org/doc/0.10.1/generated/librosa.power_to_db.html#librosa.power_to_db https://librosa.org/doc/0.10.1/generated/librosa.db_to_power.html#librosa.db_to_power
Additional context
No response
Hi @will-rice
Thanks for the suggestion. This is a reasonable addition, so feel free to open a PR.
@mthrok I came across this while working on the tests and realized that the power_to_db functionality is already available. If it would be useful to separate the functions I could work on that, but otherwise it's probably safe to close this issue.