Help - Search - Members - Calendar
Full Version: TNS useful to improve sound?
Hydrogenaudio Forums > Lossy Audio Compression > AAC > AAC - General
Tripwire
I was encoding some files using Psytel 2.15 and tried the main profile to make it use TNS. It seems like it creates artifacts on some spots in the files, which dont happen when encoding to LC. Is TNS a tool to optimize low bitrate only?
menno
That's because main prediction doesn't work good, not because of TNS. Use LC.

Menno
Tripwire
Thanks for your reply.

Why does Main profile use a different prediction than LC tho? Just out of interest.
menno
LC doesn't use prediction, to make it less complex.

Menno
hans-jürgen
QUOTE(Tripwire @ Jan 2 2003 - 05:19 PM)
I was encoding some files using Psytel 2.15 and tried the main profile to make it use TNS. It seems like it creates artifacts on some spots in the files, which dont happen when encoding to LC. Is TNS a tool to optimize low bitrate only?

There's a misunderstanding in your posting that TNS would have something to do with the Main profile. These are two different methods or tools already present in MPEG-2 AAC, so they also have nothing to do with MPEG-4 AAC.

For example you can only disable the Temporal Noise Shaping tool in PsyTEL AACEnc with - no_tns, because it's active in all profiles. TNS was meant as a tool to help especially with speech encodings at low bitrates, but it can also improve the quality of music samples if tuned carefully, because it uses the masking effect in the time domain. This means that humans don't hear tiny signals very well that occur only a very short time after a loud signal, preferrable in the same frequency region. So the quantization noise will be spread over a certain time period behind the generating signal. By the way, this is a very well known effect to conductors and professional orchestra musicians, because they use this on purpose sometimes if a tutti crescendo part is difficult to "coordinate". wink.gif

The Main profile uses a backward prediction to further increase the coding efficiency and so is generally more demanding on system ressources of the decoding side. The Low Complexity profile (LC) got its name from its low demand for system ressources and so is the chosen profile for all hardware implementations of the MPEG-2 AAC standard, as far as I know. The Main profile lacks tuning in probably all AAC implemetations, not only in PsyTEL, that's why you heard some strange sounds there.

I doubt that it will ever become the preferred "main" profile in future implementations, because all these different prediction tools (LTP too) will probably become obsolete when SBR is the official method for improving the quality of low bitrate encodings in MPEG-4. This is another tool using both tonal and noise estimation methods, but in the higher frequencies only and so enables the codec to work very efficiently on the lower part of the spectrum while the higher part gets replicated in the decoder according to the informations gathered during the encoding process about the tonal and noise components of these signals.
Tripwire
I'm aware what SBR is, but won't prolly be used here, since I encode my CDs at 192kbit AAC. I just thought since I'm storing them to disk to avoid to juggle with CDs and don't plan to buy a portable, I might use the Main profile to increase quality. But thanks for the info, a luck I've asked or else I'd have encoded a batch of CDs in Main by now.

LTP doesn't seem to be active on high bitrate anyway, the files are always same size and differ only in less than 50 bytes (I guess it has something to do with frameheaders?)
ciber-fred
hum.. just a question as i read this topic...
why use large biterate with AAC.
i personnaly use AAC because it provide a better sound at low biterate -> smaller file size ?
Tripwire
I'm more on the better quality on same bitrate thing. I used to encode MP3s at 192kbit. I'm about to reduce it to 176kbit, as a mean between 160 and 192.
hans-jürgen
QUOTE(Tripwire @ Jan 3 2003 - 01:40 PM)
I'm aware what SBR is, but won't prolly be used here, since I encode my CDs at 192kbit AAC.

So you seem to use a constant bitrate with PsyTEL on purpose? I would think a VBR preset like -normal or -extreme (depending on your favorite music) would be better.

QUOTE
I just thought since I'm storing them to disk to avoid to juggle with CDs and don't plan to buy a portable, I might use the Main profile to increase quality. But thanks for the info, a luck I've asked or else I'd have encoded a batch of CDs in Main by now.


Yes, the name of this profile is a little bit misleading, that's true.

QUOTE
LTP doesn't seem to be active on high bitrate anyway, the files are always same size and differ only in less than 50 bytes (I guess it has something to do with frameheaders?)


I'm not sure if it works at all, because I could not detect any differences in my low bitrate tests with PsyTEL, too. If you want to try another useless setting, enable PNS... wink.gif But Ivan already confirmed that this was buggy (generating even stranger sounds than Main) and that it has been fixed in Nero AAC.
kotrtim
Back to pre-echo:

Image: Time smearing of different codecs

-You can see that MP1, MP2 and MPEGplus/MPC have least problems with pre-echos.

-MP3 has much problems with pre-echos

-MPEG-2 AAC something between

-MPEG-4 AAC uses TNS and can be better than MP1, MP2 and MPEGplus




Why have MP3 and AAC less time resolution?

They have a higher frequency resolution and a higher frequency resolution means a lower time resolution because these two properties are coupled.

This higher frequency resolution has advantages if you encode highly tonal signals, but makes lots of trouble on transient signals

Therefore MP3 and AAC uses blocks switching between two different time resolutions.

To select the right blocks size is difficult to calculate, and for MP3 even the short block is too long for percussive signals

To my mind only MPEG-4 AAC is capable to eliminates all disadvantages of the additional frequency resolution. The result is transparent coding at data rates around 120...130 kbps (instead of 170...180 kbps as MPEGplus). But a

high quality MPEG-4 AAC Encoder is much much more difficult to program and to tune than a MPEGplus encoder

Is by a factor of 10...30 slower

also the decoder needs much more powerful hardware (most hardware can only play MPEG-2 AAC Low Complexity Profile)

Copied from Frank's Musepack page

Why don't use MPC, but I think this might help you a little about TNS

Edit:
QUOTE
That's because main prediction doesn't work good, not because of TNS. Use LC.

Hey, Menno you should be tuning TNS to improve time resolution instead of focusing on LC!
Tripwire
Constant bitrate? Atm yes.
menno
QUOTE(kotrtim @ Jan 4 2003 - 03:37 PM)
-MPEG-2 AAC something between

-MPEG-4 AAC uses TNS and can be better than MP1, MP2 and MPEGplus

MPEG-2 AAC also has TNS!
QUOTE
Hey, Menno you should be tuning TNS to improve time resolution instead of focusing on LC!

TNS is also part of the LC profile!

Menno
SK1
Hmm, so this is misleading:
QUOTE
MPEG-4 AAC Main Profile provides an additional feature called TNS: Temporal Noise Shaping. This provides additional time resolution.

QUOTE
# MPEG-2 AAC something between
# MPEG-4 AAC uses TNS and can be better than MP1, MP2 and MPEGplus

from this page
menno
Yes, it is.

Menno
Tripwire
So MPEG-4 AAC LC does also use TNS, or not?
kotrtim
QUOTE(Tripwire @ Jan 4 2003 - 02:51 PM)
So MPEG-4 AAC LC does also use TNS, or not?

Yes,

MPEG-2 LC vs MPEG-4 LC

When accuracy is compared
MPEG-4 with a few kb smaller is always more accurate than MPEG-2
menno
QUOTE(kotrtim @ Jan 5 2003 - 08:11 AM)
When accuracy is compared
MPEG-4 with a few kb smaller is always more accurate than MPEG-2

Can you explain that? Cause I don't see why that would always be the case.

The only difference between MPEG-4 AAC LC and MPEG-2 AAC LC is that MPEG-4 AAC could use PNS. This is usually only used on lower bitrates, so on the higher bitrates MPEG-2 and MPEG-4 AAC LC are the same.

Menno
JohnV
Yeah, I think some people are mixing PNS and TNS. wink.gif
Tripwire
Yeah, but I meant temporal noise shaping. smile.gif
Ivan Dimkovic
This is getting really confusing:

Both MPEG-2 and MPEG-4 AAC LC (Low Complexity) can (and they do) use TNS (Temporal Noise Shaping)

MPEG-4 AAC LC can also use PNS (Perceptual Noise Substitution, but this is useful for very low bit rates only - so it is not too relevant for this discussion.

AAC LC contains all important AAC tools (both MPEG-2 and MPEG-4 AAC LC), more complex AAC profiles contain various prediction algorithms (MPEG-2 AAC uses backward adaptive prediction in MPEG-2 AAC MAIN profile, MPEG-4 has Long Term Prediction in MPEG-4 LTP profile and reduced-complexity bw. prediction similar to MPEG-2 AAC in the MAIN profile), and these predictions are not too important, except for some highly stationary signals where prediction could save some bits.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2008 Invision Power Services, Inc.