source: tests/src/spectral/test-mfcc.c @ 986131d

feature/autosinkfeature/cnnfeature/cnn_orgfeature/constantqfeature/crepefeature/crepe_orgfeature/pitchshiftfeature/pydocstringsfeature/timestretchfix/ffmpeg5
Last change on this file since 986131d was 986131d, checked in by Eduard Müller <mueller.eduard@googlemail.com>, 7 years ago

Intel IPP support for aubio

See emuell/aubio/ intel_ipp2 for details please

  • Property mode set to 100644
File size: 709 bytes
Line 
1#include <aubio.h>
2
3int main (void)
4{
5  aubio_init();
6
7  uint_t win_s = 512; // fft size
8  uint_t n_filters = 40; // number of filters
9  uint_t n_coefs = 13; // number of coefficients
10  smpl_t samplerate = 16000.; // samplerate
11  cvec_t *in = new_cvec (win_s); // input buffer
12  fvec_t *out = new_fvec (n_coefs); // output coefficients
13
14  // create mfcc object
15  aubio_mfcc_t *o = new_aubio_mfcc (win_s, n_filters, n_coefs, samplerate);
16
17  cvec_norm_set_all (in, 1.);
18  aubio_mfcc_do (o, in, out);
19  fvec_print (out);
20
21  cvec_norm_set_all (in, .5);
22  aubio_mfcc_do (o, in, out);
23  fvec_print (out);
24
25  // clean up
26  del_aubio_mfcc (o);
27  del_cvec (in);
28  del_fvec (out);
29 
30  aubio_cleanup ();
31
32  return 0;
33}
Note: See TracBrowser for help on using the repository browser.