musicaiz.features.average_pitch_interval

musicaiz.features.average_pitch_interval(notes: List[musicaiz.structure.notes.Note]) float[source]

Computes the Average Pitch Interval (PI) of a a list of musicaiz Note() objects.

The steps to compute the PI are:
  1. Compute the pitch difference between two consecutive notes.

  2. Compute the mean between the pitch intervals.

This method does take into account the polyphonic notes.

Parameters
notes: List[Note]

A list of musicaiz Note() objects.

Returns
float: _description_

Average of the pitch intervals between consecutive notes.