IPB

Welcome Guest ( Log In | Register )

2 Pages V   1 2 >  
Reply to this topicStart new topic
WMA Lossless truncates last few samples of some files.
Costas
post Dec 17 2007, 14:51
Post #1





Group: Members
Posts: 7
Joined: 7-September 07
Member No.: 46870



WMA Lossless is obviously supposed to fully preserve the source data, however
it appears that sometimes the last few samples of a file will be thrown away.

(Note: For those interested in recreating the problem I have uploaded a "problematic" wav file here: http://rapidshare.com/files/REMOVED* )

If I convert the above file to WMAL using dBpoweramp and Windows Media Audio 9.2 Lossless codec I get (when After Encoding Verify Audio option is checked):

Error converting to Windows Media Audio 10, '06 - Melibea - Boheme.wav' to '06 - Melibea - Boheme.wma'
Error audio file failed verification '06 - Melibea - Boheme.wma'.

If I convert the above file to WMAL using Windows Media Encoder, I get no messages but then if I bit-compare the results using foobar2000 I get:

Comparing:
"06 - Melibea - Boheme.wav"
"06 - Melibea - Boheme.wma"
Comparing failed (length mismatch : 5:35.440000 vs 5:35.439819, 14792904 vs 14792896 samples).

Can anyone help?

Moderation: Removed sample. I haven't downloaded it but from the size of it it is longer than the 30 sec we allow here.
Go to the top of the page
+Quote Post
pdq
post Dec 17 2007, 15:03
Post #2





Group: Members
Posts: 3394
Joined: 1-September 05
From: SE Pennsylvania
Member No.: 24233



I would guess that the length of the file doesn't match the length specified in the header, so when the file is converted, only the actual data are converted, leaving a file whose length doesn't match the original header. What was used to create the original wav file?

Try decoding the lossless file to wav and compare that to the original file, but compare the data only, not the headers.
Go to the top of the page
+Quote Post
spoon
post Dec 17 2007, 16:18
Post #3


dBpowerAMP developer


Group: Developer (Donating)
Posts: 2745
Joined: 24-March 02
Member No.: 1615



It is not a header issue, I have validated this issue.


--------------------
Spoon http://www.dbpoweramp.com
Go to the top of the page
+Quote Post
kjoonlee
post Dec 17 2007, 16:32
Post #4





Group: Members
Posts: 2526
Joined: 25-July 02
From: South Korea
Member No.: 2782



I think truncation with WMA "Lossless" has been reported before, at least at Hydrogenaudio.


--------------------
http://blacksun.ivyro.net/vorbis/vorbisfaq.htm
Go to the top of the page
+Quote Post
Flepp
post Dec 17 2007, 17:16
Post #5





Group: Members
Posts: 5
Joined: 4-December 07
Member No.: 49258



Hi

I did the test with WMAL and could not find any issue.

I compared the CRC's with Dbpoweramp and found no difference.
When converting back to wav i found a small difference at the end of the file when doing a binary compare with fc/b command.
But difference was in the Meta part of the file. I removed all Metadata from both files and fc/b gave me no difference.

So your problem might have something to do with the foobar compare module.


Flepp
Go to the top of the page
+Quote Post
kjoonlee
post Dec 17 2007, 17:57
Post #6





Group: Members
Posts: 2526
Joined: 25-July 02
From: South Korea
Member No.: 2782



I can't find any more posts at the moment, but problems with truncation have been reported with other programs.

http://www.hydrogenaudio.org/forums/index....showtopic=54490


--------------------
http://blacksun.ivyro.net/vorbis/vorbisfaq.htm
Go to the top of the page
+Quote Post
spoon
post Dec 17 2007, 18:56
Post #7


dBpowerAMP developer


Group: Developer (Donating)
Posts: 2745
Joined: 24-March 02
Member No.: 1615



QUOTE (Flepp @ Dec 17 2007, 16:16) *
Hi

I did the test with WMAL and could not find any issue.

I compared the CRC's with Dbpoweramp and found no difference.
When converting back to wav i found a small difference at the end of the file when doing a binary compare with fc/b command.
But difference was in the Meta part of the file. I removed all Metadata from both files and fc/b gave me no difference.

So your problem might have something to do with the foobar compare module.


Flepp


The loss of samples seems quite rare, I tried 2000 files and none did it, but I have a specific file which does.


--------------------
Spoon http://www.dbpoweramp.com
Go to the top of the page
+Quote Post
ozmosis82
post Dec 17 2007, 21:31
Post #8





Group: Members
Posts: 204
Joined: 26-March 06
From: Edmonton, Canada
Member No.: 28860



I experienced this issue quite some time ago when I first decided to archive my CD collection losslessly. I initially chose WMA Lossless (I wasn't privy to other lossless formats yet) and encoded a number of albums. A year or so later (after much education on the subject of codecs) I decided to move to WavPack and noticed that a number of my gapless albums didn't transition as they were supposed to. There was an audible pop between tracks. I re-ripped the CD in question to see if it had always been there, and found that the transition was seamless.

(It was at this point that I became incredibly paranoid about lossless archiving, I might add.)

Since then, I've been incredibly careful and selective about how I back up my music collection. I use FLAC now and haven't looked back since. Having to go through and re-rip/encode all of those CDs was NOT something I ever want to have to do again... especially since my CD collection has only grown exponentially since then.

[EDIT: Grammar]

This post has been edited by ozmosis82: Dec 17 2007, 21:36
Go to the top of the page
+Quote Post
maiki
post Jan 8 2008, 01:32
Post #9





Group: Members
Posts: 70
Joined: 7-January 06
Member No.: 26940



QUOTE (Costas @ Dec 17 2007, 14:51) *
WMA Lossless is obviously supposed to fully preserve the source data, however
it appears that sometimes the last few samples of a file will be thrown away.


OK, I have downloaded and tested your WAVE file and the conclusion is:

your wave file is corrupted

It contains some "metadata" that should NOT be in there.

There is absolutely nothing wrong with WMA lossless, there is absolutely nothing worng with FLAC. Both encoders encode your corrupt wave file but when I decode them back, I get a different wave than your original.

This is what FLAC encoder reports:

06.wav: 100% complete, ratio=0,67806.wav: WARNING: skipping unknown sub-chunk 'LIST' (use --keep-foreign-metadata to keep)
06.wav: wrote 40001107 bytes, ratio=0,676


comparison:

the original wave file you provided: 59 171 758 bytes
encoded into WMA lossless: 39 380 187 bytes
decoded back from WMA: 59 171 628 bytes

the original wave file you provided: 59 171 758 bytes
encoded into FLAC: 40 001 107 bytes
decoded back from FLAC: 59 171 660 bytes

Since I have tested faithfullness of lossless encoders before and it did not give me any problems with any of my CD rips regarding these issues, I highly suspect you are using a buggy software (or/and) settings to rip CDs.

note: I have just tested one of my CD rips and it gives me identical files after re-decoding using WMA lossless...


conclusion #2: WMA Lossless wins the round, your wave file takes the loss

This post has been edited by maiki: Jan 8 2008, 02:53
Go to the top of the page
+Quote Post
spoon
post Jan 8 2008, 10:50
Post #10


dBpowerAMP developer


Group: Developer (Donating)
Posts: 2745
Joined: 24-March 02
Member No.: 1615



>OK, I have downloaded and tested your WAVE file and the conclusion is:
>your wave file is corrupted
>It contains some "metadata" that should NOT be in there.

Wrong - LIST chunks are valid in Wave files, Microsoft created wave files here is their take:

http://msdn2.microsoft.com/en-us/library/ms713231.aspx
---------

I have tested the wave file above it does encode to a wma file which is missing samples. When comparing audio files, Never compare just file sizes, Never run a CRC or md5 on the whole file, run it on the uncompressed audio data inside. Our [audio crc] calculation codec says about this file:

CRC32 Filename

E28F11B9 Z:\06 - Melibea - Boheme.wav
24318D58 Z:\06 - Melibea - Boheme.wma


========================================
Audio Details for: Z:\06 - Melibea - Boheme.wav

Sample Count: 14,792,904

========================================
Audio Details for: Z:\06 - Melibea - Boheme.wma

Sample Count: 14,792,859

as you can see there are samples missing from the WMA lossless file, these samples were encoded to WMA lossless, they do not come out though.

>Since I have tested faithfullness of lossless encoders before and it did
>not give me any problems with any of my CD rips regarding these
>issues, I highly suspect you are using a buggy software (or/and)
>settings to rip CDs.

By only testing say 1000 files you might never find the bug, when millions of files are being used and compared then bugs can appear.

This post has been edited by spoon: Jan 8 2008, 10:55


--------------------
Spoon http://www.dbpoweramp.com
Go to the top of the page
+Quote Post
Jillian
post Jan 8 2008, 12:01
Post #11





Group: Members
Posts: 66
Joined: 29-April 06
From: Thailand
Member No.: 30166



So WMA Lossless is lossy?
Go to the top of the page
+Quote Post
maiki
post Jan 8 2008, 12:52
Post #12





Group: Members
Posts: 70
Joined: 7-January 06
Member No.: 26940



But even if we admit that the file is not corrupted, still, FLAC also fails to encode it properly. So why do you blame WMA lossless for that? Anyway, that file is strange and has been probably separated from some cue sheet.
Go to the top of the page
+Quote Post
Cosmo
post Jan 8 2008, 13:57
Post #13





Group: Members
Posts: 913
Joined: 10-January 05
Member No.: 18979



101 Error

This post has been edited by Cosmo: Mar 11 2008, 13:58
Go to the top of the page
+Quote Post
maiki
post Jan 8 2008, 15:48
Post #14





Group: Members
Posts: 70
Joined: 7-January 06
Member No.: 26940



So I think somebody competent should post this issue to Microsoft then.
Go to the top of the page
+Quote Post
spoon
post Jan 8 2008, 16:10
Post #15


dBpowerAMP developer


Group: Developer (Donating)
Posts: 2745
Joined: 24-March 02
Member No.: 1615



They were notified, on their own forums...back in the day I used to have the contact details of the head of WMA division, no longer though.


--------------------
Spoon http://www.dbpoweramp.com
Go to the top of the page
+Quote Post
TechVsLife
post Jan 1 2009, 20:37
Post #16





Group: Members
Posts: 195
Joined: 29-May 07
Member No.: 43837



Can someone confirm that *FLAC* also fails to encode it properly? Thanks.

QUOTE (maiki @ Jan 8 2008, 06:52) *
But even if we admit that the file is not corrupted, still, FLAC also fails to encode it properly. So why do you blame WMA lossless for that? Anyway, that file is strange and has been probably separated from some cue sheet.
Go to the top of the page
+Quote Post
greynol
post Jan 1 2009, 20:53
Post #17





Group: Super Moderator
Posts: 10000
Joined: 1-April 04
From: San Francisco
Member No.: 13167



Upon closer examination you can see that maiki doesn't know what he's talking about.


--------------------
I should publish a list of forum idiots.
Go to the top of the page
+Quote Post
TechVsLife
post Jan 2 2009, 04:40
Post #18





Group: Members
Posts: 195
Joined: 29-May 07
Member No.: 43837



initially read the thread as concluding that the problem was WMAL-specific, but I wasn't sure on a re-reading. --so the source file did not cause any problems with FLAC? And does anyone know if this problem still arises with the most recent WMAL encoder/decoders or with the wma SDK? Thanks.

Moderation: Removed useless quotation of previous post.

This post has been edited by greynol: Jan 2 2009, 19:30
Go to the top of the page
+Quote Post
greynol
post Jan 2 2009, 05:07
Post #19





Group: Super Moderator
Posts: 10000
Joined: 1-April 04
From: San Francisco
Member No.: 13167



QUOTE (TechVsLife @ Jan 1 2009, 19:40) *
so the source file did not cause any problems with FLAC?
The file simply had some metadata that flac discarded (yes, I looked at it before the link was removed because it violated the TOS). If the "--keep-foreign-metadata" switch had been used then it would have been kept. This really should be self-evident from reading maiki's post.

QUOTE (TechVsLife @ Jan 1 2009, 19:40) *
And does anyone know if this problem still arises with the most recent WMAL encoder/decoders or with the wma SDK?
I don't know and I'm not sure that it was ever a problem with the codec as it was implemented in WMP.

Please don't resurrect three threads asking the same basic question. It is also a violation of the TOS, number 6 to be specific.


--------------------
I should publish a list of forum idiots.
Go to the top of the page
+Quote Post
TechVsLife
post Jan 2 2009, 06:42
Post #20





Group: Members
Posts: 195
Joined: 29-May 07
Member No.: 43837



Thanks, that hadn't been clear to me from the thread (that he failed to use the right switch in testing flac). My apologies on the Tos Six violation.
Go to the top of the page
+Quote Post
spoon
post Jan 2 2009, 10:52
Post #21


dBpowerAMP developer


Group: Developer (Donating)
Posts: 2745
Joined: 24-March 02
Member No.: 1615



The problem was / is (still on going): the files encode correctly but will not decode using the latest WMA SDK, WMP does not use their own SDK so is unaffected.


--------------------
Spoon http://www.dbpoweramp.com
Go to the top of the page
+Quote Post
TechVsLife
post Jan 2 2009, 15:42
Post #22





Group: Members
Posts: 195
Joined: 29-May 07
Member No.: 43837



Thanks, good to know my files are ok. I'll have to see if the decoding issue still exists when a new SDK is released for wmp12/windows7.

Moderation: Removed unnecessary quote of previous post. Also, it is customary to put the quote above your reply. Please try to do this in the future.

This post has been edited by greynol: Jan 2 2009, 19:28
Go to the top of the page
+Quote Post
greynol
post Jan 2 2009, 19:27
Post #23





Group: Super Moderator
Posts: 10000
Joined: 1-April 04
From: San Francisco
Member No.: 13167



Isn't the SDK separate entity from WMP and Windows, or am I missing something?

This post has been edited by greynol: Jan 2 2009, 19:29


--------------------
I should publish a list of forum idiots.
Go to the top of the page
+Quote Post
spoon
post Jan 2 2009, 21:55
Post #24


dBpowerAMP developer


Group: Developer (Donating)
Posts: 2745
Joined: 24-March 02
Member No.: 1615



I think you have seen the last WMP 11 SDK, the reason being is it has been depreciated, I think MS now expect WMA handling to use the sound API in Vista and newer to read / write WMA...interesting as even XP has been dropped, not that I think there will be much changes now to WMA.

This post has been edited by spoon: Jan 2 2009, 21:57


--------------------
Spoon http://www.dbpoweramp.com
Go to the top of the page
+Quote Post
TechVsLife
post Jan 3 2009, 00:13
Post #25





Group: Members
Posts: 195
Joined: 29-May 07
Member No.: 43837



QUOTE
Isn't the SDK separate entity from WMP and Windows, or am I missing something?

Separate, but I believe usually released about the same time.
QUOTE
Removed unnecessary quote of previous post. Also, it is customary to put the quote above your reply. Please try to do this in the future.

I'll cut back on quoting. As far as "top" posting, I actually thought that was more widely used--it's the default in gmail and outlook:
http://en.wikipedia.org/wiki/Posting_style
On the whole I find it easier to read when there IS top posting--if the message is part of a thread and one isn't cutting up the original post with interspersed replies (as here). However, when in Rome etc. Let me know if I'm in Rome.

This post has been edited by TechVsLife: Jan 3 2009, 00:22
Go to the top of the page
+Quote Post

2 Pages V   1 2 >
Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



RSS Lo-Fi Version Time is now: 1st September 2014 - 19:51