Skip to main content
replaced http://stackoverflow.com/ with https://stackoverflow.com/
Source Link
  1. compute RMS from audio signal to get power
  2. do AGC (automatic gain control)
  3. perform "discrete differentiation" (the simplest is 1st order: $y[i] = x[i] - x[i-1]$)
  4. if the value is greater than certain threshold, it means we have an onset. You have to determinate the threshold experimentally or use adaptive algorithm. Obviously you also need some kind of lowpass filter to filter the noise.

You may want to swap steps 2 and 3.

If you can use software libraries, check out aubio.

Possible duplicate of http://stackoverflow.com/questions/294468/note-onset-detectionhttps://stackoverflow.com/questions/294468/note-onset-detection

  1. compute RMS from audio signal to get power
  2. do AGC (automatic gain control)
  3. perform "discrete differentiation" (the simplest is 1st order: $y[i] = x[i] - x[i-1]$)
  4. if the value is greater than certain threshold, it means we have an onset. You have to determinate the threshold experimentally or use adaptive algorithm. Obviously you also need some kind of lowpass filter to filter the noise.

You may want to swap steps 2 and 3.

If you can use software libraries, check out aubio.

Possible duplicate of http://stackoverflow.com/questions/294468/note-onset-detection

  1. compute RMS from audio signal to get power
  2. do AGC (automatic gain control)
  3. perform "discrete differentiation" (the simplest is 1st order: $y[i] = x[i] - x[i-1]$)
  4. if the value is greater than certain threshold, it means we have an onset. You have to determinate the threshold experimentally or use adaptive algorithm. Obviously you also need some kind of lowpass filter to filter the noise.

You may want to swap steps 2 and 3.

If you can use software libraries, check out aubio.

Possible duplicate of https://stackoverflow.com/questions/294468/note-onset-detection

added 2 characters in body
Source Link
jojeck
  • 11.2k
  • 6
  • 38
  • 75
  1. compute RMS from audio signal to get power
  2. do AGC (automatic gain control)
  3. perform "discrete differentiation" (the simplest is 1st order: y[i] = x[i] - x[i-1]$y[i] = x[i] - x[i-1]$)
  4. if the value is greater than certain threshold, it means we have an onset. You have to determinate the threshold experimentally or use adaptive algorithm. Obviously you also need some kind of lowpass filter to filter the noise.

You may want to swap steps 2 and 3.

If you can use software libraries, check out aubio.

Possible duplicate of http://stackoverflow.com/questions/294468/note-onset-detection

  1. compute RMS from audio signal to get power
  2. do AGC (automatic gain control)
  3. perform "discrete differentiation" (the simplest is 1st order: y[i] = x[i] - x[i-1])
  4. if the value is greater than certain threshold, it means we have an onset. You have to determinate the threshold experimentally or use adaptive algorithm. Obviously you also need some kind of lowpass filter to filter the noise.

You may want to swap steps 2 and 3.

If you can use software libraries, check out aubio.

Possible duplicate of http://stackoverflow.com/questions/294468/note-onset-detection

  1. compute RMS from audio signal to get power
  2. do AGC (automatic gain control)
  3. perform "discrete differentiation" (the simplest is 1st order: $y[i] = x[i] - x[i-1]$)
  4. if the value is greater than certain threshold, it means we have an onset. You have to determinate the threshold experimentally or use adaptive algorithm. Obviously you also need some kind of lowpass filter to filter the noise.

You may want to swap steps 2 and 3.

If you can use software libraries, check out aubio.

Possible duplicate of http://stackoverflow.com/questions/294468/note-onset-detection

Source Link

  1. compute RMS from audio signal to get power
  2. do AGC (automatic gain control)
  3. perform "discrete differentiation" (the simplest is 1st order: y[i] = x[i] - x[i-1])
  4. if the value is greater than certain threshold, it means we have an onset. You have to determinate the threshold experimentally or use adaptive algorithm. Obviously you also need some kind of lowpass filter to filter the noise.

You may want to swap steps 2 and 3.

If you can use software libraries, check out aubio.

Possible duplicate of http://stackoverflow.com/questions/294468/note-onset-detection