Skip to main content
Topic: FLAC vs TAK encoding results (Read 39279 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

FLAC vs TAK encoding results

Reply #25
So, maybe is time to test FLAC -8 and TAK -pMax, am I right?

I guess you worry a bit about usage of FLAC -0 and TAK -p0 which aren't very interesting settings - at least for FLAC. I too would have preferred a more usual FLAC setting like -5 or -8 (though I don't think speed will be significantly lower). With TAK a low setting (like -p2, but even -p 0 is a good choice) is appropriate IMO as compression ratio is still advantageous.
lame3995o -Q1.7
opus --bitrate 140

FLAC vs TAK encoding results

Reply #26
foobar 0.9.6.1 beta 2
decoding test - 10 passes
FLAC 1.2.1
-8 -A2 309x
-0      310x

I did wrong measurements


It's actually.
-8 -A2 309.5x
-0      377.0x

FLAC vs TAK encoding results

Reply #27
Thanks.
I guessed the results are close, but I didn't expect them to be so close.
lame3995o -Q1.7
opus --bitrate 140

FLAC vs TAK encoding results

Reply #28
I did actually get quite a variation with my machine (Athlon XP 2400+, 1GB RAM).  I'm going to run a test again on just a few files to double check, but these are the figures I have thus far:

Code: [Select]
Settings:
  Buffer entire file into memory: yes
  High priority: yes
  Passes: 10

File      FLAC 1.2.1      TAK 1.1.0
          -0      -8      -p0     -p4
Code: [Select]
00.wav    277x    206x    191x    132x
01.wav    289x    238x    209x    136x
02.wav    291x    222x    206x    130x
03.wav    273x    211x    191x    129x
04.wav    257x    199x    187x    103x
05.wav    278x    216x    199x    124x
06.wav    275x    211x    188x    142x
07.wav    277x    216x    196x    129x
08.wav    271x    214x    192x    138x
09.wav    281x    218x    200x    131x
10.wav    278x    208x    191x    146x
11.wav    285x    217x    200x    128x
12.wav    275x    219x    201x    125x
13.wav    275x    209x    192x    119x
14.wav    277x    209x    197x    125x
15.wav    275x    215x    200x    128x
16.wav    273x    233x    191x    140x
17.wav    281x    216x    200x    121x
18.wav    265x    212x    192x    108x
19.wav    278x    211x    200x    122x
20.wav    280x    219x    189x    134x
21.wav    292x    223x    206x    118x
22.wav    277x    209x    192x    125x
23.wav    280x    213x    191x    133x
24.wav    276x    209x    197x    124x
25.wav    277x    208x    199x    119x
26.wav    292x    230x    205x    126x
27.wav    281x    217x    201x    153x
28.wav    275x    205x    190x    149x
29.wav    288x    221x    198x    133x
30.wav    276x    221x    198x    130x
31.wav    285x    211x    198x    134x
32.wav    280x    207x    192x    142x
33.wav    278x    211x    192x    147x
34.wav    287x    216x    202x    121x
35.wav    281x    209x    196x    139x
36.wav    274x    209x    191x    122x
37.wav    275x    201x    186x    135x
38.wav    287x    222x    203x    133x
39.wav    253x    195x    183x    106x
40.wav    279x    211x    193x    137x
41.wav    280x    215x    191x    124x
42.wav    275x    206x    190x    137x
43.wav    280x    218x    198x    137x
44.wav    282x    225x    200x    148x
45.wav    260x    199x    186x    121x
46.wav    272x    214x    199x    112x
47.wav    260x    201x    187x    118x
48.wav    252x    193x    182x    116x
49.wav    255x    195x    183x    121x
Code: [Select]
Average   276x    213x    195x    129x
[!--sizeo:1--][span style=\"font-size:8pt;line-height:100%\"][!--/sizeo--]
(Late) Edit: spelling[/size]
I'm on a horse.

FLAC vs TAK encoding results

Reply #29
Thanks for your results.
I don't care about ultra-precision of results, the rather rough impression is enough.
As from that you do have significantly slower results using FLAC -8 compared to -0 (while 'slower' still means 'very fast').
It's still faster than TAK -p0, but not by much.
Considering that TAK -p1 should yield pretty much the same decoding speed as -p0 TAK -p1 may be the best TAK solution when focussing on decompression speed while still taking care of good compression ratio. TAK -p2's compression speed is not expected to be much lower, so maybe TAK -p 2 is the best solution when focussing the same on both decompression speed and compression ratio. All a matter of taste of course.
So FLAC is still the decompression speed king, but has a strong competitor.
lame3995o -Q1.7
opus --bitrate 140

FLAC vs TAK encoding results

Reply #30
I don't care about ultra-precision of results, the rather rough impression is enough.
I wasn't after more precision, only checking that they weren't wildly off.  I can confirm that a smaller test yielded very similar results.

I personally wonder whether the fact that the TAK foobar decoding component has to use an external library makes some difference.  I have no idea about such matters though.
I'm on a horse.

FLAC vs TAK encoding results

Reply #31
I tested on my side.
foobar2000 0.9.6.1b2
Intel C2Duo E6300 (1.83 GHz) // 1 GB RAM)
I set foobar2000's test speed to 10 pass and I took the fastest one to fill the table.

I also choose four files from my own music library having four different level of complexity: the first one reaches 250 kbps; the second 500 kbps; the third 750 kbps and the last one 1000 kbps (all originally encoded with flac -5). Why? Simply because I noticed that decoding speed changes a lot depending on the file and its bitrate.

Code: [Select]
          | FLAC -0 | FLAC -8 |  TAK -p0 |  TAK -p4
----------|---------|---------|----------|-----------
250 kbps  |  x528   |  x488   |  x284    |  x192
500 kbps  |  x444   |  x406   |  x282    |  x165
750 kbps  |  x434   |  x370   |  x259    |  x151
1000 kbps |  x422   |  x325   |  x243    |  x150

If I compare this table to the past test I performed one year ago on the same computer and with a ~1000 kbps file:
- flac decoding speed is similar (x312 vs x325)
- TAK decoding speed on fb2k significantly increased (x181 vs x243)

foobar2000 exact values:
Code: [Select]
File: C:\flac\test\test\250kbps FLAC-0.flac
  Opening time: 0:00.001 min, 0:00.018 max, 0:00.002 average
  Decoding time: 0:00.349 min, 0:00.351 max, 0:00.350 average
  Speed (x realtime): 524.197 min, 528.377 max, 526.773 average
File: C:\flac\test\test\250kbps FLAC-8.flac
  Opening time: 0:00.001 min, 0:00.017 max, 0:00.002 average
  Decoding time: 0:00.377 min, 0:00.385 max, 0:00.380 average
  Speed (x realtime): 478.679 min, 488.796 max, 484.094 average
File: C:\flac\test\test\250kbps TAK p0.tak
  Opening time: 0:00.000 min, 0:00.016 max, 0:00.002 average
  Decoding time: 0:00.646 min, 0:00.649 max, 0:00.648 average
  Speed (x realtime): 283.568 min, 284.903 max, 284.317 average
File: C:\flac\test\test\250kbps TAK p4.tak
  Opening time: 0:00.001 min, 0:00.015 max, 0:00.002 average
  Decoding time: 0:00.958 min, 0:00.960 max, 0:00.959 average
  Speed (x realtime): 191.794 min, 192.300 max, 192.107 average

************************************************************************

File: C:\flac\test\test\500kbps FLAC-0.flac
  Opening time: 0:00.001 min, 0:00.026 max, 0:00.003 average
  Decoding time: 0:00.331 min, 0:00.335 max, 0:00.332 average
  Speed (x realtime): 440.209 min, 444.940 max, 443.115 average
File: C:\flac\test\test\500kbps FLAC-8.flac
  Opening time: 0:00.001 min, 0:00.026 max, 0:00.003 average
  Decoding time: 0:00.362 min, 0:00.366 max, 0:00.364 average
  Speed (x realtime): 402.274 min, 406.770 max, 404.358 average
File: C:\flac\test\test\500kbps TAK p0.tak
  Opening time: 0:00.000 min, 0:00.025 max, 0:00.003 average
  Decoding time: 0:00.521 min, 0:00.524 max, 0:00.522 average
  Speed (x realtime): 280.986 min, 282.703 max, 282.039 average
File: C:\flac\test\test\500kbps TAK p4.tak
  Opening time: 0:00.001 min, 0:00.025 max, 0:00.004 average
  Decoding time: 0:00.888 min, 0:00.891 max, 0:00.889 average
  Speed (x realtime): 165.397 min, 165.853 max, 165.623 average

************************************************************************

File: C:\flac\test\test\750kbps FLAC-0.flac
  Opening time: 0:00.001 min, 0:00.063 max, 0:00.007 average
  Decoding time: 0:00.575 min, 0:00.577 max, 0:00.576 average
  Speed (x realtime): 432.590 min, 434.455 max, 433.582 average
File: C:\flac\test\test\750kbps FLAC-8.flac
  Opening time: 0:00.001 min, 0:00.063 max, 0:00.007 average
  Decoding time: 0:00.675 min, 0:00.678 max, 0:00.677 average
  Speed (x realtime): 368.238 min, 370.070 max, 369.082 average
File: C:\flac\test\test\750kbps TAK p0.tak
  Opening time: 0:00.000 min, 0:00.062 max, 0:00.007 average
  Decoding time: 0:00.963 min, 0:00.967 max, 0:00.965 average
  Speed (x realtime): 258.226 min, 259.176 max, 258.667 average
File: C:\flac\test\test\750kbps TAK p4.tak
  Opening time: 0:00.001 min, 0:00.061 max, 0:00.007 average
  Decoding time: 0:01.651 min, 0:01.655 max, 0:01.653 average
  Speed (x realtime): 150.874 min, 151.224 max, 151.091 average

************************************************************************

File: C:\flac\test\test\1000kbps FLAC-0.flac
  Opening time: 0:00.001 min, 0:00.059 max, 0:00.006 average
  Decoding time: 0:00.412 min, 0:00.416 max, 0:00.413 average
  Speed (x realtime): 418.770 min, 422.565 max, 421.343 average
File: C:\flac\test\test\1000kbps FLAC-8.flac
  Opening time: 0:00.001 min, 0:00.059 max, 0:00.006 average
  Decoding time: 0:00.535 min, 0:00.537 max, 0:00.535 average
  Speed (x realtime): 323.822 min, 325.526 max, 325.008 average
File: C:\flac\test\test\1000kbps TAK p0.tak
  Opening time: 0:00.000 min, 0:00.058 max, 0:00.006 average
  Decoding time: 0:00.714 min, 0:00.717 max, 0:00.715 average
  Speed (x realtime): 242.555 min, 243.622 max, 243.214 average
File: C:\flac\test\test\1000kbps TAK p4.tak
  Opening time: 0:00.000 min, 0:00.055 max, 0:00.006 average
  Decoding time: 0:01.155 min, 0:01.159 max, 0:01.157 average
  Speed (x realtime): 150.079 min, 150.697 max, 150.406 average

[!--sizeo:1--][span style=\"font-size:8pt;line-height:100%\"][!--/sizeo--]EDIT: changed CPU name from E4300 to E6300[/size]

FLAC vs TAK encoding results

Reply #32
I made  wrong measurements in previous post. The correct results are:
Intel E2160 (1.8 GHz x2) 2 GB DDR2 667 Mhz RAM. OS Windows XP SP3
foobar 0.9.6.1
decoding test - 10 passes
FLAC 1.2.1 -  13 songs from Steve Vai - The Ultra Zone
-8 -A2 309.5x
-0 377.0x

For real usage on PC such high decoding speed doesn't bring real benefit. Let's see two cases
1. Real playback
2. Encoding

1. Real playback:
FLAC -8 -A2 309.5x decoded at 1 core - 0.323% of CPU usage (1 core) for real time playback
FLAC -0 377.0x  decoded  at 1 core    - 0.265% of CPU usage (1 core) for real time playback

Nobody will notice this difference, less than 1% (actually it's even less than 0.1% of difference in CPU usage). In fact pure FLAC decoding can be masked with slower decoding features like: dithering, 24 bits decoding, equalizer and etc.


2. Encoding. LAME 3.98.2 -V0
WAV -> MP3 = 41x
FLAC -8 -> MP3 = 41x (MP3 encoding) + 309.5x (FLAC decoding) = 36.20x
FLAC -0 -> MP3 = 41x (MP3 encoding) + 377.0x (FLAC decoding) = 36.98x


I did it wrong again. Calculations were done with doble speed (real speed) for encoding mp3 as it's dual core. But erroneously the speed of decoding for flac was not doubled.
FLAC -8 -A2 309.5x2 =619 
FLAC -0  377x2 = 754

So
FLAC -8 -> MP3 = 41x (MP3 encoding) + 619x (FLAC decoding) = 38.45x
FLAC -0 -> MP3 = 41x (MP3 encoding) + 754x (FLAC decoding) = 38.89x
It's pretty the same numbers what I get for real encodes.


So encoding from FLAC -8 is only 2.15% 1.12% slower than from FLAC -0.


My personal conclusion:  There is no benefit for PC usage from high speed decoding of FLAC -0.
Exception can be DAP and other kinds of audio/video hardware.

FLAC vs TAK encoding results

Reply #33
There is no benefit for PC usage from high speed decoding of FLAC -0.

Any CPU cycle that is spared from FLAC decoding is useful when transcoding, whether you use a piping method or decode FLAC to WAV files first. Any spared CPU cycle can then be used to the encoding processes (provided you transcode multiple files in parallel).

FLAC vs TAK encoding results

Reply #34
So you would use FLAC -0 instead of -8 because encode speed to MP3 would arise +1.12% and CPU usage would decrease from 0.323% to 0.265% during playback, right? While your FLAC -0 files will be 8% bigger than FLAC-0?

FLAC vs TAK encoding results

Reply #35
Don't ask me, I wouldn't run FLAC below -8.

 
SimplePortal 1.0.0 RC1 © 2008-2019