Skip to main content
Topic: xHE-AAC. Is it ready yet? Any encoders out there? (Read 20020 times) previous topic - next topic
0 Members and 2 Guests are viewing this topic.

Re: xHE-AAC. Is it ready yet? Any encoders out there?

Reply #25
From the same paper https://dl.dropboxusercontent.com/u/61700377/misc/20130920_Streaming_Codec_Study_Report.pdf

Quote
Interestingly, results were quite flat starting at 32 kbps, suggesting that listeners did not hear marked
improvements at higher bit rates
:o
This is so wrong I don't even know which argument to start with.
Let's just put it in a technical terms.

If your codec and /or test present the same not so good quality (MUSHRA 60 = MOS 3) both at 24-32 kbps and higher bitrate 64 kbps then there is something really wrong with your codec and/or test. 

Also according to their test  their xHE-AAC 64 kbps = MP3 96 kbps. Even MP3pro (MP3+SBR) 64 kbps is on par with legacy MP3 96 kbps. So  this particular tested implementation of xHE-AAC doesn't bring nothing new to 14 years old SBR (?). 




Another interesting statement about bitrates and 4G.
Quote
Based on our research, we recommend keeping the bit rate of streams
as low as possible, consistent with high audio quality.  For the HE‐AAC codec, we believe this balance is achieved
at a constant stream rate of 48 kbps

Something obvious but still.  Audio quality isn't  high  at 48 kbps with any codec. OK quality, maybe.

 I don't beleive that such low bitrate 48 kbps can prevent dropout.
1. It's impossible to "pre-buffer" a real-time radio.
2. The rate of 4G is far superior than any logical audio bitrates. I have an unlimited 4G 30 Mbits connection on my phone. A speed  can drop down to ~300-700 kbps in worst congestion case (and I still get Spotify working at 96/160/320 kbps)
Still far superior to 48-100 kbps.  But if there is some area with no 4G You lose a connection per completely then  even xHE-AAC 16 kbps won't help here.

So all this point of very low bitrate on 4G is very moot.

P.S. They push low bitrates and xHE-AAC for an obvious reason.
Why would someone pay more if LC-AAC (which is almost 20 years old) is doing already great at  80-96 kbps without all that extra pay for a newer low-bitrate codec with a load of patents for semi-parametric or parametric coding tools like SBR, PS, SBS, MPS, advanced LPC, IGF, ELT etc.

Re: xHE-AAC. Is it ready yet? Any encoders out there?

Reply #26
IgorC: A result like that is a little shaky, and I think their graphs are a little weird, too.

I think as for low bitrates in the mobile market it doesn't make much sense these days, as providers are pushing for higher bandwidths constantly.
A point where it makes sense to me though, is when it comes to streaming costs. Most providers (mine included) charge for traffic volume. So, when you have less traffic you pay less, so that makes sense. Especially, when you're using that streaming service in your car, etc. where sound quality isn't perfect anyway.

But I'm only really interested in how it performs against Opus. What they claim is one thing, as long as I can't test it myself, it's not really that interesting to me. I don't see myself using DRM over AM, as I don't really have a need for that. But I guess it'd make sense if you're in a remote area, or on a boat or something, and all you can get is AM radio.

I'm a big fan of Codec2, which to me covers the "lower end" of the bandwidth spectrum. I'm a little surprised by the fact the radio operators don't settle on Opus, as it is free, it is a low-latency codec, and provides adequate quality on low bandwidths. I'm not a marketing person, so I guess there's something I simply don't see.

Re: xHE-AAC. Is it ready yet? Any encoders out there?

Reply #27
polemon,
Quote
Most providers (mine included) charge for traffic volume. So, when you have less traffic you pay less, so that makes sense.
That's true.

Quote
But I'm only really interested in how it performs against Opus.
That depends on particular implmentation(encoder) of xHE-AAC.
While there is only one Opus reference implementation there can be multiple xHE-AAC encoders with different audio quality.

You can find some samples of USAC (xHE-AAC) here https://hydrogenaud.io/index.php/topic,106938.msg875351.html#msg875351
That is a reference high quality USAC encoder which isn't available.

I have compared it with Opus some years ago and here are my conslusions:
32 kbps, stereo. USAC is better than Opus.  It's not a surprise as Opus is a low-delay codec and frequency leakeage is big at very low bitrate. While USAC benefits from 100+ ms delay.

48 kbps, stereo. That's where it starts changing. Opus 1.1 was somwehat inferior to HE-AAC and USAC. But the latest alpha 1.2 should be already on par with USAC and somewhat better than HE-AAC.

64 kbps and higher bitrates, stereo. That's where both Opus and USAC already push the limits what can be done with lossy audio compression. Both are good and better than HE-AAC and LC-AAC. It will take at least 5 years or so to make something better than that.

But that's with USAC reference highest quality encoder which isn't available publicly.
That particular xHE-AAC encoder from paper isn't very high qualtiy implementation of standard.
If You want to know an average MUSHRA scores for Opus  the I can provide them knowing the previous results of Hydrogenaudio tests and from my personal experience with it.
MUSHRA:
Opus 48 kbps ~65-70.
Opus 64 kbps ~80-85
Opus 96 kbps ~90-95

The main rule is MOS (hydrogenaudio tests) = MUSHRA/20

Also there is some information about Opus vs EVS (enhanced for low delay xHE-AAC) at 48 kbps, mono
https://hydrogenaud.io/index.php/topic,106938.msg875399.html#msg875399
But Opus 1.2 (which is in development now) shoud do better

Re: xHE-AAC. Is it ready yet? Any encoders out there?

Reply #28
it's a shame that no encoders are available for general use. it seems this codec is very restricted, only in dedicated hw for now.

Re: xHE-AAC. Is it ready yet? Any encoders out there?

Reply #29
As I was looking into AMR codecs, I've stumbled over this page: http://www.voiceage.com/Patent-Portfolio.html
I don't know how authoritative it is, but I was told, that U-Boat patents are mostly a thing of the past. Given what is described there, patents for xHE-AAC will expire in 2031 - or to be more precise: the last one of those will expire in 2031.

According to this: https://www.iis.fraunhofer.de/en/ff/amm/impl.html there are SDKs available, that run on a plethora of systems, including PC (including Linux). How to get those SDKs, I have no idea.

VoiceAge "sells" xHE-AAC: http://www.voiceage.com/xHE-AAC.html however I'm not sure how they sell it. They claim to be a "codec provider", I wonder if that means, they do anything beyond licensing, really. As far as I understand it, the SDK or whatever software has to come from FhG IIS anyway.

I occasionally check out the usual places on the internet for a pirated copy of the SDK, but so far I couldn't find any. I guess since there aren't that many users, the probability of the SDK leaking outside of its designed realm is rather minimal. And tbh, I think this is the only way we'd get a chance at having a go at xHE-AAC for anytime soon.

Re: xHE-AAC. Is it ready yet? Any encoders out there?

Reply #30
Internet isn't a viable option for patented formats anymore.
Google tries to get rid of AAC in Youtube (still supported in MS and Apple browsers )and pushes Opus. Spotify uses Vorbis and they can't afford a patented format. WhatsApp uses Opus. Netflix uses patent free formats for mobile clients as well. 

MPEG Surround is a standard since 2007 (10 years ago! ) and its presence is null in internet community.
The same goes for xHE-AAC. Something is telling me (and I don't know what is it  O:) ) the same will go for a latest standard 3DA which improves xHE-AAC quality furthermore.

If there is possibility for a new codec in future that will be available for internet community that will be Ghost (or whatever it will be called).  https://people.xiph.org/~xiphmont/demo/ghost/demo.html

Ghost can improve quality  comparing to Opus more than considerably as it can use higher latencies (100-200ms) and some additional complexity. Today ARM chips  can decode at least 2x-4x complexity of Opus without dropping smartphone's battery life.

PS. BTW  xHE-AAC's sweet spot is 24-32 kbps stereo. It's slightly better than HE-AAC at  >=48kbp bitrates. 
Chances that xHE-AAC will be any better than Opus at >=48 kbps are zero.

PS2. There is also a new format AC4 from Dolby. Dolby has acquired Coding Technologies (creators of SBR and Parametric Stereo). AC4 is similar to xHE-AAC (if not better)

Re: xHE-AAC. Is it ready yet? Any encoders out there?

Reply #31
If there is possibility for a new codec in future that will be available for internet community that will be Ghost (or whatever it will be called). https://people.xiph.org/~xiphmont/demo/ghost/demo.html

Ghost can improve quality comparing to Opus more than considerably as it can use higher latencies (100-200ms) and some additional complexity. Today ARM chips  can decode at least 2x-4x complexity of Opus without dropping smartphone's battery life.
OK, so when it uses higher latencies, it's meant just for unicast streaming, etc.? Opus was designed to be a low-latency codec for VoIP, etc. that just happened to be good all round.

So Ghost will not replace Opus, merely it will be the "true" replacement for Vorbis, I take it?

Re: xHE-AAC. Is it ready yet? Any encoders out there?

Reply #32
You're right.

Re: xHE-AAC. Is it ready yet? Any encoders out there?

Reply #33
Amazing stuff and ideas but... Ghost really? Should we create an association to pick names for open source projects? :)

Re: xHE-AAC. Is it ready yet? Any encoders out there?

Reply #34
 Vorbis, Opus and Ghost aren't names that I would prefer either.   :)

In my opinion some generic naming like Open Audio Codec 1 (OAC1) as for Vorbis , low delay OAC2 (LD-OAC2) as for Opus are easy to understand.
Even better,  Xiph Audio I (XA1, XA2...).

The future royalty-free video codec is "AV1" (AOMedia Video 1).  More clear impossible.

Re: xHE-AAC. Is it ready yet? Any encoders out there?

Reply #35
Vorbis, Opus and Ghost aren't names that I would prefer either.

Well, the names like that are usually chosen for the same reason Linux distributions have names like "Ubntu" or "Fedora". The idea is to have a nice martketable name, which also speaks to a community, etc.

However this might swing ther other way: the MPEG numbering, layering, parting and whatever becomes a complete mess, with overlapping naming schemes and naming collisions.

the ITU has a numbering scheme which works half-good, I'd say, but it's still somewhat confusing.

The On2 VPn numbering scheme for video codecs was fine, I think, though. Numbering schemes usually tend to overcomplicate things, so I'm kinda not in favor of that. I'd name it after the person or group mainly involved in its invention or development, similar to how naming works with things like RSA, LZW, Keccak, etc.

Re: xHE-AAC. Is it ready yet? Any encoders out there?

Reply #36
If there is possibility for a new codec in future that will be available for internet community that will be Ghost (or whatever it will be called).  https://people.xiph.org/~xiphmont/demo/ghost/demo.html

Ghost can improve quality  comparing to Opus more than considerably as it can use higher latencies (100-200ms) and some additional complexity. Today ARM chips  can decode at least 2x-4x complexity of Opus without dropping smartphone's battery life.
I wait for that day so eagerly. They are dropping some serious promises/targets on the table. This format could be a real game changer if and when it will be a thing. I hope we won't have to wait so long for it.

Re: xHE-AAC. Is it ready yet? Any encoders out there?

Reply #37
It seems Ghost is back at being in limbo: https://wiki.xiph.org/Ghost

IgorC: did you do this on their talk page: https://wiki.xiph.org/Talk:Ghost ¦D

Monty's page says "Copyright 2011" and I doubt there has been any changes to it since.

xiph.org has a thing for silly sounding names, their project name on the forefront of that, etc. But also "Vorbis", "Daala", "Ogg".


Re: xHE-AAC. Is it ready yet? Any encoders out there?

Reply #39
So I gave http://stream.radioh.no:443/ a try.

Listening / Getting the Streamdump
Thanks to mpv, youtube-dl, and ffmpeg, listening to the /rh.x16 stream is actually possible on Linux, and I'm pretty sure on Windows, too. However, it seems the toolchain is kinda struggling as it is.

Simply playing the stream directly with mpv, is quite low on errors:
Code: [Select]
$ mpv http://stream.radioh.no:443/rh.16
yields the following error right at the start:
Code: [Select]
[ffmpeg/audio] aac: channel element 2.15 is not allocated
Error decoding audio.
however right after that, the stream starts playing quite nicely.

Data Specifics
With the help of youtube-dl, I managed to download a sample length of the stream.
Inspecting it with ffmpeg yields this:
Code: [Select]
[aac @ 0x59159c0] Estimating duration from bitrate, this may be inaccurate
Input #0, aac, from 'rh-rh.16.part':
  Duration: 00:09:45.52, bitrate: 16 kb/s
    Stream #0:0: Audio: aac (HE-AACv2), 32000 Hz, stereo, fltp, 16 kb/s
Note the "16 kb/s". The Duration is out by around 20 seconds, in that ~10min sample. The file is 1189420 (1.2M) bytes in length, and is a pure AAC dump.

I can play the file back using mpv, but ffmpeg complains about "Reserved SBR extensions is not implemented", which seems to be kindof a minor thing (?), as the file plays alright.

When playing this file with "--msg-level=all=v", playing the stream directly with the switch using mpv, or inspecting the file with ffmpeg, it never mentions "xHE-AAC". Instead, the AAC stream is identified as HE-AACv2.

Tool Versions
My youtube-dl version is: "2018.01.21" (probably not the latest one).
I tried two versions of ffmpeg, "3.3.7" and "N-45774-g223f3dff8-static https://johnvansickle.com/ffmpeg/" compiled just a couple days ago.
mpv version is: "0.27.2".

I'm using Fedora 27.

Sound Quality
Since no log output of any of the tools I've used reports anything about "xHE-AAC" or "USAC", I'm not sure whether the USAC component is simply ignored. FFmpeg reports "HE-AACv2" with 16 kb/s, and that's pretty much it. Since all tools here use ffmpeg as back-end, I guess this isn't a surprise.

Having said that, the stream sounds "OK", given the low bitrate. However any sounds resembling noise, like someone making an 's', 'f', 'sh', or 'z' sound etc., sound all alike, and incredibly harsh. Similar to a cassette tape recorded with DC bias. Another analogy is perhaps very small speakers, like the ones you'd find on a cheap cellphone or an old 80's pocket radio. I imagine playing that stream through the speakers of a cellphone or cheap bluetooth speakers would be adequate; I wouldn't want to listen to it in my car, though. FM radio sounds much cleaner than this.

If anyone cares, I can upload a sample, together with one or two samples of one of their higher-quality streams for comparison.

Given that I don't know whether my tools are decoding the stream correctly, I'm unsure whether the (subjectively) bad sound quality is down to xHE-AAC simply being used with such a low bitrate, or if it's down to my tools not being able to decode the stream correctly.

Still haven't figured out a way, to create my own sample of xHE-AAC encoded audio. AFAIK, there are no encoders freely available, etc.

There's also a /rh.x16 stream with a content type of "audio/usac". So perhaps that is the /actual/ xHE-AAC stream?
I can't play the stream, with anything that I tried. I get errors like:
Code: [Select]
[aac_latm @ 0x4e82f80] Audio object type 42 is not implemented. Update your FFmpeg version to the newest one from Git. If the problem still occurs, it means that your file has a feature which has not been implemented.
(in case of mpv, I'm getting the exact same message, except with [ffmpeg/audio] in the beginning)

So perhaps 42 is the AOT for xHE-AAC, and it's simply not implemented anywhere (specifically ffmpeg)?

Re: xHE-AAC. Is it ready yet? Any encoders out there?

Reply #40
I don't think ffmpeg can decide xhe-aac.

Re: xHE-AAC. Is it ready yet? Any encoders out there?

Reply #41
Is there any sort of player available, for Windows or Linux, that can play xHE-AAC / USAC streams?

The only thing I can find is this: https://www.indexcom.com/products/hifiradio/
So that's an iOS app, only, it seems.

I'd at least want to have a listen, and see for myself, then.

Re: xHE-AAC. Is it ready yet? Any encoders out there?

Reply #42
For me this format is beyond useless.
Almost nothing supports it, impossible to encode unless you pay big bucks for a hw encoder.
Seems like patent hell caught this one.


Re: xHE-AAC. Is it ready yet? Any encoders out there?

Reply #44
https://trac.ffmpeg.org/wiki/Encode/AAC
ffmpeg supports HE-AAC, not xHE-AAC.

Guys, you're wasting your time on something that will not happen. xHE-AAC won't be publicly available.

And sincerely Opus does everything what xHE-AAC could do. Also new version of  Opus 1.3 will be this year (I guess) which will bring even more of quality improvements.

P.S. Why asking for something expensive while there is a patent-free format freely available which does the same job?
Better quality at extremely low bitrates as 16-32 kbps stereo? Well, that's it, xHE-AAC could shine only there by design. It's very slightly better than [HE]AAC at higher bitrate and no better than Opus. ( I had chance to listen a  reference xHE-AAC at 96 kbps and it was inferior to state of art Apple AAC encoder at 96 kbps . However it was slightly better than HE-AAC at 64 kbps and considerably better than HE-AACv2 at 32 kbps.

xHE-AAC is a sort of HE-AACv3 with a very few real changes at higher bitrate such as slightly  better lossless entropy coder and better stereo coding ( ~+8 kbps of compression gain).
 
P.S2. If they aren't interested in making xHE available as software encoder well, then good for them.  Just show middle finger  and move to something better ... good news we have a good alternatives. :)
 

Re: xHE-AAC. Is it ready yet? Any encoders out there?

Reply #45
Well, I can only go by the examples and sound bites that got released for the press, etc.

It's not that I'm "longing" for this codec to any extent. But to me, it seems xHE-AAC closes a gap - for now, at least.

What is the gap? Well, it's the gap between I'd say ~48kb/s Opus, and <3kb/s speech codecs like Codec2, that has seen some quite remarkable improvements over the last couple months:

http://www.rowetel.com/?p=5966
and: https://storage.googleapis.com/downloads.webmproject.org/icassp2018/index.html

Now you might ask the question of reason behind closing that gap. And yes, you might bring up simply the reason of there not really being any market for it. But from a scientific and engineering standpoint, I don't think this is a fruitless endeavor.

If we can trust the sound bites and samples we get from the marketing division of FhG, xHE-AAC is quite amazing sounding in the 8kb/s-16kb/s range.

Before xHE-AAC gets released, I believe we'll simply see someone pick up a project of making a free codec working in these bitrates, though. I believe that's more likely to happen any time soon.

Marketing wise, there's no reason for FhG to release the codec to anyone but hardware manufacturers. There's no marketable reason to be able to listen to xHE-AAC streams on your cellphone or whatever. It's so niche, almost Codec2 levels of niche. So, I don't think well ever see encoders or decoders plonked down on us for "home use".

Re: xHE-AAC. Is it ready yet? Any encoders out there?

Reply #46
...
Marketing wise, there's no reason for FhG to release the codec to anyone but hardware manufacturers. There's no marketable reason to be able to listen to xHE-AAC streams on your cellphone or whatever. It's so niche, almost Codec2 levels of niche. So, I don't think well ever see encoders or decoders plonked down on us for "home use".

True.
 I'd like to encode some audiobooks in 8kbps to see if it holds. As well as test if 24kbps stereo is any better than he aac v2. Totally non-commercial.


Re: xHE-AAC. Is it ready yet? Any encoders out there?

Reply #48
Phantom_13 thank you for the link.
This is a game changer.  New parametric-WaveNet@2.4 kbps sounds as good as high quality WB speech codec@ 8 kbps (if not even better)
 :o
http://www.rowetel.com/?p=5966

It shouldn't be difficult to scale this codec to fullband and stereo. This way fullband, stereo speech with near transparent quality would be possible at ~ 8 kbps.  Amazing.

Re: xHE-AAC. Is it ready yet? Any encoders out there?

Reply #49
@Phantom_13 Well, yeah, that's what I was linking to. In fact that's how I've kinda stumbled over this.

The highest compression currently usable with Codec2 is 700C. There seems to be some talks of using param WaveNet to decode Codec2 in 700C mode (700b/s).

 
SimplePortal 1.0.0 RC1 © 2008-2018