Skip to main content

Topic: how to compress 93gb speech mp3 files with low noise using lame. (Read 3461 times) previous topic - next topic

0 Members and 1 Guest are viewing this topic.
how to compress 93gb speech mp3 files with low noise using lame.
Hi I am Rupesh from India. I have a huge directory of size 93.5 gb with 8500 mp3 files and 2000 sub directories.

All these mp3s are speeches recorded by someone at 64 kbps. I want to compress these files recursively using lame with 16 kbps bit rate and 11050 sample rate.

I have compressed the above huge directory with above options using ffmpeg and the resulted destination directory size was 29.5 gb and the quality was not good. Then I thought instead of compressing using ffmpeg it is better to compress using lame.

I have compressed some directories with options given below using lame and the quality was not good.

Code: [Select]
 lame    --abr 20 -m j -q 0 --resample 22.05 --priority 4
lame    --abr 16 -m j -q 0 --resample 11.025 --priority 4
lame    --abr 16 -m j -q 0 --resample 22.05 --priority 4

The files I converted using ffmpeg was better than the files converted using lame.

In the above sound quality was not good I mean after the compression completed when I try to play these files on any music player I am getting    sounds like sshhh... garrr... and some electronic noises.

Please try to suggest optimal settings to compress these speech mp3 files I mean less noises like sshhh garrrr and other such electronic noises.
Are there any other ways to reduce these noises during the process of compression.

I think that sample rate and bit rate play a lead role together in compression I mean it is not feasible to use 44.1 kHz to 16 kbps bit rate and so suggest the correct sample rate to 16 kbps and 24 kbps.

If it is not possible to eliminate these noises in 16 kbps bit rate try to suggest at other bit rates upto 24 kbps.

As I am new to audio compression please suggest optimal settings I mean bitrate below 24 kbps, sample rate to the corresponding bitrate, replay gain, athtype, highpass, low pass etc., found in lame documentation.


Regards,
Rupesh.

  • dhromed
  • [*][*][*][*][*]
Re: how to compress 93gb speech mp3 files with low noise using lame.
Reply #1
I think you're confusing bit-RATE with bit-DEPTH.
mp3 has no bit-depth. When decoded and played, they'll probably all be 16-bit, according to your sound card settings, so you don't have to think about that when compressing to mp3.

16kbps is the bitrate, the amount of data per second, and it's very low. Try something higher. 64 is also low, but usually okay for speech. You're also transcoding from lossy to even more lossy, wich will enlarge any artifacts that were in the 64kbps version.

You might be able to get away with a lowpass of 8KHz or lower, but you'll have to test a few files and see if it sounds okay.

  • lvqcl
  • [*][*][*][*][*]
  • Developer
Re: how to compress 93gb speech mp3 files with low noise using lame.
Reply #2
Encode to mono:
lame --abr 16 -m m --resample 11025

  • Porcus
  • [*][*][*][*][*]
Re: how to compress 93gb speech mp3 files with low noise using lame.
Reply #3
I know the OP asks for LAME mp3s, but maybe one should give Opus a shot?  I have no idea how artifacts compound when encoding first to 64 and then to 16. 

(Of course you keep the originals, right?)

  • LithosZA
  • [*][*][*][*]
Re: how to compress 93gb speech mp3 files with low noise using lame.
Reply #4
There is a 16Kbps Opus vs 16Kbps MP3 comparison on Wikipedia to give you an idea: https://en.wikipedia.org/wiki/Opus_(audio_format)#Support
Click the play button on the player on the right side of the screen.

  • dhromed
  • [*][*][*][*][*]
Re: how to compress 93gb speech mp3 files with low noise using lame.
Reply #5

Re: how to compress 93gb speech mp3 files with low noise using lame.
Reply #6
Well, this is weird.
https://hydrogenaud.io/index.php/topic,114145
https://hydrogenaud.io/index.php/topic,114147

Yes I have created those new threads because those are specific to the corresponding topic and those threads will attract more viewers.

  • o-l-a-v
  • [*][*][*]
Re: how to compress 93gb speech mp3 files with low noise using lame.
Reply #7
I bet you can save some gigabytes losslessly using mp3packer. Have you tried it? It's included with FileOptimizer at Sourceforge (if you want GUI). Or else there is WinMP3Packer.
  • Last Edit: 31 May, 2017, 02:56:05 AM by o-l-a-v

  • dhromed
  • [*][*][*][*][*]
Re: how to compress 93gb speech mp3 files with low noise using lame.
Reply #8
Yes I have created those new threads because those are specific to the corresponding topic and those threads will attract more viewers.
ok, I'm sorry for my doubt.

My original advice still stands, that 16kbps is probably too low for good speech.
Going from 64 to 32kbps and from stereo to mono should reduce the data to 25% while still keeping acceptable quality.

  • pdq
  • [*][*][*][*][*]
Re: how to compress 93gb speech mp3 files with low noise using lame.
Reply #9
Going from 64 to 32kbps and from stereo to mono should reduce the data to 50% while still keeping acceptable quality.

  • dhromed
  • [*][*][*][*][*]
Re: how to compress 93gb speech mp3 files with low noise using lame.
Reply #10
Stereo to mono does not (roughly) half the data?

  • Fairy
  • [*][*][*]
Re: how to compress 93gb speech mp3 files with low noise using lame.
Reply #11
Stereo to mono does not (roughly) half the data?

No. A 128kbps stereo mp3 is 128kbps not 256kbps.

the bitrate is not connected to the amount of channels but is the total bitrate for the file, de bitrate is then shared between the channels via pure stereo or joint stereo mode (or dual mono IIRC).

PS. I would go for the Opus codec. It's way better than MP3 at low bitrates.
  • Last Edit: 31 May, 2017, 08:53:39 AM by Fairy

  • Porcus
  • [*][*][*][*][*]
Re: how to compress 93gb speech mp3 files with low noise using lame.
Reply #12
FileOptimizer at Sourceforge

Why have I never heard about that before?

... I see that the FAQ is full of explanations why this-and-that particular operation is not lossless. Use with caution then.

Re: how to compress 93gb speech mp3 files with low noise using lame.
Reply #13
Some of you suggested to use opus codec instead of mp3 at 16 kbps and so I want to use mp3 at higher frequencies and bitrates. I am going to use opus codec for speech files at 16 kbps.

  • greynol
  • [*][*][*][*][*]
  • Global Moderator
Re: how to compress 93gb speech mp3 files with low noise using lame.
Reply #14
the bitrate is not connected to the amount of channels but is the total bitrate for the file, de bitrate is then shared between the channels via pure stereo or joint stereo mode (or dual mono IIRC).
When encoding in mono, the single channel gets twice as much data as one channel encoded in dual mono at the same bitrate.

When encoding in L+R, one channel can get more data than the other in a given frame.

When encoding in L+R/M+S, data can also distributed as the encoder sees fit.

Since L/R and M/S are mathematically equivalend, both L+R/M+S (joint-stereo) and L+R (stereo) are "pure stereo".
Is 24-bit/192kHz good enough for your lo-fi vinyl, or do you need 32/384?

  • dhromed
  • [*][*][*][*][*]
Re: how to compress 93gb speech mp3 files with low noise using lame.
Reply #15
> No. A 128kbps stereo mp3 is 128kbps not 256kbps.
Oh derp, of course.
I was literally thinking that while typing that post, my brain must have partially switched off or something.

  • Porcus
  • [*][*][*][*][*]
Re: how to compress 93gb speech mp3 files with low noise using lame.
Reply #16
my brain must have partially switched off or something.
And possibly you did not even save any bitrate from downmixing your left & right cerebral hemispheres to mono? ;)

  • pdq
  • [*][*][*][*][*]
Re: how to compress 93gb speech mp3 files with low noise using lame.
Reply #17
my brain must have partially switched off or something.
And possibly you did not even save any bitrate from downmixing your left & right cerebral hemispheres to mono? ;)
Sometimes it feels as if my brain is in forced stereo mode.