align-audio

Find relative time displacement of two recordings of the same music

LTS Haskell 24.50:0.0.0.2
Stackage Nightly 2026-07-12:0.0.0.2
Latest on Hackage:0.0.0.2

See all snapshots align-audio appears in

BSD-3-Clause licensed and maintained by Henning Thielemann
This version can be pinned in stack with:align-audio-0.0.0.2@sha256:4199f568e1509ec91e3a5ea3beb04627c41c5e2d148ba1f84a8bc682e4d54bc3,3157

Module documentation for 0.0.0.2

There are no documented modules for this package.

Say, you have a video with some background music and a clean recording of the background music. You want to know exact displacement of the background music. This program should find it.

align-audio orig.wav video.wav

The program actually performs a simple correlation.

The program can handle sources of different sample rates if the sample rates are integers.

You can specify the precision of the displacement using the --rate option, which must be a positive integer:

align-audio --rate 1000 orig.wav video.wav

For reading of audio files, libsox is used and thus you can use all audio formats supported by SoX.

Cabal-Flags:

  • blas for running with 'comfort-blas' (more memory consumption)

  • lapack for running with lapack (heavier dependency)