Skip to main content

Notice

Please note that most of the software linked on this forum is likely to be safe to use. If you are unsure, feel free to ask in the relevant topics, or send a private message to an administrator or moderator. To help curb the problems of false positives, or in the event that you do find actual malware, you can contribute through the article linked here.
Topic: Q: improving sound of old .mp3 files by filtering artifacts? (Read 26645 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

Q: improving sound of old .mp3 files by filtering artifacts?

Before shouting «no, you cannot know what has been deleted»: this is not about knowing, it is about guessing better than one could once upon a time in the previous millennium.


Back in the 90's, you could way more often than today single out an mp3 file by its artifacts (for given bitrate in suitable range
  • ). Of course we could not know without the original whether a certain signal is an encoding artifact or is part of the music, but back in those days we could fairly often make an educated guess by listening -- doing «ABX except without the A and B».

    So, the last 15 years have brought forth lossy encoders which are better at avoiding audible artifacts: Not only do we know better what to avoid, we also know better how to avoid it. And in principle, it might very well be possible to use this improved knowledge to (i) detect in an old mp3 file «what would have been avoided today», and (ii) filter it out. Not to achieve the impossible certainty that this part of the signal was not in the original source, but to achieve fewer audible nuissances more often than not.


    Q: Has this been attempted, successfully or not?


    (Any such tool could be easily testable if one has an old encoder and a lossless source and a few good ears.)




  • I presume that http://listening-tests.hydrogenaudio.org/s...8-1/results.htm should keep TOS#8 moderation off my back.

Q: improving sound of old .mp3 files by filtering artifacts?

Reply #1
How often do you have three or copies of the same track each from a different encoding?  Seems like even if this were possible you'd never actually have a use for it.

Q: improving sound of old .mp3 files by filtering artifacts?

Reply #2
No, I am talking of one. One old mp3 with artifacts we could by now know how to identify algorithimically and filter away in a way that more often than not results in an improvement.

Q: improving sound of old .mp3 files by filtering artifacts?

Reply #3
No, I am talking of one. One old mp3 with artifacts we could by now know how to identify algorithimically and filter away in a way that more often than not results in an improvement.


I assumed you mean A/Bing multiple samples to figure out what was an artifact.  If not, how exactly do you propose to figure out what is an artifact?  And what would you do about it?

Q: improving sound of old .mp3 files by filtering artifacts?

Reply #4
I assumed you mean A/Bing multiple samples to figure out what was an artifact.  If not, how exactly do you propose to figure out what is an artifact?  And what would you do about it?


I take it that what Porcus meant was that some kinds of sounds are characteristically artefacts of bad MP3 coders, so that if he hears, say, ringing in an old MP3 file, he doesn't for sure know it's an artefact, but he'll take the chance and remove it, if that is possible. It might have been deliberately introduced--you could only tell for sure by comparing--but he'd still like it gone. Would that be possible?

Q: improving sound of old .mp3 files by filtering artifacts?

Reply #5
It might have been deliberately introduced--you could only tell for sure by comparing--but he'd still like it gone. Would that be possible?


How do you "remove" something without knowing what it sounds like?  Aside from muting the audio that is

Its rather hard to "remove" something that occurs due to missing information or excessive approximation.

Q: improving sound of old .mp3 files by filtering artifacts?

Reply #6
Processing filters to remove encoding artifacts such as blocking, banding, ringing are rather common in video.
Of course lost information cannot be recovered. They are applied just to get better perceived quality...though they usually have unwanted side-effect, too (removing noise usually removes not only noises but also details).

OP might be thinking of something like that... just a guess.

Q: improving sound of old .mp3 files by filtering artifacts?

Reply #7
How do you "remove" something without knowing what it sounds like?  Aside from muting the audio that is


We know what it «sounds» like. I tried to explain that in fair detail in the original post, but again: even if we do not know for certain for every given sample that this particular property is an artifact or not, we know enough to guess better than 50/50 on real-world music (this for the relevant bitrange).

We also have knowledge about how to avoid it, given that we know the original. Again, not perfect knowledge, but fairly good knowledge -- this is the reason why you can encode a 1000 kbps FLAC file from CD into a 100 kbps mp3 file and still sounds ... if not transparent, so arguably superior to a random 90% removal of information.

And this knowledge has improved over the last 15 years. (Of course, Moore's law makes it harder to distinguish between improved knowledge and improved ability to utilize it.)

So then comes the question: has the science of psychoacoustics gotten us far enough to filter even without the exact original? We do not need to be able to filter everything -- it suffices that for a suitable percentage of low-bitrate files, it improves, and the rest it can leave untouched.


Processing filters to remove encoding artifacts such as blocking, banding, ringing are rather common in video
[...]
to get better perceived quality


Good point. Another example is the crackle/pop removal algorithms for digitalization of vinyl. (And the good'ole subsonic filter on phono pre-amps.)



Q: improving sound of old .mp3 files by filtering artifacts?

Reply #8
It's just an audio restoration challenge that (AFAIK) know one has really tackled yet. (IIRC creative claimed some of their sound cards did this, but I don't know if they really did).

When there's enough content that only exists as low-ish quality lossy audio that people want to re-issue in <tomorrow's new wonder audio format>, someone will come along and invent a process for making it sound better.


If it was me, I'd go after the splashy metallic artefacts that ruin the high frequencies first. Little idea how to though - most attempts to re-synthesize high frequencies sound pretty metallic themselves.

Cheers,
David.

Q: improving sound of old .mp3 files by filtering artifacts?

Reply #9
I think one very crude way to do this could be to just use a lowpass filter. Indeed, some of the most annoying MP3 artifacts come from poorly-encoded high frequencies. You could add a lowpass filter at, say, 7 kHz and remove all the high-frequency content, and your audio might sound less artifacted. However, this assumes there aren't also artifacts in the lower frequencies (which is often the case with poor encodes). And you'd also be able to tell very apparently that the audio had been lowpassed, it'd sound like something recorded in the 1950s. Whether or not that sounds better than leaving the artifacted high freqs intact is entirely subjective.

I don't know much about the theoretical side of audio processing, FFTs and such, but it seems like removing MP3 artifacts would be very difficult, if not impossible, and the results would not be that great. Doesn't sound like something that would be worth someone's time to develop.

Q: improving sound of old .mp3 files by filtering artifacts?

Reply #10
For badly encoded voice you might try recompressing it with a speech codec to see if that is forced to throw away some artefacts it considers unencodable.

Q: improving sound of old .mp3 files by filtering artifacts?

Reply #11
I know this is an old thread, but I came to this forum today to ask something about this subject and found this thread.

I'm planning to try to make a filter like this. I'm pretty sure that it's possible - the only thing is that I don't have too much time to spend on this, so I'll give it a try for a few days to see how far I can get. Before I do that, I just want to check:
- Is there anything available like this now? I have searched, and only found this: http://www.fidelityamplifier.com/ , which seems to do a kinda fair job at restoring high frequencies after lowpass filtering, but it doesn't improve MP3s at all - actually it makes them sound worse due to what appears to be incorrect lowpass filter frequency detection.

- It would help to have a precise description of the type of MP3 artifacts that can occur. Some are obvious (holes in the spectrum which are probably related to the metallic sound, pre- and postringing - but it would be useful to know if there are exact times that they can assume (I know MP3 works with 1152 samples, but I don't know how big the overlap between blocks is, and it can also use a more fine-grained block size when needed). Also, different encoders with different settings might make different choices, so just encoding a bunch of files at low bitrates and analyzing them isn't sufficient to determine what's possible.

I know that many people are going to say that if data is gone you cannot restore it - just to show that I'm serious about this, 3 years ago I was tired of clipped audio on source material and created a declipper - see https://www.youtube.com/watch?v=oqOljvx9KaM . Right now, I'm tired of bad quality MP3s, so I want to try to do something similar for MP3 (and maybe also other lossy) audio. Because it's probably impossible to reliably detect MP3 artifacts (*) it will not be perfect - but it would really be nice if I could make MP3s sound a lot better.


(*) actually it might be. If I look at the spectrum in my own software, I see frequency ranges with absolute silence in low bitrate MP3 files, which I have never seen in uncompressed audio. But I think this won't help to detect pre/post ringing.

Q: improving sound of old .mp3 files by filtering artifacts?

Reply #12
StereoTool now includes a filter that is exactly what is described in this thread.

However, it is still in the "experimental" stage.

To enable it, you have to set StereoTool to "Extreme Tweaker", and the filter appears in the StereoTool interface. It is called the "Delossifier." It is designed for filtering ringing from compressed audio.


Q: improving sound of old .mp3 files by filtering artifacts?

Reply #13
I think the biggest problem with that idea is how to determine if the 'warbling' for example is intentional or not. IE is it intentional vibrato from a guitar amp or some electronic effect? Or is it a real mp3 artifact? Oh how many times I've chased THAT tail while abx'ing lossy codecs...

Q: improving sound of old .mp3 files by filtering artifacts?

Reply #14
Just a heads-up on this topic, there is a shareware Photoshop plugin that cleans JPEG artifacts and does an amazing job at that (it's called Topaz DeJpeg) and has some before/after images at the bottom of their website: https://www.topazlabs.com/dejpeg

It does an amazing job and although I don't know this could be of any use at MP3 de-noising, but if JPEG images can be restored this effectively, it most probably can be done with MP3s too... and I'm also interested in any such software!

Q: improving sound of old .mp3 files by filtering artifacts?

Reply #15
Just a heads-up on this topic, there is a shareware Photoshop plugin that cleans JPEG artifacts and does an amazing job at that (it's called Topaz DeJpeg) and has some before/after images at the bottom of their website:


Thats mostly just blending the transform blocks.

MP3 already takes care of that by using the MDCT.

Re: Q: improving sound of old .mp3 files by filtering artifacts?

Reply #16
StereoTool now includes a filter that is exactly what is described in this thread.
That was just a thing that removes pre-ringing, but now it actually has a filter that reconstructs the spectrum. It's still called the 'Delossifier', but it now consists of 2 parts: Pre-ringing killer and Spectral Hole Filler. It's not perfect but it definitely makes the sound less annoying, mainly at lower bitrates.

Re: Q: improving sound of old .mp3 files by filtering artifacts?

Reply #17
Malware warning, Virustotal:

Re: Q: improving sound of old .mp3 files by filtering artifacts?

Reply #18
Looks like false positive, detection rate is low and almost all of them are heuristic. I tried the VST version and attached a sample, the flac is processed with Delossifier.

Re: Q: improving sound of old .mp3 files by filtering artifacts?

Reply #19
A 32kbps mp3 processed by Delossifier 20 times. Spectrophiles must love this plugin. BTW each time I processed it the volume also decreased a bit, don't know why.

Re: Q: improving sound of old .mp3 files by filtering artifacts?

Reply #20
Let us assume that modern codecs represent the very state of the art in knowledge about how to recreate a piece of music in a way that is perceptually "believable" and "non-annoying" using a minimum amount of bits to transfer that information. If there is a way to (on average) improve the listening experience without transferring more information, new codecs would probably embrace that technology.

However, older codecs might not have had access to the current knowledge. Further, it seems fair to assume that 20 or 30 year old codecs would have been severly limited by the available processing power and memory.

So what if one used a state-of-the-art representation of human hearing (some auditory filter bank with masking etc) to analyze known references (CDs) as well as known "noisy" output (lossy compressed/decompressed versions using a given codec/parameters) using (trendy tool of the day) machine learning. Could such a black box "learn" something about systematic errors when judged on a subjectively sensible set of parameters?

Naiively, one might hope for a tool that _recognize_ Beethovens 5th symphony in a poor recording, at extremely low bitrate and _substitute_ it for a pristine recording. Somewhat less naiively, one might hope that subjectively important "structure" present in typical music, ignored/distorted by bad encoders could be fixed up?

-k

Re: Q: improving sound of old .mp3 files by filtering artifacts?

Reply #21
Quote
Naiively, one might hope for a tool that _recognize_ Beethovens 5th symphony in a poor recording, at extremely low bitrate and _substitute_ it for a pristine recording.
Somebody told me you can digitize a vinyl record an upload it to iCloud and iTuned Match will replace the scratchy vinyl with the clean iTunes version.

But, that's not compression.  It's indexing.

Re: Q: improving sound of old .mp3 files by filtering artifacts?

Reply #22
 So let us just say that the Mp3 format is a failure to begin with and was released to the consumer anyway. 
And let it be known that all digital audio has artifacts even 384k and above.

Here is some things I have found with my dealings with Mp3 that may help.

 1. When downloading from the internet you are subject to electro as well as mechanical interference's . as well as the site claim to have perfect files.
 2. When ripping from CD. I find two methods that work well one is to filter out freq above 15k before compression or up sample the file to 192k add a tape simulator vst then compression to Mp3 using" same bit and sample rate as original "
This seems to work very good and on average will give you a cut off freq of about 18k and a mp3 file of 48/16.
 3. Changing the file to 729k " up sample " will  affect the transits of the file after which a 48db filter starting at lets say 10k will help
and leave enough high end info to somewhat enjoy.
 4. Static filters can work such as cuts at 10830,7830,and 4830 k work but audio is not static so you may hear some funky stereo effects narrowing the width of the file will help this.
  5. Using a vst called sample reducer and setting it around 18-19k run it parallel with the signal then reversing the original then roll off the top with the 48db filter will give good enough results.
 Now all of the above is for you in the box folks
You know just push play....................
The best way i have found is to reprint ' ( re -record ) using the above filters or a combination of and a good old fashion rack mounted analog Eq , compressor, and delay at good ole 96k/24bit WAV file.
 Lets say it sounds like a 15ips reel to reel with DBX  and has depth as well as cross talk
basically all the things in the box guys don't like or understand .
Analog Heads................
Gotta love it..................
 Is it perfect ? By no means
 Is it worth it ? it could be
A hybird system is all that's needed  and it works about 90% of the time even on Youtube downloads.
Which makes this method  cheap to use

Re: Q: improving sound of old .mp3 files by filtering artifacts?

Reply #23

Re: Q: improving sound of old .mp3 files by filtering artifacts?

Reply #24
that post looks like AI generated copypasta
a fan of AutoEq + Meier Crossfeed