ferraus declick

Remove clicks, pops, and crackle

Synopsis

ferraus declick <input> [options] [-o <output>]

What it does

Fits an autoregressive model to the audio and flags samples whose forward and backward prediction errors are both outliers (a click), then re-synthesises each flagged run by least-squares AR interpolation. Several passes catch clicks hidden by bigger ones. --auto is the vinyl-crackle preset; --big-pops also repairs wider pops.

This command is also an fx stage and a pipeline op: ferraus fx in.wav -o out.wav --fx "declick:key=value".

Examples

Remove clicks with the defaults

ferraus declick lp-rip.wav -o clean.wav

Vinyl crackle preset

ferraus declick lp-rip.wav --auto -o clean.wav

Catch quieter clicks and wide pops

ferraus declick tape.wav --big-pops on --sensitivity 50% -o clean.wav

Options

FlagTypeDefaultMeaning
--sensitivitypercent30%Detection sensitivity in percent: higher finds quieter clicks (and risks transients)
--complexityinteger16AR model order used for detection and interpolation Range: 4..64.
--max-widthtime2msWidest click to repair (time); wider events are treated as music
--big-popson|offoffAlso repair wide pops up to 20 ms (on|off)
--passesinteger4Number of detect-and-repair passes Range: 1..16.
--autoflag—Vinyl crackle preset: higher sensitivity, more passes, higher order
--mixpercent100%Dry/wet balance: 0% returns the input unchanged, 100% is fully processed

Global options

Every command also accepts the global options (-o, --json, --dry-run, --overwrite, --progress, ...). See Global options.

Exit codes

CodeMeaning
0Success
1Processing failed
2Usage or parameter error
3Input missing or unreadable
4Unsupported format or codec
8Cancelled
70Internal error (bug)

Common mistakes

  • Forgetting that outputs are never overwritten: pass --overwrite or a new -o path when re-running.
  • Beat-based times (4b, 1/4) need a tempo: pass --bpm or write 4b@120.
  • Percentages accept 80% or the fraction 0.8; a bare 80 means 80x, not 80%.

For models

  • MCP tool: ferraus_declick
  • Schema: ferraus schema declick
  • Pipeline: { op: declick, args: { ... } } (flag names with _ instead of -)
  • fx stage: yes
{"command": "declick", "defaults": {"sensitivity": "30%", "complexity": "16", "max_width": "2ms", "big_pops": "off", "passes": "4", "mix": "100%"}}