Skip to main content

Topic: Bit rate changed when ape to flac (Read 5129 times) previous topic - next topic

0 Members and 1 Guest are viewing this topic.
Bit rate changed when ape to flac
hi,

  Since my portable audio player not support ape, thus I converted to flac. I use foobar2000 do the stuff.

  Here are my fb2k configuration:
  fb2k latest version
  flac-1.2.1
  FLAC level 5

  But the problem is, I test 20 different ape files+ to flac, but after convertion the flac bit rate is not the same as original ape file

  My question is, since both format are "loseless", why the ape bit rate and flace bit rate are not the same?

  Some "component" is missing? Or something's wrong..?

  Hope I can figure what's going on

thanks for help~

  • benski
  • [*][*][*][*][*]
  • Developer
Bit rate changed when ape to flac
Reply #1
hi,

  Since my portable audio player not support ape, thus I converted to flac. I use foobar2000 do the stuff.

  Here are my fb2k configuration:
  fb2k latest version
  flac-1.2.1
  FLAC level 5

  But the problem is, I test 20 different ape files+ to flac, but after convertion the flac bit rate is not the same as original ape file

  My question is, since both format are "loseless", why the ape bit rate and flace bit rate are not the same?

  Some "component" is missing? Or something's wrong..?

  Hope I can figure what's going on

thanks for help~


the "bitrate" of a lossless file represents the size-per-second after the lossless compression has been done.  It does not represent the size of the audio data after it is decompressed (which will always be the same).  APE and FLAC use different lossless compression technologies and therefore will have different sizes.  APE tends to produce very slightly smaller sizes, at the expense of requiring more CPU time to decode.  The audio data is always the same though!
  • Last Edit: 06 July, 2011, 10:48:31 PM by benski

Bit rate changed when ape to flac
Reply #2
The bitrate is the compressed bitrate, not the uncompressed rate which will be bit identical / equal.  APE and FLAC have different algorithms and I would expect some differences in the amount of compression each can achieve and therefore the bit rate would change.  Use FLAC level 1 and you'll get a higher bit rate than FLAC level 8 - but they will produce bit-identical outputs after decoding.  IIRC, APE compresses more than FLAC typically so I would expect a larger file for FLAC and hence a higher bit rate reported, although the decoded output will be identical between APE and FLAC.
Was that a 1 or a 0?

Bit rate changed when ape to flac
Reply #3
The bitrate is the compressed bitrate, not the uncompressed rate which will be bit identical / equal.  APE and FLAC have different algorithms and I would expect some differences in the amount of compression each can achieve and therefore the bit rate would change.  Use FLAC level 1 and you'll get a higher bit rate than FLAC level 8 - but they will produce bit-identical outputs after decoding.  IIRC, APE compresses more than FLAC typically so I would expect a larger file for FLAC and hence a higher bit rate reported, although the decoded output will be identical between APE and FLAC.


Thanks~

that make me know the details~

Bit rate changed when ape to flac
Reply #4
and one more questions...
i use fb2k, media info, those are display the 'compressed bitrate'
then how can i know the original cd bitrate..?

thanks~
  • Last Edit: 11 July, 2011, 12:15:38 PM by db1989

  • trout
  • [*][*][*][*]
Bit rate changed when ape to flac
Reply #5

how can i know the original cd bitrate..?

That's easy. The bitrate of an audio CD (CDDA) is always 1411.2 kbit/s.

Channels x Sample rate x Bits per sample = bits per second


  • odyssey
  • [*][*][*][*][*]
Bit rate changed when ape to flac
Reply #6
You probably confuse bitrate with lossy compressed files.

When a file is compressed "lossy", you often choose CBR (constant bit rate) to restrict the file to be within a specific size.

A lossless compressed file cannot be restricted to a specific bitrate, as it wouldn't be lossless if you threw away any bits.
Can't wait for a HD-AAC encoder :P

  • db1989
  • [*][*][*][*][*]
  • Global Moderator
Bit rate changed when ape to flac
Reply #7
A lossless compressed file cannot be restricted to a specific bitrate, as it wouldn't be lossless if you threw away any bits.
To add, though: it can have a mean (often reported using the term average, but anyone who’s studied a tiny bit of statistics knows to frown upon that!) bitrate, which will be what thinksloth saw. The reason the mean bitrate differs between formats is that, for any given waveform, the encoders will be of differing efficiencies; one will compress it to a smaller total file size than the other.

Bit rate changed when ape to flac
Reply #8
A lossless compressed file cannot be restricted to a specific bitrate, as it wouldn't be lossless if you threw away any bits.
To add, though: it can have a mean (often reported using the term average, but anyone who’s studied a tiny bit of statistics knows to frown upon that!) bitrate, which will be what thinksloth saw. The reason the mean bitrate differs between formats is that, for any given waveform, the encoders will be of differing efficiencies; one will compress it to a smaller total file size than the other.


oh, i think i am confused when thinking the questions but now make it clear, thanks all of yours answer.

Because as yours said loseless mean exactly the same as the cd.

And i also interested to know why some ape/flac files have such a low compressed bitrate, e.g. 290 kbps
I know when such a low bitrate require more cpu work when decode, but it can save the portable media player storage.

Bit rate changed when ape to flac
Reply #9
You should go back and read the replies in this thread again as they clearly state how FLAC and APE (along with other non-CBR lossless formats) can produce files with varying bitrates.  There are many aspects that influence bitrate and, in my experience, lossless files with extremely low bitrates tend to contain a large portion of mono audio (or be completely mono), are comprised of simple low beats, or have long lengths of silence thus bringing down their overall average bitrate.  There are other things as well.  Either way, as previously pointed out, you shouldn't be focused on the bitrate of lossless files as that doesn't matter.  You can encode at FLAC level 1 and get a different bitrate than at FLAC level 8 yet both files will be exactly the same.

  • odyssey
  • [*][*][*][*][*]
Bit rate changed when ape to flac
Reply #10
And i also interested to know why some ape/flac files have such a low compressed bitrate, e.g. 290 kbps

Because the final bitrate depends on the content. If you have a pure silence file, it can be compressed to almost nothing, even if it's several hours long - Because it's simple, there is nothing to encode, really. The more complex the music (/waveform) are, the harder it can be to encode.

If you encode white noise, you will see that it's almost impossible to compress, because it's complex (there are no patterns).

A typical example of this, is recent music (which are almost per definition subject to the "loudness war") is boosting the waveform so much that it is more like the white noise example, whereas older music is much quiter and easier for the encoder to compress. So typically you will see older music being able to compress to lower bitrates than newer music.

If you are familar with zip-archives, it's pretty much the same. Nothing within is changed, but a large collection of text-documents is easy to compress, while complex files, as videos, images etc are harder to compress.

I know when such a low bitrate require more cpu work when decode, but it can save the portable media player storage.

No it doesn't. Some efficient encoders (e.g. APE) that uses complex algorithms to reduce the bitrate, also requires complex decoding techniques - THAT takes up CPU power.
Can't wait for a HD-AAC encoder :P