Skip to content

Commit

Permalink
Fix magnitude_to_decibel docs to reference librosa (#128)
Browse files Browse the repository at this point in the history
The function `kapre.backend.magnitude_to_decibel` is actually an equivalent to `librosa.power_to_db` instead of `librosa.amplitude_to_db`.
  • Loading branch information
jamesmishra committed Nov 14, 2021
1 parent e8c52e1 commit f25fdab
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion kapre/backend.py
Expand Up @@ -71,7 +71,7 @@ def magnitude_to_decibel(x, ref_value=1.0, amin=1e-5, dynamic_range=80.0):
"""A function that converts magnitude to decibel scaling.
In essence, it runs `10 * log10(x)`, but with some other utility operations.
Similar to `librosa.amplitude_to_db` with `ref=1.0` and `top_db=dynamic_range`
Similar to `librosa.power_to_db` with `ref=1.0` and `top_db=dynamic_range`
Args:
x (`Tensor`): float tensor. Can be batch or not. Something like magnitude of STFT.
Expand Down

0 comments on commit f25fdab

Please sign in to comment.