Mercurial > hg > qm-dsp
comparison dsp/segmentation/ClusterMeltSegmenter.h @ 26:d096a79fa772
* Add timbral (MFCC) feature option to segmenter
author | cannam |
---|---|
date | Thu, 10 Jan 2008 16:41:33 +0000 |
parents | 2b74bd60c61f |
children | 6cb2b3cd5356 |
comparison
equal
deleted
inserted
replaced
25:54a962727271 | 26:d096a79fa772 |
---|---|
17 | 17 |
18 using std::vector; | 18 using std::vector; |
19 | 19 |
20 class Decimator; | 20 class Decimator; |
21 class ConstantQ; | 21 class ConstantQ; |
22 class MFCC; | |
22 | 23 |
23 class ClusterMeltSegmenterParams | 24 class ClusterMeltSegmenterParams |
24 // defaults are sensible for 11025Hz with 0.2 second hopsize | 25 // defaults are sensible for 11025Hz with 0.2 second hopsize |
25 { | 26 { |
26 public: | 27 public: |
64 int getNSegmentTypes() { return nclusters; } | 65 int getNSegmentTypes() { return nclusters; } |
65 | 66 |
66 protected: | 67 protected: |
67 void makeSegmentation(int* q, int len); | 68 void makeSegmentation(int* q, int len); |
68 | 69 |
70 void extractFeaturesConstQ(const double *, int); | |
71 void extractFeaturesMFCC(const double *, int); | |
72 | |
69 Window<double> *window; | 73 Window<double> *window; |
70 ConstantQ* constq; | 74 ConstantQ* constq; |
75 MFCC* mfcc; | |
71 model_t* model; // the HMM | 76 model_t* model; // the HMM |
72 int* q; // the decoded HMM state sequence | 77 int* q; // the decoded HMM state sequence |
73 vector<vector<double> > histograms; | 78 vector<vector<double> > histograms; |
74 | 79 |
75 feature_types featureType; | 80 feature_types featureType; |