Skip to main content

Notice

Please note that most of the software linked on this forum is likely to be safe to use. If you are unsure, feel free to ask in the relevant topics, or send a private message to an administrator or moderator. To help curb the problems of false positives, or in the event that you do find actual malware, you can contribute through the article linked here.
Topic: WavPack quick verify feature using raw block checksums (Read 6592 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

WavPack quick verify feature using raw block checksums

One of the features introduced in WavPack 5.0 was appending checksums to the raw WavPack blocks. Each block already had checksums for the decoded data, but having only that meant that a full audio data decode was required to verify the file's integrity. I've now implemented a “quick verify” (-vv) option to wvunpack that uses only the block checksums and is, as expected, much faster than the full verify. In fact, its operation seems to be only limited by the read access speed of the source device!

I still recommend a “real” verify pass at some point to make sure that files are actually encoded correctly, preferably when the file is created (by adding -v to the encoder command-line) or afterward with wvunpack. However, once that is done, any subsequent corruption of WavPack files should be detected with the new quick version.

Of course this will not work with legacy files from before WavPack 5.0, but that case is detected by the quick verify command and it silently reverts to the regular version.

I am going to include this in version 5.4, but I'm not sure when that will be, so I thought I'd make it available in case anyone wanted to try it out first and possibly provide feedback. I am attaching a Windows executable and a Debian/Ubuntu/Mint Linux binary of the wvunpack program that include this feature.

Thanks!

edit: removed the binaries because this feature is now available in 5.4.0.

Re: WavPack quick verify feature using raw block checksums

Reply #1
pretty neat feature, thank you!
however ultimately I hope at some point this kind of integrity verification becomes just a standard feature of all stable filesystems in use and so will be a straightforward step to do for any file in any format...
maybe in 10 years or so
a fan of AutoEq + Meier Crossfeed

Re: WavPack quick verify feature using raw block checksums

Reply #2
Just noticed this with the release of 5.4.0, pretty handy, thanks a lot.
WavPack 5.7.0 -b384hx6cmv / qaac64 2.83 -V 100

Re: WavPack quick verify feature using raw block checksums

Reply #3
I with ubuntu to transform DSF into wavpack I use this command wavpack -hmv import-id3 * .dsf, do I need to change something?

Re: WavPack quick verify feature using raw block checksums

Reply #4
I with ubuntu to transform DSF into wavpack I use this command wavpack -hmv import-id3 * .dsf, do I need to change something?

It's a little difficult to tell with that font, but here's exactly what you want to type:
Code: [Select]
wavpack -hmv --import-id3 *.dsf

Note that long options (like "import-id3") need a double-dash prefix and there should be no space between the star and the dot dsf because then it's really two file specifications (one for all files and one for exactly ".dsf").

That should do it! Just be sure you're really in the folder with the files, you can list all of them with this:
Code: [Select]
ls -l *.dsf

And after the WavPack operation, you should be able to see the WavPack files with this:
Code: [Select]
ls -l *.wv



Re: WavPack quick verify feature using raw block checksums

Reply #5
I just wanted to know if the command I give is right, I think so because it works, I repeat what I do by writing the word space instead of space ....... I open the terminal in the folder where I have the dsf files to transform and then I type: wavpack space -hmv space import-id3 space * .dsf obviously the command import-id3 I use it if I want to copy the tags too otherwise I might not use it .....

Re: WavPack quick verify feature using raw block checksums

Reply #6
I just wanted to know if the command I give is right, I think so because it works, I repeat what I do by writing the word space instead of space ....... I open the terminal in the folder where I have the dsf files to transform and then I type: wavpack space -hmv space import-id3 space * .dsf obviously the command import-id3 I use it if I want to copy the tags too otherwise I might not use it .....
The only thing is the import-id3 must be preceded with -- (with no space) or WavPack will not know it's an option (it will think it's a file). Otherwise this is good.

Re: WavPack quick verify feature using raw block checksums

Reply #7
You say that the command must be like that? --import-id3, with a hyphen at the beginning? Because as I do (ie without the initial hyphen) the tags matter to me ......

Re: WavPack quick verify feature using raw block checksums

Reply #8
Right, two hyphens actually: space hyphen hyphen import-id3 space.

Re: WavPack quick verify feature using raw block checksums

Reply #9
I've now implemented a “quick verify” (-vv) option to wvunpack that uses only the block checksums and is, as expected, much faster than the full verify. In fact, its operation seems to be only limited by the read access speed of the source device!

Hi Bryant,
Thanks for all hard work and excellent audio codec.
Just one question:
is it possible to use quick verify (or standard verify option) on multiple folders (maybe through foobar2000)?

Re: WavPack quick verify feature using raw block checksums

Reply #10
Unfortunately there's no easy way to do that, at least for more than one folder.

I'm on Linux, so I can do something like:

Code: [Select]
wvunpack -vv ~/Music/*/*.wv ~/Music/*/*/*.wv

But that doesn't work on Windows and won't actually work on Linux either if there are too many files.

What would be ideal is a script that would recursively go into folders (depending on your platform), but that's beyond my abilities...  :)

Re: WavPack quick verify feature using raw block checksums

Reply #11
Well... then only way is manual check folder by folder on windows.
Thanks anyway. :)

Re: WavPack quick verify feature using raw block checksums

Reply #12
Frontah can be adapted to do a quick verify on Windows. The command-line parameters are in a text file within a zip archive. You can drag a folder and it will load all file extensions types known to it.

Limitations: no special characters in filenames, can't see the exact error message without scanning a long text file of stderr output (but at least there is that), can't select a particular format among all the files (can sort by tag type).

Re: WavPack quick verify feature using raw block checksums

Reply #13
Frontah can be adapted to do a quick verify on Windows. The command-line parameters are in a text file within a zip archive. You can drag a folder and it will load all file extensions types known to it.

Excellent. Thanks.