Skip to content

Commit

Permalink
Fix bug for bsseval
Browse files Browse the repository at this point in the history
  • Loading branch information
bdmgxl committed Feb 24, 2021
1 parent 8b9fe8d commit cb94572
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions speechmetrics/relative/bsseval.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,9 @@ def test_window(self, audios, rate):
from museval.metrics import bss_eval
if len(audios) != 2:
raise ValueError('BSSEval needs a reference and a test signals.')
result = bss_eval(reference_sources=audios[1].T,
estimated_sources=audios[0].T,

result = bss_eval(reference_sources=audios[1][None,...], # shape: [nsrc, nsample, nchannels]
estimated_sources=audios[0][None,...],
window=self.bss_window * rate,
hop=self.bss_hop * rate)
return {'sdr': result[0], 'isr': result[1], 'sar': result[3]}
Expand Down

0 comments on commit cb94572

Please sign in to comment.