Commit 6e5dc787 authored by Jan Kiene's avatar Jan Kiene
Browse files

remove sba_fmt from IVAS conditions and use cod:fmt key instead

parent 3d0092a0
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -78,26 +78,26 @@ conditions_to_generate:
    ### IVAS condition ###############################
    c06:
        type: ivas
        sba_fmt: "FOA"
        bitrates:
            - 96000
        cod:
            fmt: "FOA"
        dec:
            fmt: "HOA3"
    c07:
        type: ivas
        sba_fmt: "FOA"
        bitrates:
            - 128000
        cod:
            fmt: "FOA"
        dec:
            fmt: "HOA3"
    c08:
        type: ivas
        sba_fmt: "FOA"
        bitrates:
            - 160000
        cod:
            fmt: "FOA"
        dec:
            fmt: "HOA3"

+2 −2
Original line number Diff line number Diff line
@@ -78,18 +78,18 @@ conditions_to_generate:
    ### IVAS condition ###############################
    c06:
        type: ivas
        sba_fmt: "HOA2"
        bitrates:
            - 160000
        cod:
            fmt: "HOA2"
        dec:
            fmt: "HOA3"
    c07:
        type: ivas
        sba_fmt: "HOA2"
        bitrates:
            - 192000
        cod:
            fmt: "HOA2"
        dec:
            fmt: "HOA3"

+0 −15
Original line number Diff line number Diff line
@@ -347,21 +347,6 @@ def get_processing_chain(
        cod_cfg = cond_cfg["cod"]
        dec_cfg = cond_cfg["dec"]

        if cond_cfg.get("sba_fmt"):
            validate_sba_fmt(tmp_in_fmt, cond_cfg.get("sba_fmt"))
            chain["processes"].append(
                Postprocessing(
                    {
                        "in_fs": tmp_in_fs,
                        "in_fmt": tmp_in_fmt,
                        "out_fs": tmp_in_fs,
                        "out_fmt": cond_cfg.get("sba_fmt"),
                    },
                    name="sba_fmt_rend",
                )
            )
            tmp_in_fmt = cond_cfg.get("sba_fmt")

        # 9.6 kbit/s NB for EVS LFE coding only applies to EVS conditions
        evs_lfe_9k6bps_nb = cond_cfg.get("evs_lfe_9k6bps_nb", None)

+0 −16
Original line number Diff line number Diff line
@@ -350,22 +350,6 @@ class IVAS(Processing):
        raise ValueError(f"IVAS: Invalid input config: {fmt.name}.")


def validate_sba_fmt(in_fmt, sba_fmt):
    in_audio = audio.fromtype(in_fmt)
    sba_audio = audio.fromtype(sba_fmt)
    if isinstance(in_audio, audio.SceneBasedAudio):
        if not isinstance(sba_audio, audio.SceneBasedAudio) or (
            sba_audio.num_channels > in_audio.num_channels
        ):
            raise ValueError(
                "SBA format for IVAS condition has to be SBA with lower or equal order than input signal"
            )
    else:
        if in_audio.name != sba_audio.name:
            raise ValueError("Cannot specify SBA format for non SBA input formats")
    return


class IVAS_rend(Processing):
    def __init__(self, attrs):
        super().__init__(attrs)