IPB

Welcome Guest ( Log In | Register )

 
Reply to this topicStart new topic
FLAC encode partial sample error on verify, what does this mean?
pokepoke
post Feb 27 2006, 00:48
Post #1





Group: Members
Posts: 12
Joined: 18-June 04
Member No.: 14751



Hi all,

Got some SHN files full of SBEs recently, did the standard decode to WAV, encode to FLAC cleanup, and during the verify on some of the files, got the following error:

ERROR: got partial sample

There's no discernible error in FLAC playback, but I was wondering what this might mean?

I'm using FLAC Front End 1.7.1 etree edition and FLAC 1.1.2a for the encoding.

Thanks in advance...

EDIT: the files in question still show sector boundary errors. And I forgot to say I use the align on sector boundaries option, at level 8.

This post has been edited by pokepoke: Feb 27 2006, 01:21
Go to the top of the page
+Quote Post
jcoalson
post Feb 27 2006, 04:23
Post #2


FLAC Developer


Group: Developer
Posts: 1526
Joined: 27-February 02
Member No.: 1408



it means the WAV is truncated, and not even at a sample boundary. e.g. if it's 16-bit stereo data, the subchunk's length is not a multiple of 4.

could be that the SHN files are truncated too. shorten doesn't have much error detection so it's hard to say.

Josh
Go to the top of the page
+Quote Post
Cartman_Sr
post Feb 27 2006, 04:47
Post #3





Group: Members
Posts: 112
Joined: 9-February 06
From: Edmonton, Alberta
Member No.: 27644



What does "align on sector boundaries" do?
Go to the top of the page
+Quote Post
jcoalson
post Feb 27 2006, 05:18
Post #4


FLAC Developer


Group: Developer
Posts: 1526
Joined: 27-February 02
Member No.: 1408



http://flac.sourceforge.net/documentation....ns_sector_align
Go to the top of the page
+Quote Post
Cartman_Sr
post Feb 27 2006, 05:47
Post #5





Group: Members
Posts: 112
Joined: 9-February 06
From: Edmonton, Alberta
Member No.: 27644



Oh. I'm a bonehead for not reading that part. Anyways, I really like the FLAC format. I'm still learning how to use everything. Thanks Josh.
Go to the top of the page
+Quote Post
pokepoke
post Feb 27 2006, 18:43
Post #6





Group: Members
Posts: 12
Joined: 18-June 04
Member No.: 14751



QUOTE (jcoalson @ Feb 26 2006, 10:23 PM)
it means the WAV is truncated, and not even at a sample boundary.  e.g. if it's 16-bit stereo data, the subchunk's length is not a multiple of 4.

could be that the SHN files are truncated too.  shorten doesn't have much error detection so it's hard to say.

Josh
*


Wow, from Mr. FLAC himself! I am flattered by your attention, sir, and a big fan of your work.

The SHN files were indeed dubiously produced. I was able to encode, decode, and reencode successfully, so I guess this means that the FLAC files dropped the bad subchunks? Interesting that it seems to be an either-or, to align on the boundaries or to drop the bad subchunk. Or am I misreading that?

Thanks very much for the reply. (I couldn't find much on this error in this forum, or even on the internets.)
Go to the top of the page
+Quote Post
jcoalson
post Feb 27 2006, 20:43
Post #7


FLAC Developer


Group: Developer
Posts: 1526
Joined: 27-February 02
Member No.: 1408



thanks.

hmm... there is supposed to be only 1 'data' subchunk in a WAV file, which contains all the audio. assuming that, then upon hitting an unaligned (i.e. length mod 4 != 0) subchunk, flac should error out and not produce a file.

if it gets a 'data' subchunk that ends earlier than the WAV header says it should, flac will give a different warning ("WARNING: unexpected EOF; expected %u samples, got %u samples") and keep the flac output.

so I'm not sure exactly what's going on; if there is a place you can host one of the bad SHN files I can take a look.

Josh
Go to the top of the page
+Quote Post
pokepoke
post Feb 27 2006, 23:20
Post #8





Group: Members
Posts: 12
Joined: 18-June 04
Member No.: 14751



Well, in each case it got to 100% of the FLAC creation, then gave the message. And the decoding itself got rid of the SHNs. Let me see if the guy who torrented them originally can help out.

One more thing--shntool found problems on the original files that correspond to the message "audio data is not block-[a]ligned", not on exactly the same tracks that caused FLAC problems, but perhaps significant?

This post has been edited by pokepoke: Feb 27 2006, 23:29
Go to the top of the page
+Quote Post
pokepoke
post Mar 1 2006, 16:55
Post #9





Group: Members
Posts: 12
Joined: 18-June 04
Member No.: 14751



PM sent with link to test file. Looking forward to your reply.
Go to the top of the page
+Quote Post
jcoalson
post Mar 1 2006, 19:47
Post #10


FLAC Developer


Group: Developer
Posts: 1526
Joined: 27-February 02
Member No.: 1408



answer: the original SHN was created from a truncated WAV file. the reason:

1. "shorten -x test.shn 1.wav" yields no errors and a WAV file with the right headers but truncated data subchunk

2. if I chop the last byte off test.shn and try to decode than, shorten complains about premature EOF

3. "shorten 1.wav 1.shn" causes no error and 1.shn is identical to test.shn

Josh
Go to the top of the page
+Quote Post
pokepoke
post Mar 1 2006, 21:57
Post #11





Group: Members
Posts: 12
Joined: 18-June 04
Member No.: 14751



QUOTE (jcoalson @ Mar 1 2006, 01:47 PM)
answer: the original SHN was created from a truncated WAV file.
*


Can you explain to me how a truncated WAV file gets truncated? Or point me somewhere where I can learn about it? The file's creator is curious to know where he might have gone wrong.

I really appreciate your help.
Go to the top of the page
+Quote Post
jcoalson
post Mar 2 2006, 19:21
Post #12


FLAC Developer


Group: Developer
Posts: 1526
Joined: 27-February 02
Member No.: 1408



sorry, I don't really know, it's never happened to me.
Go to the top of the page
+Quote Post
kjoonlee
post Mar 2 2006, 19:47
Post #13





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



There can be many reasons, the first of which comes to mind is "incomplete download."


--------------------
http://blacksun.ivyro.net/vorbis/vorbisfaq.htm
Go to the top of the page
+Quote Post

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: 23rd July 2014 - 19:03