Public Member Functions
|Bands (MatrixXI starts, std::vector< MatrixXR > weights)|
|void||process (const MatrixXR &frames, MatrixXR *bands)|
|std::vector< MatrixXR >||weights () const|
|void||bandWeights (int band, MatrixXR *bandWeights) const|
|void||starts (MatrixXI *result) const|
|int||bands () const|
|void||setStartsWeights (const MatrixXI &starts, std::vector< MatrixXR > weights, bool callSetup=true)|
This class represents an object to perform calculatinos of band values. The value of a band corresponds to the sum of the values of the input array in the band's positions multiplied with the band's weights.
In this implementation the positions of a given band are defined by the index of the first array cell of the band and the size of the weights array. The full configuration of the bands algorithm is defined using a single column matrix for the starts of the bands and a vector of single row matrices for the weights each band.
Note that the number of rows of the starts matrix and the size of the vector of weights must be the same, and this will be the number of bands.
|std::vector< MatrixXR >||weights|
Constructs a Bands object with the specified starts and weights setting.
|starts||single column matrix of Integers that determine the first array cell of each band.|
|weights||vector of single row matrices of Reals that determine the values of the weights of each band.|
|void process||(||const MatrixXR &||frames,|
Calculates the bands of frames using the specified starts and weights properties.
|frames||matrix of Real values.|
|bands||pointer to a matrix of Real values for the output. The matrix should have the same number of rows as frames and as many columns as the number of bands (rows in the starts matrix and elements in the weights vector).|
|vector< MatrixXR > weights||(||)||const|
|void starts||(||MatrixXI *||result||)||const|
Return in result the single column matrix of start indices of the bands.
Referenced by MelBands::starts().
Return number of bands.
Referenced by MelBands::bands().
|void setStartsWeights||(||const MatrixXI &||starts,|
|std::vector< MatrixXR >||weights,|
|bool|| callSetup = |
Determines the starts positions and weights of the bands. Note that the number of rows of starts and the size of weights should be the same and will determine the number of bands.