Loading tests/renderer/test_renderer_be_comparison.py +0 −170 Original line number Diff line number Diff line Loading @@ -56,18 +56,6 @@ def test_ambisonics_binaural_static(test_info, in_fmt, out_fmt, framing_5ms): ) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_AMBI) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_ambisonics_binaural_static_with_binary_hrir(test_info, in_fmt, out_fmt, framing_5ms): compare_renderer_vs_renderer_with_binary_hrir( test_info, in_fmt, out_fmt, framing_5ms=(framing_5ms == "5ms"), is_comparetest=True, ) @pytest.mark.parametrize("trj_file", HR_TRAJECTORIES_TO_TEST) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_AMBI) Loading @@ -83,21 +71,6 @@ def test_ambisonics_binaural_headrotation( test_info, in_fmt, out_fmt, trj_file, ) @pytest.mark.parametrize("trj_file", HR_TRAJECTORIES_TO_TEST) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_AMBI) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_ambisonics_binaural_headrotation_with_binary_hrir(test_info, in_fmt, out_fmt, trj_file, framing_5ms): compare_renderer_vs_renderer_with_binary_hrir( test_info, in_fmt, out_fmt, trj_file=HR_TRAJECTORY_DIR.joinpath(f"{trj_file}.csv"), framing_5ms=(framing_5ms == "5ms"), is_comparetest=True, ) """ Multichannel """ Loading @@ -123,22 +96,6 @@ def test_multichannel_binaural_static(test_info, in_fmt, out_fmt, framing_5ms): ) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_MC) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_multichannel_binaural_static_with_binary_hrir(test_info, in_fmt, out_fmt, framing_5ms): if in_fmt in ["MONO", "STEREO"]: pytest.skip("MONO or STEREO to Binaural rendering unsupported") compare_renderer_vs_renderer_with_binary_hrir( test_info, in_fmt, out_fmt, framing_5ms=(framing_5ms == "5ms"), is_comparetest=True, ) @pytest.mark.parametrize("trj_file", HR_TRAJECTORIES_TO_TEST) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_MC) Loading @@ -159,26 +116,6 @@ def test_multichannel_binaural_headrotation( ) @pytest.mark.parametrize("trj_file", HR_TRAJECTORIES_TO_TEST) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_MC) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_multichannel_binaural_headrotation_with_binary_hrir( test_info, in_fmt, out_fmt, trj_file, framing_5ms ): if in_fmt in ["MONO", "STEREO"]: pytest.skip("MONO or STEREO to Binaural rendering unsupported") compare_renderer_vs_renderer_with_binary_hrir( test_info, in_fmt, out_fmt, trj_file=HR_TRAJECTORY_DIR.joinpath(f"{trj_file}.csv"), framing_5ms=(framing_5ms == "5ms"), is_comparetest=True, ) """ ISM """ Loading Loading @@ -210,26 +147,6 @@ def test_ism_binaural_static(test_info, in_fmt, out_fmt, framing_5ms): ) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_ISM) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_ism_binaural_static_with_binary_hrir(test_info, in_fmt, out_fmt, framing_5ms): try: in_meta_files = FORMAT_TO_METADATA_FILES[in_fmt] except: in_meta_files = None compare_renderer_vs_renderer_with_binary_hrir( test_info, in_fmt, out_fmt, in_meta_files=in_meta_files, framing_5ms=(framing_5ms == "5ms"), is_comparetest=True, ) @pytest.mark.parametrize("trj_file", HR_TRAJECTORIES_TO_TEST) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_ISM) Loading @@ -252,28 +169,6 @@ def test_ism_binaural_headrotation(test_info, in_fmt, out_fmt, trj_file, framing ) @pytest.mark.parametrize("trj_file", HR_TRAJECTORIES_TO_TEST) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_ISM) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_ism_binaural_headrotation_with_binary_hrir(test_info, in_fmt, out_fmt, trj_file, framing_5ms): try: in_meta_files = FORMAT_TO_METADATA_FILES[in_fmt] except: in_meta_files = None compare_renderer_vs_renderer_with_binary_hrir( test_info, in_fmt, out_fmt, trj_file=HR_TRAJECTORY_DIR.joinpath(f"{trj_file}.csv"), in_meta_files=in_meta_files, framing_5ms=(framing_5ms == "5ms"), is_comparetest=True, ) """ MASA """ Loading Loading @@ -301,22 +196,6 @@ def test_masa_binaural_static(test_info, in_fmt, out_fmt, framing_5ms): ) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_MASA) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_masa_binaural_static_with_binary_hrir(test_info, in_fmt, out_fmt, framing_5ms): if out_fmt in ["BINAURAL_ROOM_IR", "BINAURAL_ROOM_REVERB"]: pytest.skip("Skipping binaural room outputs for MASA as unimplemented.") compare_renderer_vs_renderer_with_binary_hrir( test_info, in_fmt, out_fmt, in_meta_files=FORMAT_TO_METADATA_FILES[in_fmt], framing_5ms=(framing_5ms == "5ms"), ) @pytest.mark.parametrize("trj_file", HR_TRAJECTORIES_TO_TEST) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_MASA) Loading @@ -335,24 +214,6 @@ def test_masa_binaural_headrotation(test_info, in_fmt, out_fmt, trj_file, framin ) @pytest.mark.parametrize("trj_file", HR_TRAJECTORIES_TO_TEST) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_MASA) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_masa_binaural_headrotation_with_binary_hrir(test_info, in_fmt, out_fmt, trj_file, framing_5ms): if out_fmt in ["BINAURAL_ROOM_IR", "BINAURAL_ROOM_REVERB"]: pytest.skip("Skipping binaural room outputs for MASA as unimplemented.") compare_renderer_vs_renderer_with_binary_hrir( test_info, in_fmt, out_fmt, trj_file=HR_TRAJECTORY_DIR.joinpath(f"{trj_file}.csv"), in_meta_files=FORMAT_TO_METADATA_FILES[in_fmt], framing_5ms=(framing_5ms == "5ms"), ) """ Custom loudspeaker layouts """ Loading Loading @@ -402,19 +263,6 @@ def test_custom_ls_input_binaural(test_info, in_layout, out_fmt, framing_5ms): ) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_layout", CUSTOM_LS_TO_TEST) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_custom_ls_input_binaural_with_binary_hrir(test_info, in_layout, out_fmt, framing_5ms): compare_renderer_vs_renderer_with_binary_hrir( test_info, CUSTOM_LAYOUT_DIR.joinpath(f"{in_layout}.txt"), out_fmt, framing_5ms=(framing_5ms == "5ms"), is_comparetest=True, ) @pytest.mark.parametrize("trj_file", HR_TRAJECTORIES_TO_TEST) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_layout", CUSTOM_LS_TO_TEST) Loading @@ -432,24 +280,6 @@ def test_custom_ls_input_binaural_headrotation( ) @pytest.mark.parametrize("trj_file", HR_TRAJECTORIES_TO_TEST) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_layout", CUSTOM_LS_TO_TEST) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_custom_ls_input_binaural_headrotation_with_binary_hrir( test_info, in_layout, out_fmt, trj_file, framing_5ms ): compare_renderer_vs_renderer_with_binary_hrir( test_info, CUSTOM_LAYOUT_DIR.joinpath(f"{in_layout}.txt"), out_fmt, trj_file=HR_TRAJECTORY_DIR.joinpath(f"{trj_file}.csv"), framing_5ms=(framing_5ms == "5ms"), is_comparetest=True, ) """ Metadata / scene description input """ Loading tests/renderer/test_renderer_with_or_without_binary_hrir_BE_comparison.py 0 → 100644 +220 −0 Original line number Diff line number Diff line #!/usr/bin/env python3 """ (C) 2022-2023 IVAS codec Public Collaboration with portions copyright Dolby International AB, Ericsson AB, Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other contributors to this repository. All Rights Reserved. This software is protected by copyright law and by international treaties. The IVAS codec Public Collaboration consisting of Dolby International AB, Ericsson AB, Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other contributors to this repository retain full ownership rights in their respective contributions in the software. This notice grants no license of any kind, including but not limited to patent license, nor is any license granted by implication, estoppel or otherwise. Contributors are required to enter into the IVAS codec Public Collaboration agreement before making contributions. This software is provided "AS IS", without any express or implied warranties. The software is in the development stage. It is intended exclusively for experts who have experience with such software and solely for the purpose of inspection. All implied warranties of non-infringement, merchantability and fitness for a particular purpose are hereby disclaimed and excluded. Any dispute, controversy or claim arising under or in relation to providing this software shall be submitted to and settled by the final, binding jurisdiction of the courts of Munich, Germany in accordance with the laws of the Federal Republic of Germany excluding its conflict of law rules and the United Nations Convention on Contracts on the International Sales of Goods. """ import pytest from .utils import * """ Ambisonics """ @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_AMBI) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_ambisonics_binaural_static_with_binary_hrir(test_info, in_fmt, out_fmt, framing_5ms): compare_renderer_vs_renderer_with_binary_hrir( test_info, in_fmt, out_fmt, framing_5ms=(framing_5ms == "5ms"), is_comparetest=True, ) @pytest.mark.parametrize("trj_file", HR_TRAJECTORIES_TO_TEST) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_AMBI) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_ambisonics_binaural_headrotation_with_binary_hrir(test_info, in_fmt, out_fmt, trj_file, framing_5ms): compare_renderer_vs_renderer_with_binary_hrir( test_info, in_fmt, out_fmt, trj_file=HR_TRAJECTORY_DIR.joinpath(f"{trj_file}.csv"), framing_5ms=(framing_5ms == "5ms"), is_comparetest=True, ) """ Multichannel """ @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_MC) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_multichannel_binaural_static_with_binary_hrir(test_info, in_fmt, out_fmt, framing_5ms): if in_fmt in ["MONO", "STEREO"]: pytest.skip("MONO or STEREO to Binaural rendering unsupported") compare_renderer_vs_renderer_with_binary_hrir( test_info, in_fmt, out_fmt, framing_5ms=(framing_5ms == "5ms"), is_comparetest=True, ) @pytest.mark.parametrize("trj_file", HR_TRAJECTORIES_TO_TEST) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_MC) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_multichannel_binaural_headrotation_with_binary_hrir( test_info, in_fmt, out_fmt, trj_file, framing_5ms ): if in_fmt in ["MONO", "STEREO"]: pytest.skip("MONO or STEREO to Binaural rendering unsupported") compare_renderer_vs_renderer_with_binary_hrir( test_info, in_fmt, out_fmt, trj_file=HR_TRAJECTORY_DIR.joinpath(f"{trj_file}.csv"), framing_5ms=(framing_5ms == "5ms"), is_comparetest=True, ) """ ISM """ @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_ISM) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_ism_binaural_static_with_binary_hrir(test_info, in_fmt, out_fmt, framing_5ms): try: in_meta_files = FORMAT_TO_METADATA_FILES[in_fmt] except: in_meta_files = None compare_renderer_vs_renderer_with_binary_hrir( test_info, in_fmt, out_fmt, in_meta_files=in_meta_files, framing_5ms=(framing_5ms == "5ms"), is_comparetest=True, ) @pytest.mark.parametrize("trj_file", HR_TRAJECTORIES_TO_TEST) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_ISM) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_ism_binaural_headrotation_with_binary_hrir(test_info, in_fmt, out_fmt, trj_file, framing_5ms): try: in_meta_files = FORMAT_TO_METADATA_FILES[in_fmt] except: in_meta_files = None compare_renderer_vs_renderer_with_binary_hrir( test_info, in_fmt, out_fmt, trj_file=HR_TRAJECTORY_DIR.joinpath(f"{trj_file}.csv"), in_meta_files=in_meta_files, framing_5ms=(framing_5ms == "5ms"), is_comparetest=True, ) """ MASA """ @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_MASA) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_masa_binaural_static_with_binary_hrir(test_info, in_fmt, out_fmt, framing_5ms): if out_fmt in ["BINAURAL_ROOM_IR", "BINAURAL_ROOM_REVERB"]: pytest.skip("Skipping binaural room outputs for MASA as unimplemented.") compare_renderer_vs_renderer_with_binary_hrir( test_info, in_fmt, out_fmt, in_meta_files=FORMAT_TO_METADATA_FILES[in_fmt], framing_5ms=(framing_5ms == "5ms"), ) @pytest.mark.parametrize("trj_file", HR_TRAJECTORIES_TO_TEST) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_MASA) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_masa_binaural_headrotation_with_binary_hrir(test_info, in_fmt, out_fmt, trj_file, framing_5ms): if out_fmt in ["BINAURAL_ROOM_IR", "BINAURAL_ROOM_REVERB"]: pytest.skip("Skipping binaural room outputs for MASA as unimplemented.") compare_renderer_vs_renderer_with_binary_hrir( test_info, in_fmt, out_fmt, trj_file=HR_TRAJECTORY_DIR.joinpath(f"{trj_file}.csv"), in_meta_files=FORMAT_TO_METADATA_FILES[in_fmt], framing_5ms=(framing_5ms == "5ms"), ) """ Custom loudspeaker layouts """ @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_layout", CUSTOM_LS_TO_TEST) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_custom_ls_input_binaural_with_binary_hrir(test_info, in_layout, out_fmt, framing_5ms): compare_renderer_vs_renderer_with_binary_hrir( test_info, CUSTOM_LAYOUT_DIR.joinpath(f"{in_layout}.txt"), out_fmt, framing_5ms=(framing_5ms == "5ms"), is_comparetest=True, ) @pytest.mark.parametrize("trj_file", HR_TRAJECTORIES_TO_TEST) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_layout", CUSTOM_LS_TO_TEST) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_custom_ls_input_binaural_headrotation_with_binary_hrir( test_info, in_layout, out_fmt, trj_file, framing_5ms ): compare_renderer_vs_renderer_with_binary_hrir( test_info, CUSTOM_LAYOUT_DIR.joinpath(f"{in_layout}.txt"), out_fmt, trj_file=HR_TRAJECTORY_DIR.joinpath(f"{trj_file}.csv"), framing_5ms=(framing_5ms == "5ms"), is_comparetest=True, ) No newline at end of file Loading
tests/renderer/test_renderer_be_comparison.py +0 −170 Original line number Diff line number Diff line Loading @@ -56,18 +56,6 @@ def test_ambisonics_binaural_static(test_info, in_fmt, out_fmt, framing_5ms): ) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_AMBI) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_ambisonics_binaural_static_with_binary_hrir(test_info, in_fmt, out_fmt, framing_5ms): compare_renderer_vs_renderer_with_binary_hrir( test_info, in_fmt, out_fmt, framing_5ms=(framing_5ms == "5ms"), is_comparetest=True, ) @pytest.mark.parametrize("trj_file", HR_TRAJECTORIES_TO_TEST) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_AMBI) Loading @@ -83,21 +71,6 @@ def test_ambisonics_binaural_headrotation( test_info, in_fmt, out_fmt, trj_file, ) @pytest.mark.parametrize("trj_file", HR_TRAJECTORIES_TO_TEST) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_AMBI) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_ambisonics_binaural_headrotation_with_binary_hrir(test_info, in_fmt, out_fmt, trj_file, framing_5ms): compare_renderer_vs_renderer_with_binary_hrir( test_info, in_fmt, out_fmt, trj_file=HR_TRAJECTORY_DIR.joinpath(f"{trj_file}.csv"), framing_5ms=(framing_5ms == "5ms"), is_comparetest=True, ) """ Multichannel """ Loading @@ -123,22 +96,6 @@ def test_multichannel_binaural_static(test_info, in_fmt, out_fmt, framing_5ms): ) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_MC) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_multichannel_binaural_static_with_binary_hrir(test_info, in_fmt, out_fmt, framing_5ms): if in_fmt in ["MONO", "STEREO"]: pytest.skip("MONO or STEREO to Binaural rendering unsupported") compare_renderer_vs_renderer_with_binary_hrir( test_info, in_fmt, out_fmt, framing_5ms=(framing_5ms == "5ms"), is_comparetest=True, ) @pytest.mark.parametrize("trj_file", HR_TRAJECTORIES_TO_TEST) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_MC) Loading @@ -159,26 +116,6 @@ def test_multichannel_binaural_headrotation( ) @pytest.mark.parametrize("trj_file", HR_TRAJECTORIES_TO_TEST) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_MC) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_multichannel_binaural_headrotation_with_binary_hrir( test_info, in_fmt, out_fmt, trj_file, framing_5ms ): if in_fmt in ["MONO", "STEREO"]: pytest.skip("MONO or STEREO to Binaural rendering unsupported") compare_renderer_vs_renderer_with_binary_hrir( test_info, in_fmt, out_fmt, trj_file=HR_TRAJECTORY_DIR.joinpath(f"{trj_file}.csv"), framing_5ms=(framing_5ms == "5ms"), is_comparetest=True, ) """ ISM """ Loading Loading @@ -210,26 +147,6 @@ def test_ism_binaural_static(test_info, in_fmt, out_fmt, framing_5ms): ) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_ISM) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_ism_binaural_static_with_binary_hrir(test_info, in_fmt, out_fmt, framing_5ms): try: in_meta_files = FORMAT_TO_METADATA_FILES[in_fmt] except: in_meta_files = None compare_renderer_vs_renderer_with_binary_hrir( test_info, in_fmt, out_fmt, in_meta_files=in_meta_files, framing_5ms=(framing_5ms == "5ms"), is_comparetest=True, ) @pytest.mark.parametrize("trj_file", HR_TRAJECTORIES_TO_TEST) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_ISM) Loading @@ -252,28 +169,6 @@ def test_ism_binaural_headrotation(test_info, in_fmt, out_fmt, trj_file, framing ) @pytest.mark.parametrize("trj_file", HR_TRAJECTORIES_TO_TEST) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_ISM) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_ism_binaural_headrotation_with_binary_hrir(test_info, in_fmt, out_fmt, trj_file, framing_5ms): try: in_meta_files = FORMAT_TO_METADATA_FILES[in_fmt] except: in_meta_files = None compare_renderer_vs_renderer_with_binary_hrir( test_info, in_fmt, out_fmt, trj_file=HR_TRAJECTORY_DIR.joinpath(f"{trj_file}.csv"), in_meta_files=in_meta_files, framing_5ms=(framing_5ms == "5ms"), is_comparetest=True, ) """ MASA """ Loading Loading @@ -301,22 +196,6 @@ def test_masa_binaural_static(test_info, in_fmt, out_fmt, framing_5ms): ) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_MASA) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_masa_binaural_static_with_binary_hrir(test_info, in_fmt, out_fmt, framing_5ms): if out_fmt in ["BINAURAL_ROOM_IR", "BINAURAL_ROOM_REVERB"]: pytest.skip("Skipping binaural room outputs for MASA as unimplemented.") compare_renderer_vs_renderer_with_binary_hrir( test_info, in_fmt, out_fmt, in_meta_files=FORMAT_TO_METADATA_FILES[in_fmt], framing_5ms=(framing_5ms == "5ms"), ) @pytest.mark.parametrize("trj_file", HR_TRAJECTORIES_TO_TEST) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_MASA) Loading @@ -335,24 +214,6 @@ def test_masa_binaural_headrotation(test_info, in_fmt, out_fmt, trj_file, framin ) @pytest.mark.parametrize("trj_file", HR_TRAJECTORIES_TO_TEST) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_MASA) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_masa_binaural_headrotation_with_binary_hrir(test_info, in_fmt, out_fmt, trj_file, framing_5ms): if out_fmt in ["BINAURAL_ROOM_IR", "BINAURAL_ROOM_REVERB"]: pytest.skip("Skipping binaural room outputs for MASA as unimplemented.") compare_renderer_vs_renderer_with_binary_hrir( test_info, in_fmt, out_fmt, trj_file=HR_TRAJECTORY_DIR.joinpath(f"{trj_file}.csv"), in_meta_files=FORMAT_TO_METADATA_FILES[in_fmt], framing_5ms=(framing_5ms == "5ms"), ) """ Custom loudspeaker layouts """ Loading Loading @@ -402,19 +263,6 @@ def test_custom_ls_input_binaural(test_info, in_layout, out_fmt, framing_5ms): ) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_layout", CUSTOM_LS_TO_TEST) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_custom_ls_input_binaural_with_binary_hrir(test_info, in_layout, out_fmt, framing_5ms): compare_renderer_vs_renderer_with_binary_hrir( test_info, CUSTOM_LAYOUT_DIR.joinpath(f"{in_layout}.txt"), out_fmt, framing_5ms=(framing_5ms == "5ms"), is_comparetest=True, ) @pytest.mark.parametrize("trj_file", HR_TRAJECTORIES_TO_TEST) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_layout", CUSTOM_LS_TO_TEST) Loading @@ -432,24 +280,6 @@ def test_custom_ls_input_binaural_headrotation( ) @pytest.mark.parametrize("trj_file", HR_TRAJECTORIES_TO_TEST) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_layout", CUSTOM_LS_TO_TEST) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_custom_ls_input_binaural_headrotation_with_binary_hrir( test_info, in_layout, out_fmt, trj_file, framing_5ms ): compare_renderer_vs_renderer_with_binary_hrir( test_info, CUSTOM_LAYOUT_DIR.joinpath(f"{in_layout}.txt"), out_fmt, trj_file=HR_TRAJECTORY_DIR.joinpath(f"{trj_file}.csv"), framing_5ms=(framing_5ms == "5ms"), is_comparetest=True, ) """ Metadata / scene description input """ Loading
tests/renderer/test_renderer_with_or_without_binary_hrir_BE_comparison.py 0 → 100644 +220 −0 Original line number Diff line number Diff line #!/usr/bin/env python3 """ (C) 2022-2023 IVAS codec Public Collaboration with portions copyright Dolby International AB, Ericsson AB, Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other contributors to this repository. All Rights Reserved. This software is protected by copyright law and by international treaties. The IVAS codec Public Collaboration consisting of Dolby International AB, Ericsson AB, Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other contributors to this repository retain full ownership rights in their respective contributions in the software. This notice grants no license of any kind, including but not limited to patent license, nor is any license granted by implication, estoppel or otherwise. Contributors are required to enter into the IVAS codec Public Collaboration agreement before making contributions. This software is provided "AS IS", without any express or implied warranties. The software is in the development stage. It is intended exclusively for experts who have experience with such software and solely for the purpose of inspection. All implied warranties of non-infringement, merchantability and fitness for a particular purpose are hereby disclaimed and excluded. Any dispute, controversy or claim arising under or in relation to providing this software shall be submitted to and settled by the final, binding jurisdiction of the courts of Munich, Germany in accordance with the laws of the Federal Republic of Germany excluding its conflict of law rules and the United Nations Convention on Contracts on the International Sales of Goods. """ import pytest from .utils import * """ Ambisonics """ @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_AMBI) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_ambisonics_binaural_static_with_binary_hrir(test_info, in_fmt, out_fmt, framing_5ms): compare_renderer_vs_renderer_with_binary_hrir( test_info, in_fmt, out_fmt, framing_5ms=(framing_5ms == "5ms"), is_comparetest=True, ) @pytest.mark.parametrize("trj_file", HR_TRAJECTORIES_TO_TEST) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_AMBI) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_ambisonics_binaural_headrotation_with_binary_hrir(test_info, in_fmt, out_fmt, trj_file, framing_5ms): compare_renderer_vs_renderer_with_binary_hrir( test_info, in_fmt, out_fmt, trj_file=HR_TRAJECTORY_DIR.joinpath(f"{trj_file}.csv"), framing_5ms=(framing_5ms == "5ms"), is_comparetest=True, ) """ Multichannel """ @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_MC) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_multichannel_binaural_static_with_binary_hrir(test_info, in_fmt, out_fmt, framing_5ms): if in_fmt in ["MONO", "STEREO"]: pytest.skip("MONO or STEREO to Binaural rendering unsupported") compare_renderer_vs_renderer_with_binary_hrir( test_info, in_fmt, out_fmt, framing_5ms=(framing_5ms == "5ms"), is_comparetest=True, ) @pytest.mark.parametrize("trj_file", HR_TRAJECTORIES_TO_TEST) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_MC) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_multichannel_binaural_headrotation_with_binary_hrir( test_info, in_fmt, out_fmt, trj_file, framing_5ms ): if in_fmt in ["MONO", "STEREO"]: pytest.skip("MONO or STEREO to Binaural rendering unsupported") compare_renderer_vs_renderer_with_binary_hrir( test_info, in_fmt, out_fmt, trj_file=HR_TRAJECTORY_DIR.joinpath(f"{trj_file}.csv"), framing_5ms=(framing_5ms == "5ms"), is_comparetest=True, ) """ ISM """ @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_ISM) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_ism_binaural_static_with_binary_hrir(test_info, in_fmt, out_fmt, framing_5ms): try: in_meta_files = FORMAT_TO_METADATA_FILES[in_fmt] except: in_meta_files = None compare_renderer_vs_renderer_with_binary_hrir( test_info, in_fmt, out_fmt, in_meta_files=in_meta_files, framing_5ms=(framing_5ms == "5ms"), is_comparetest=True, ) @pytest.mark.parametrize("trj_file", HR_TRAJECTORIES_TO_TEST) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_ISM) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_ism_binaural_headrotation_with_binary_hrir(test_info, in_fmt, out_fmt, trj_file, framing_5ms): try: in_meta_files = FORMAT_TO_METADATA_FILES[in_fmt] except: in_meta_files = None compare_renderer_vs_renderer_with_binary_hrir( test_info, in_fmt, out_fmt, trj_file=HR_TRAJECTORY_DIR.joinpath(f"{trj_file}.csv"), in_meta_files=in_meta_files, framing_5ms=(framing_5ms == "5ms"), is_comparetest=True, ) """ MASA """ @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_MASA) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_masa_binaural_static_with_binary_hrir(test_info, in_fmt, out_fmt, framing_5ms): if out_fmt in ["BINAURAL_ROOM_IR", "BINAURAL_ROOM_REVERB"]: pytest.skip("Skipping binaural room outputs for MASA as unimplemented.") compare_renderer_vs_renderer_with_binary_hrir( test_info, in_fmt, out_fmt, in_meta_files=FORMAT_TO_METADATA_FILES[in_fmt], framing_5ms=(framing_5ms == "5ms"), ) @pytest.mark.parametrize("trj_file", HR_TRAJECTORIES_TO_TEST) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_fmt", INPUT_FORMATS_MASA) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_masa_binaural_headrotation_with_binary_hrir(test_info, in_fmt, out_fmt, trj_file, framing_5ms): if out_fmt in ["BINAURAL_ROOM_IR", "BINAURAL_ROOM_REVERB"]: pytest.skip("Skipping binaural room outputs for MASA as unimplemented.") compare_renderer_vs_renderer_with_binary_hrir( test_info, in_fmt, out_fmt, trj_file=HR_TRAJECTORY_DIR.joinpath(f"{trj_file}.csv"), in_meta_files=FORMAT_TO_METADATA_FILES[in_fmt], framing_5ms=(framing_5ms == "5ms"), ) """ Custom loudspeaker layouts """ @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_layout", CUSTOM_LS_TO_TEST) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_custom_ls_input_binaural_with_binary_hrir(test_info, in_layout, out_fmt, framing_5ms): compare_renderer_vs_renderer_with_binary_hrir( test_info, CUSTOM_LAYOUT_DIR.joinpath(f"{in_layout}.txt"), out_fmt, framing_5ms=(framing_5ms == "5ms"), is_comparetest=True, ) @pytest.mark.parametrize("trj_file", HR_TRAJECTORIES_TO_TEST) @pytest.mark.parametrize("out_fmt", OUTPUT_FORMATS_BINAURAL) @pytest.mark.parametrize("in_layout", CUSTOM_LS_TO_TEST) @pytest.mark.parametrize("framing_5ms", FRAMING_5MS_TO_TEST) def test_custom_ls_input_binaural_headrotation_with_binary_hrir( test_info, in_layout, out_fmt, trj_file, framing_5ms ): compare_renderer_vs_renderer_with_binary_hrir( test_info, CUSTOM_LAYOUT_DIR.joinpath(f"{in_layout}.txt"), out_fmt, trj_file=HR_TRAJECTORY_DIR.joinpath(f"{trj_file}.csv"), framing_5ms=(framing_5ms == "5ms"), is_comparetest=True, ) No newline at end of file