INTERACT FORUM

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: FLAC compression levels question(s)  (Read 6856 times)

FenceFurniture

  • Galactic Citizen
  • ****
  • Posts: 420
FLAC compression levels question(s)
« on: August 08, 2019, 11:54:14 pm »

Not being at all tech minded, as I have been demonstrating in my G drive thread  ::) I have only just found out that file compression doesn't affect sound quality, just the speed at which the file can be read by any given device.

On my PC that won't be a problem with bigger compression levels (I wouldn't think), but for my DAP which is a Shanling M3s it might be - I have posted a question in their forum to see what they recommend. EDIT: just had a response over there and they think any compression level will be ok for the M3S.

Someone I was talking to this morning (who wised me up) said that he felt the sweet spot for compression was level 5. So I copied a folder a couple of times to do some tests for space saved, and then imported them into MC 23, and compressed them both. wer, I learnt my lesson and did it within MC :)

The original uncompressed folder is 526Mb
Compression level 5 made it 508Mb
and level 6 made it 493Mb

Hardly worthwhile for a 5% space saving, but maybe I didn't do it correctly. I have the Convert Format dialogue open, convert 12 files to: "FLAC encoder" (even though they are flac already), and then clicked options, "convert to same folder", "replace original on disc and library". In the encoder settings I have the level (5 or 6) but I didn't know what to do with the other options:
Verify encoding left unchecked
Add 4k padding block has a x
Add seek table has a x
Use Ogg as transport layer is unchecked

I'd be interested in some thoughts on compression levels and any tips that people might have please.


Logged

wer

  • Citizen of the Universe
  • *****
  • Posts: 2640
Re: FLAC compression levels question(s)
« Reply #1 on: August 09, 2019, 12:07:54 am »

No, you have discovered FLAC's dirty secret...

Higher compression levels yield little benefit.  On some occasions, I have actually seen it increase file size.  That's why 5 is the recommended level.

Stick with level 5, the default, and don't worry about it.
Logged

FenceFurniture

  • Galactic Citizen
  • ****
  • Posts: 420
Re: FLAC compression levels question(s)
« Reply #2 on: August 09, 2019, 12:17:47 am »

Stick with level 5, the default, and don't worry about it.
In that case I don't think I could be bothered doing it at all - a lot of work for a <5% space saving.

The flac files this other fella has are all much more compressed. Usually around half the size of mine for any given album. He ripped them with dbPoweramp (as I do) and set the compression level to 5. I might re-do one of my CDs as a test.
Logged

RoderickGI

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 8186
Re: FLAC compression levels question(s)
« Reply #3 on: August 09, 2019, 12:40:08 am »

I thought 6 was the recommended compression level...

Yeah, the FLAC Encoder MC uses has 6 as the recommended level.

There have been detailed discussions on the topic in the past. Including information on how much difference on size the different level make. Answer: Not much, if in the mid-range.
See this post and thread: https://yabb.jriver.com/interact/index.php/topic,117944.msg816031.html#msg816031

Hard drive space is cheap. FLAC files aren't that big. Set to 6 and leave it be.
Logged
What specific version of MC you are running:MC27.0.27 @ Oct 27, 2020 and updating regularly Jim!                        MC Release Notes: https://wiki.jriver.com/index.php/Release_Notes
What OS(s) and Version you are running:     Windows 10 Pro 64bit Version 2004 (OS Build 19041.572).
The JRMark score of the PC with an issue:    JRMark (version 26.0.52 64 bit): 3419
Important relevant info about your environment:     
  Using the HTPC as a MC Server & a Workstation as a MC Client plus some DLNA clients.
  Running JRiver for Android, JRemote2, Gizmo, & MO 4Media on a Sony Xperia XZ Premium Android 9.
  Playing video out to a Sony 65" TV connected via HDMI, playing digital audio out via motherboard sound card, PCIe TV tuner

FenceFurniture

  • Galactic Citizen
  • ****
  • Posts: 420
Re: FLAC compression levels question(s)
« Reply #4 on: August 09, 2019, 12:44:31 am »

Original uncompressed 526Mb
re-ripped with dbPoweramp at level 0 "Fast" yields 355Mb
re-ripped with dbPoweramp at level 1 yields 346Mb
re-ripped with dbPoweramp at level 3 yields 340Mb
re-ripped with dbPoweramp at level 5 yields 328Mb (very worthwhile space saving)
re-ripped with dbPoweramp at level 8 yields 326Mb (no gain over L5)

So maybe it's all in the original ripping? Results above suggest that with dbPoweramp setting level 5 or 6 is the sweet spot, and no difference between them. Other software might be different of course.
Logged

FenceFurniture

  • Galactic Citizen
  • ****
  • Posts: 420
Re: FLAC compression levels question(s)
« Reply #5 on: August 09, 2019, 12:49:30 am »

I thought 6 was the recommended compression level...
in dbPoweramp the default is 5, so that is probably what they think is the sweet spot, I suppose. I'll finish these rips soon and update the stats I just posted.

Hard drive space is cheap. FLAC files aren't that big. Set to 6 and leave it be.
True, but I'm running out of space on my Solid State drive in the Laptop.
Logged

wer

  • Citizen of the Universe
  • *****
  • Posts: 2640
Re: FLAC compression levels question(s)
« Reply #6 on: August 09, 2019, 01:11:58 am »

If you just google "flac compression levels" there's been lots of discussion over the years on this.  Wikipedia even has a comparison.

People have even done studies, compressing large amounts of different types of music, and performing statistical analysis on the results.

Every music file will compress differently, and generally compression levels are worse for classical music than rock.  But the general consensus is that size benefits beyond level 5 are negligible.  Between 0 and 5, it's a trade-off between encoding speed vs a moderate amount of additional compression.

dbPowerAmp defaults to 5, MC to 6.  FenceFurniture is using dbPowerAmp like I am.
Logged

FenceFurniture

  • Galactic Citizen
  • ****
  • Posts: 420
Re: FLAC compression levels question(s)
« Reply #7 on: August 09, 2019, 01:52:11 am »

I had a thought that maybe I could use dbP to compress existing files and get a better result, but it only works from ripping a CD unfortunately. So it does seem that it is all in the original ripping that you can save decent space with compression - yer outta luck after the fact (with MC anyway) because the space savings are negligible.
Logged

wer

  • Citizen of the Universe
  • *****
  • Posts: 2640
Re: FLAC compression levels question(s)
« Reply #8 on: August 09, 2019, 02:01:01 am »

You can use MC to transcode to different compression levels, but it's a waste of time for little storage gain.

dbPowerAmp CD Ripper doesn't transcode files that have already been ripped and compressed.  Re-ripping just to recompress with dbPa is madness.  Let it go.

It doesn't matter if you use a different utility to recompress FLAC to a different compression level.  FLAC is a standardized algorithm and the same compression level on different apps will yield the same file size.  MC is no better or worse.  It's FLAC.
Logged

FenceFurniture

  • Galactic Citizen
  • ****
  • Posts: 420
Re: FLAC compression levels question(s)
« Reply #9 on: August 09, 2019, 03:12:33 am »

Yeah, that was just a summary - I've let it go.
Logged

JimH

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 72422
  • Where did I put my teeth?
Re: FLAC compression levels question(s)
« Reply #10 on: August 09, 2019, 06:32:38 am »

The flac files this other fella has are all much more compressed. Usually around half the size of mine for any given album.
There's probably a mistake somewhere.  The range of FLAC compression size is around 5%.

Have you looked at the cost of hard disks?

1 TB 2.5"  about $50 at Amazon

6 TB 3.5"  about $110

1 TB stores about 3,000 CD's or 30,000 FLAC files.
Logged

Hendrik

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 10926
Re: FLAC compression levels question(s)
« Reply #11 on: August 09, 2019, 06:40:35 am »

The amount of compression you can achieve also highly depends on the complexity of the music. We've seen some classical piano music that compressed really well, to such sizes that we thought something might be wrong, while other types of music won't really compress well at all. The fate of lossless compression, you highly depend on the content.
Logged
~ nevcairiel
~ Author of LAV Filters

FenceFurniture

  • Galactic Citizen
  • ****
  • Posts: 420
Re: FLAC compression levels question(s)
« Reply #12 on: August 09, 2019, 06:43:27 am »

There's probably a mistake somewhere.  The range of FLAC compression size is around 5%.
Yes that's what I found when I tried compressing using MC after ripping, but when I re-ripped the same CD at compression 5 using dbP it was a much bigger compression, as I posted in the results a little earlier. The other fella was also using dbP to rip (at level 5).

External storage is fine and cheap, but I am trying to find a solution that will obviate an external drive, and also (more importantly) fit onto a micro SD card. Just the SACD files alone will probably suck up 256Gb. This is for the DAP that I use.
Logged

Smilin_Jim

  • Recent member
  • *
  • Posts: 33
Re: FLAC compression levels question(s)
« Reply #13 on: August 19, 2019, 01:13:02 pm »

There is one good reason not to go with the above suggestions.  Some devices, like my 2019 Acura RDX, need the compression level set to 0 in order to read the file correctly. As far as it is concerned, anything other than 0 is unreadable.  0 is true heaven.

The JRiver MC23 documentation relates this setting to "quality."  It is not. It is just how aggressive FLAC is at trying to reduce file size.  The output of all compression levels should be a lossless file, all should decompress to exactly the same output. 

Note to anyone that decides to test this, as with any complex calculation, getting results from running a compression/decompression that vary by a few bytes from one pass to another doesn't necessarily mean the music changed.
Logged

JimH

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 72422
  • Where did I put my teeth?
Re: FLAC compression levels question(s)
« Reply #14 on: August 19, 2019, 01:26:27 pm »

The JRiver MC23 documentation relates this setting to "quality."  It is not. It is just how aggressive FLAC is at trying to reduce file size.  The output of all compression levels should be a lossless file, all should decompress to exactly the same output. 
Where did you see that?  You're correct.  It isn't a quality setting.
Logged

sygnus21

  • Junior Woodchuck
  • **
  • Posts: 76
Re: FLAC compression levels question(s)
« Reply #15 on: August 19, 2019, 03:04:21 pm »

in dbPoweramp the default is 5, so that is probably what they think is the sweet spot, I suppose. I'll finish these rips soon and update the stats I just posted.
True, but I'm running out of space on my Solid State drive in the Laptop.

In DBPoweramp the recommended compression level is 5. In JRiver Media Center its 6. I wouldn't get caught up in who thinks what compression level is best as these are different programs. Anyway I myself use no compression level in either program. That's me.
Logged

wer

  • Citizen of the Universe
  • *****
  • Posts: 2640
Re: FLAC compression levels question(s)
« Reply #16 on: August 19, 2019, 03:47:27 pm »

There is one good reason not to go with the above suggestions.  Some devices, like my 2019 Acura RDX, need the compression level set to 0 in order to read the file correctly.

Then your 2019 Acura RDX doesn't correctly support FLAC.

I tried to help a friend play files from a USB stick in his car last year; he was puzzled why he couldn't get it to work.  Turned out the car would recognize 128kbit MP3, and 320kbit MP3, but it wouldn't recognize 192kbit.

Some embedded devices just have broken support, like his car and yours.

That's not a reason to avoid FLAC compression, it just means that people with dysfunctional embedded devices need to convert their files as needed. 

Unlike some formats, FLAC doesn't need additional computing horsepower for higher levels of DEcompression.  Acura ought to fix that defect with a firmware update for their infotainment system.  Good luck.
Logged

sygnus21

  • Junior Woodchuck
  • **
  • Posts: 76
Re: FLAC compression levels question(s)
« Reply #17 on: August 19, 2019, 05:47:38 pm »

Then your 2019 Acura RDX doesn't correctly support FLAC.

I tried to help a friend play files from a USB stick in his car last year; he was puzzled why he couldn't get it to work.  Turned out the car would recognize 128kbit MP3, and 320kbit MP3, but it wouldn't recognize 192kbit.

Some embedded devices just have broken support, like his car and yours.

That's not a reason to avoid FLAC compression, it just means that people with dysfunctional embedded devices need to convert their files as needed. 

Unlike some formats, FLAC doesn't need additional computing horsepower for higher levels of DEcompression.  Acura ought to fix that defect with a firmware update for their infotainment system.  Good luck.

I'm not ready to assume it's an "Acura problem" especially in 2019. It sounds more like media file issue. I'm pretty sure if I went to an Acura dealer and loaded a CD with level 5 or 6 compression level flac files loaded onto it into one of their car's stereo's that CD would play. 

My two cents.
Logged

wer

  • Citizen of the Universe
  • *****
  • Posts: 2640
Re: FLAC compression levels question(s)
« Reply #18 on: August 19, 2019, 06:19:49 pm »

Try it.  It might very well work.  Because the CD files are processed differently than the USB files.  Car infotainment systems are often a hodgepodge of technologies glued together that have a variety of issues.

If you take a flac file to several different players and they all play it fine, but your car won't, what should you deduce from that?  Presumably you tried the files in other players to ensure the file is valid.

I'm not saying it's a problem unique to Acura.  Not at all.

Any device or player, that claims to support FLAC, but will only play level 0 files, does not support FLAC properly, by definition.

In another thread I related an issue where a device would play 128kbit and 320kbit MP3 files, but not 192kbit.  Nothing wrong with the files, that's just defective MP3 support, plain and simple.  Same sort of problem.
Logged

sygnus21

  • Junior Woodchuck
  • **
  • Posts: 76
Re: FLAC compression levels question(s)
« Reply #19 on: August 19, 2019, 11:42:08 pm »

Try it.  It might very well work.  Because the CD files are processed differently than the USB files.  Car infotainment systems are often a hodgepodge of technologies glued together that have a variety of issues.

If you take a flac file to several different players and they all play it fine, but your car won't, what should you deduce from that?  Presumably you tried the files in other players to ensure the file is valid.

I'm not saying it's a problem unique to Acura.  Not at all.

Any device or player, that claims to support FLAC, but will only play level 0 files, does not support FLAC properly, by definition.

In another thread I related an issue where a device would play 128kbit and 320kbit MP3 files, but not 192kbit.  Nothing wrong with the files, that's just defective MP3 support, plain and simple.  Same sort of problem.

Not trying to argue, and I'm going to move on, but I'm having a hard time following what you're putting down cause just about everything today supports flac so...  ?

Peace:)
Logged

Smilin_Jim

  • Recent member
  • *
  • Posts: 33
Re: FLAC compression levels question(s)
« Reply #20 on: August 20, 2019, 07:33:10 am »

Folks, I am not trying to throw Acura under the bus. But, if you want to listen to FLAC surround files in it, encode them at Level 0. That's all.

And if that is the case for the Acura, maybe it is the solution for other Atom and similar light CPUs that can't seem to recognize FLAC files when they say they do.
Logged

RoderickGI

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 8186
Re: FLAC compression levels question(s)
« Reply #21 on: August 20, 2019, 07:06:46 pm »

I just laugh and laugh reading the defence of the Acura's media system.

Auto manufacturers just need to tick the boxes. Does it have an infotainment/media/stereo system with Bluetooth connections and a touch screen? Yes. Tick.
Does it work well and as expected? Who cares? We ticked the box!
It is all just "Me too" marketing, even with the expensive brands.

Such systems often don't support Playlists, or only very specifc formats of Playlist. They often only support folder navigation to select what to play, and don't even support search or sorting of all media. Then they claim support for MP3, FLAC, WAV, etc., but that support is often very dodgy. Maybe the Acura does only support level 0 compression FLAC files, but if it does, that is just another failing of its media system.

I just laugh and laugh.  ;D ;D ;D
Logged
What specific version of MC you are running:MC27.0.27 @ Oct 27, 2020 and updating regularly Jim!                        MC Release Notes: https://wiki.jriver.com/index.php/Release_Notes
What OS(s) and Version you are running:     Windows 10 Pro 64bit Version 2004 (OS Build 19041.572).
The JRMark score of the PC with an issue:    JRMark (version 26.0.52 64 bit): 3419
Important relevant info about your environment:     
  Using the HTPC as a MC Server & a Workstation as a MC Client plus some DLNA clients.
  Running JRiver for Android, JRemote2, Gizmo, & MO 4Media on a Sony Xperia XZ Premium Android 9.
  Playing video out to a Sony 65" TV connected via HDMI, playing digital audio out via motherboard sound card, PCIe TV tuner

FenceFurniture

  • Galactic Citizen
  • ****
  • Posts: 420
Re: FLAC compression levels question(s)
« Reply #22 on: August 20, 2019, 08:51:03 pm »

For vehicle use I have found the most convenient way by far is to plug my Shanling M3s DAP into the after market Kenwood player via a 3.5mm jack. That way I can play the flac files with certainty and convenience. I use the DAP for FF, REW, Pause and VOL because I know where these analogue buttons are by feel.

The biggest problem with new tech decks in cars is that the idiot designers think we don't mind pulling over every time to make even the most minor adjustment - one simply CANNOT drive and search through a series of menus just to turn the bass down/up!

Bring back the bass and treble knobs I say!

Rant off....
Logged
Pages: [1]   Go Up