Loading scripts/pyaudio3dtools/audioarray.py +1 −2 Original line number Diff line number Diff line Loading @@ -486,7 +486,6 @@ def compare( if get_ssnr: # length of segment is always 20ms len_seg = int(0.02 * fs) print(len_seg, ref.shape, test.shape) result["SSNR"] = ssnr( ref, test, Loading Loading @@ -731,7 +730,7 @@ def ssnr( # if the reference signal was outside the thresholds for all segments in a channel, segment_counter is zero # for that channel and the division here would trigger a warning. We supress the warning and later # set the SSNR for those channels to nan manually instead (overwriting later is simply easier than adding ifs here) with warnings.catch_warnings(): with warnings.catch_warnings(action='ignore'): ssnr = np.round( 10 * np.log10(10 ** (np.sum(ss, axis=0) / segment_counter) - 1), 2 ) Loading tests/cmp_pcm.py +0 −1 Original line number Diff line number Diff line Loading @@ -152,7 +152,6 @@ def cmp_pcm( odg = float(match_odg.groups()[0]) msg = f"Channel {n} ODG: {odg}" reason += " - " + msg print(msg) if get_odg_bin: odg_files = {} Loading Loading
scripts/pyaudio3dtools/audioarray.py +1 −2 Original line number Diff line number Diff line Loading @@ -486,7 +486,6 @@ def compare( if get_ssnr: # length of segment is always 20ms len_seg = int(0.02 * fs) print(len_seg, ref.shape, test.shape) result["SSNR"] = ssnr( ref, test, Loading Loading @@ -731,7 +730,7 @@ def ssnr( # if the reference signal was outside the thresholds for all segments in a channel, segment_counter is zero # for that channel and the division here would trigger a warning. We supress the warning and later # set the SSNR for those channels to nan manually instead (overwriting later is simply easier than adding ifs here) with warnings.catch_warnings(): with warnings.catch_warnings(action='ignore'): ssnr = np.round( 10 * np.log10(10 ** (np.sum(ss, axis=0) / segment_counter) - 1), 2 ) Loading
tests/cmp_pcm.py +0 −1 Original line number Diff line number Diff line Loading @@ -152,7 +152,6 @@ def cmp_pcm( odg = float(match_odg.groups()[0]) msg = f"Channel {n} ODG: {odg}" reason += " - " + msg print(msg) if get_odg_bin: odg_files = {} Loading