Loading scripts/pyaudio3dtools/audioarray.py +0 −4 Original line number Diff line number Diff line Loading @@ -578,8 +578,4 @@ def ssnr( ssnr = np.round(10 * np.log10(10 ** (np.sum(ss, axis=0) / segment_counter) - 1), 2) ssnr[segment_counter == 0] = -np.inf # set to zero for channels with no diff (this handles e.g. the corner-case of an all-zero channel in both ref and dut) zero_diff_mask = np.asarray([np.all(diff_sig_norm[:, c] == 0) for c in range(ref_sig.shape[1])]) ssnr[zero_diff_mask] = 0 return ssnr Loading
scripts/pyaudio3dtools/audioarray.py +0 −4 Original line number Diff line number Diff line Loading @@ -578,8 +578,4 @@ def ssnr( ssnr = np.round(10 * np.log10(10 ** (np.sum(ss, axis=0) / segment_counter) - 1), 2) ssnr[segment_counter == 0] = -np.inf # set to zero for channels with no diff (this handles e.g. the corner-case of an all-zero channel in both ref and dut) zero_diff_mask = np.asarray([np.all(diff_sig_norm[:, c] == 0) for c in range(ref_sig.shape[1])]) ssnr[zero_diff_mask] = 0 return ssnr