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: ALAC PCM compare on OS X? (Read 4583 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

ALAC PCM compare on OS X?

I'm in the process of converting my flac to alac and need to do a PCM compare between them on a mac.

I've scoured a number of sources and the closest I've come is xAct, while it can compare flac to flac and a few others, it cannot do alac PCM checksums or compares. Besides that, I'd *prefer* to use in shell script.

Is my google-fu just weak?

Re: ALAC PCM compare on OS X?

Reply #1
Maybe you can convert both to WAV and compare the two WAVs?  Or, convert back to FLAC and compare FLAC-to-FLAC?

But, what's the problem?   You don't trust FLAC or ALAC to be lossless?   Or you don't trust your computer?


Re: ALAC PCM compare on OS X?

Reply #2
There is -f md5 in ffmpeg.

quick example:
Code: [Select]
orig=$(ffmpeg -i some.wav -loglevel warning -f md5 -)
echo "$orig"
flac=$(ffmpeg -i some.flac -loglevel warning -f md5 -)
echo "$flac"
[ "$orig" == "$flac" ] && echo "fine" || echo "nope"
PANIC: CPU 1: Cache Error (unrecoverable - dcache data) Eframe = 0x90000000208cf3b8
NOTICE - cpu 0 didn't dump TLB, may be hung

Re: ALAC PCM compare on OS X?

Reply #3
p.s. or a oneliner:
Code: [Select]
diff <(ffmpeg -i some.wav -loglevel warning -f md5 -) <(ffmpeg -i some.flac -loglevel warning -f md5 -) && echo "fine" || echo "nope"
(probably good idea to toss "2>/dev/null" or two here and there)
PANIC: CPU 1: Cache Error (unrecoverable - dcache data) Eframe = 0x90000000208cf3b8
NOTICE - cpu 0 didn't dump TLB, may be hung

Re: ALAC PCM compare on OS X?

Reply #4
I don't trust my NAS... and I'm going to address that with ZFS filer in Jan 2017 (long irrelevant story).

I've actually done a ton of conversion, then using a windows VM running foobar with bit compare found diffs.

So I do my conversion (and concurrent tagging standardization) from my mac. I have a windows VM that I bring up when needed and a few other linux servers, but not for the purpose of audio (they're actually "servers" with no head nor sound) that I could use for processing, but would prefer to check concurrently to editing of the metadata.

Thanks for the code! I think I'll just have to go down the route of trying to compile my own solution on the mac or switch to background processing the PCM cmp from a linux box and breaking up my workflow.

Re: ALAC PCM compare on OS X?

Reply #5
What do you need to compile?
PANIC: CPU 1: Cache Error (unrecoverable - dcache data) Eframe = 0x90000000208cf3b8
NOTICE - cpu 0 didn't dump TLB, may be hung

Re: ALAC PCM compare on OS X?

Reply #6
Conveniently missing all of those codecs that seem to only bar distribution of the resulting binaries just to piss people off, and obviously not because people are somehow afraid of patent lawyers.

Re: ALAC PCM compare on OS X?

Reply #7
Plural? From what I can see "only" fdk-aac is missing.
PANIC: CPU 1: Cache Error (unrecoverable - dcache data) Eframe = 0x90000000208cf3b8
NOTICE - cpu 0 didn't dump TLB, may be hung

Re: ALAC PCM compare on OS X?

Reply #8
Apologies for the lack of clarity in my response.

The conversion to wave of the flac & alac with a diff is a high impact over 4tb of music, but a great interim solution.

I'll end up either:
1. make shntool with the alac helper for OS X from the current code base (the problem I'm having here is finding the source as http://craz.net/ is not responding)
2. use linux attached to my NAS running shntool with alac (given I can find in usable form)

The problem I'm running into is the alac helper program available in the wild for anything other then windows (ugh).

Re: ALAC PCM compare on OS X?

Reply #9
2. use linux attached to my NAS running shntool with alac (given I can find in usable form)

The problem I'm running into is the alac helper program available in the wild for anything other then windows (ugh).
By simply creating a symlink to alac-decoder I was able to get "shntool cmp orig.flac new.m4a" to work on linux.

I cannot find an alac helper equivalent yet for mac in either compiled+made form or source. Anyone?

Re: ALAC PCM compare on OS X?

Reply #10
How is that different from the ffmpeg solution speedwise?
PANIC: CPU 1: Cache Error (unrecoverable - dcache data) Eframe = 0x90000000208cf3b8
NOTICE - cpu 0 didn't dump TLB, may be hung