Skip to content

Commit

Permalink
Merge pull request aliutkus#22 from haoheliu/master
Browse files Browse the repository at this point in the history
Fix bug for bsseval
  • Loading branch information
aliutkus authored Mar 1, 2021
2 parents 8b9fe8d + cb94572 commit 06a1473
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 06a1473

Please sign in to comment.