Re: [rtcweb] FEC for audio?

Justin Uberti <juberti@google.com> Tue, 20 May 2014 13:26 UTC

Return-Path: <juberti@google.com>
X-Original-To: rtcweb@ietfa.amsl.com
Delivered-To: rtcweb@ietfa.amsl.com
Received: from localhost (ietfa.amsl.com [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 49E801A0705 for <rtcweb@ietfa.amsl.com>; Tue, 20 May 2014 06:26:00 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.029
X-Spam-Level:
X-Spam-Status: No, score=-2.029 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FM_FORGED_GMAIL=0.622, HTML_MESSAGE=0.001, RP_MATCHES_RCVD=-0.651, SPF_PASS=-0.001] autolearn=ham
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id fgtooKtYUAtM for <rtcweb@ietfa.amsl.com>; Tue, 20 May 2014 06:25:57 -0700 (PDT)
Received: from mail-ve0-x235.google.com (mail-ve0-x235.google.com [IPv6:2607:f8b0:400c:c01::235]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id A374E1A0704 for <rtcweb@ietf.org>; Tue, 20 May 2014 06:25:57 -0700 (PDT)
Received: by mail-ve0-f181.google.com with SMTP id pa12so578888veb.12 for <rtcweb@ietf.org>; Tue, 20 May 2014 06:25:56 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type; bh=lT+nbEVIBHhTZyaEoPELxVMgiIZf+DJ+jeSn6Ykn3U4=; b=YBejvxmTnjWGr/3LbaMdA88Joi/bAW77N8Di/TLWsp/O0JkFpV683UUc/4jafEYHAp AZxfaf1QPcb1tA1mIMbHLDc//G7ZaxZOAdUw1X3Dfr/g0VzkfyoXCwc2oe7NMjumCNqV q/ew+dgI6tONbawYwnfDjpyqftzWmKGIuKE+Wrc7E3eiZlYAZaEiigUYMI5toek+l5Lm zV2kfL/JulY5/6NJIgVshMW6MByZK7W0D6Vs4rdG2KOJipnWCU9V/UY5xqmGf5ZDmvjK MbKy9w0+/hlIGGgYt5EJZ3jAn9Eq4+pVzjvkwmBjmi+3mbWd0B2uluDKO+PIl51t3mcW Mz/Q==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc:content-type; bh=lT+nbEVIBHhTZyaEoPELxVMgiIZf+DJ+jeSn6Ykn3U4=; b=T/LfZo0CCqPnJyyJ06bYYiK+To/BgSj1W+8OZm7prv0WPwfaCU3k4Dc6tkqG/QwOMN GwnunkI5yQpg5MaZvFPZlLriS4/h6cqZF6BTx26zUdj2Jbcgm2i1V5owMjRIXAjgXhCz k2/xkRLX/gpwY+rZog04LXWH5oUmK0QDsQd0rbjZPs0KUShwqMhXaUw/jf8Gv60nKEVp 6tjmJ3pVa6CQH9JfN9T4O9RtC4rCVQMQQ72ok82osBsQP6F3l6OPgjhz0XQvQ/mBLX0b JWyEhMx/JsSHhMlPMHZ/vi6JwWQ8zFNKaj6c3zySO5/raQAW+JubiFZwxmFE2hP0ktr1 8bYw==
X-Gm-Message-State: ALoCoQlvfoo6L7X2485EaGaH8gQmaYS3mp0POTSD6rSvHV6n0VeaouojwYe5z7r3cgHMUYZA/lfC
X-Received: by 10.58.228.163 with SMTP id sj3mr24210971vec.28.1400592356576; Tue, 20 May 2014 06:25:56 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.52.145.105 with HTTP; Tue, 20 May 2014 06:25:33 -0700 (PDT)
In-Reply-To: <537AACDA.20603@mozilla.com>
References: <CAOJ7v-1qEpkWShmw1SQKh4_BLKycF=egu42TS9o9+Smtof36pg@mail.gmail.com> <CAJrXDUESUa-xm9y22OAVKAw5z=WnkY4-X6XFZOoXwvkMoDnaoQ@mail.gmail.com> <537A6190.4060709@mozilla.com> <CAOJ7v-2mb6DkakaEWMxJwqqLSePb7NrOcF-DSycW-CftBGdmcA@mail.gmail.com> <CAOJ7v-1YxHhVm8NE4H3ZkCuOtN4CsUgQoiV1GN3w3NKRWhqWMw@mail.gmail.com> <537AACDA.20603@mozilla.com>
From: Justin Uberti <juberti@google.com>
Date: Tue, 20 May 2014 06:25:33 -0700
Message-ID: <CAOJ7v-3Qi7=jt__BKUfzaBZTfTZ=bdHuzskeRpnbDRbOUYxpGA@mail.gmail.com>
To: "Timothy B. Terriberry" <tterriberry@mozilla.com>
Content-Type: multipart/alternative; boundary="047d7bd6b332e3f23404f9d4d1bd"
Archived-At: http://mailarchive.ietf.org/arch/msg/rtcweb/dKjgsVci7PVeHy5V5cp6-pyfb9g
Cc: "rtcweb@ietf.org" <rtcweb@ietf.org>
Subject: Re: [rtcweb] FEC for audio?
X-BeenThere: rtcweb@ietf.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: Real-Time Communication in WEB-browsers working group list <rtcweb.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/rtcweb>, <mailto:rtcweb-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/rtcweb/>
List-Post: <mailto:rtcweb@ietf.org>
List-Help: <mailto:rtcweb-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/rtcweb>, <mailto:rtcweb-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 20 May 2014 13:26:00 -0000

I don't think we would send a standalone FEC packet, given the overheads -
I would expect we would use RFC 2198 encoding and send 5109 FEC as
piggyback on the 'next' audio packet, similar to how I understand the
internal FEC works. This would have (5 + 10 + 4) * 8 = 152 bits of overhead
per packet, or ~8 Kbps when using 20 ms frames.







On Mon, May 19, 2014 at 6:16 PM, Timothy B. Terriberry <
tterriberry@mozilla.com> wrote:

> Justin Uberti wrote:
>
>> Advice on the exact value of XX welcomed.
>>
>
> That is complicated, of course. I think if you're using SILK, you should
> probably always prefer the in-band FEC (if nothing else, it saves you a
> minimum of 54 bytes of header overhead over RFC5109), but that's a decision
> we make on a packet-by-packet basis.
>
> However, libopus will use CELT at rates as low as 12 kbps (and always uses
> CELT for CBR rates below 8 kbps), and will use SILK/Hybrid at rates as high
> as 76 kbps, depending on the application libopus was configured with, our
> estimate of whether or not the content contains voice or music, the stereo
> width (if the signal is stereo), and hysteresis from previous mode
> decisions.
>
> For a simple application, I'd probably enable 5109 for a mono voice stream
> encoded in VOIP mode at around 48-56 kbps (but I have not done any testing
> around these numbers). A more complex application could negotiate 5109
> always, and then only transmit FEC for the packets that do not contain a
> SILK layer.
>
> If you are using 5109, be careful to pass in the post-FEC recovery packet
> loss percentage to libopus when encoding, instead of the raw packet loss
> percentage. Above a certain loss rate (8% if I'm reading the current code
> correctly), libopus will force SILK usage in order to be able to use the
> built-in FEC.
>
> When protecting CELT, you may also want to experiment with using ULP to
> protect only the beginning of the CELT payloads. We intentionally organized
> the packet so the most important information was at the front. The first
> 64-bits or so are enough to get the pitch filter and basic energy levels
> correct (though you'll probably want to send a little more to justify all
> the bitrate you spent on IP+UDP+RTP+FEC headers). As long as you get the
> energy levels correct, you cannot mess things up _too_ badly, even if the
> rest of the packet is random garbage. Make sure you pass the decoder a
> packet with the same size as the original, even if you only recover some of
> the data, as otherwise even the recovered data will not decode correctly.
>
>
> _______________________________________________
> rtcweb mailing list
> rtcweb@ietf.org
> https://www.ietf.org/mailman/listinfo/rtcweb
>