Creates a corpus from a set of audio files. More...
#include <corpusbuilder.h>
Public Member Functions | |
| CorpusBuilder () | |
| Constructor. | |
| ~CorpusBuilder () | |
| Destructor. | |
| void | setElementLength (int sec) |
| Set what length (in seconds) should be used as training element length (0 : use the whole files) | |
| void | setComputingOffset (int sec) |
| Set computing offset (the time at the beginning of each file we should forget) | |
| bool | setup (string fileName) |
| Set up from an XML file. | |
| bool | write (Corpus *corpus) |
| Write down the results. | |
| void | compute () |
| Compute. | |
| void | setVerbose (bool verbose) |
| Sets verbosity. | |
| bool | setupPipeline (string filename) |
| Mirror from SoundAnalyser. | |
Additional Inherited Members | |
Private Member Functions inherited from SoundAnalyser | |
| SoundAnalyser (bool live=false) | |
| Sets up a new sound analyser. | |
| ~SoundAnalyser () | |
| Destructor. | |
| void | resetExtractors () |
| Extractors management. | |
| void | cleanExtractors () |
| Clean the data in the extractors. | |
| void | registerExtractor (string name, FeatureExtractor *extr, bool used=true, bool drawLines=true) |
| Adds a new extractor. | |
| FeatureExtractor * | getExtractor (string name) |
| Find an extractor. | |
| void | setNormalization (float min, float max) |
| Set up unified bounds for all features. | |
| bool | compute (string url) |
| Compute the features of a given file. | |
| void | waitComputed () |
| Wait up to the end of the computation. | |
| unsigned int | nbFeatures () |
| Features management : sizes. | |
| unsigned int | nbElems (unsigned int n) |
| Return the number of elements of the nth feature. | |
| unsigned int | nbSamples () |
| Return the number of sample we've been computing. | |
| unsigned int | dimension () |
| Get the dimension : sum of all the nbElems(i) | |
| unsigned int | realDimension () |
| Get the real dimension : sum of all the nbElems we care (the values which are actually used for detection) | |
| double ** | features (unsigned int n) |
| Return the array of features for the nth sample. | |
| void | clearFeatures () |
| Clears the features. | |
| void | cleanOldFeatures (unsigned int newestCount) |
| Removes the old features so that the newest remain. | |
| bool | isUsed (unsigned int index) |
| Features management : individual properties. | |
| bool | isDrawnWithLines (unsigned int index) |
| Should this feature be drawn as a lines or a shade of grey ? | |
| string | name (unsigned int n) |
| Get the name of the nth feature. | |
| int | getFeatureByName (string name) |
| Get the id of the feature named so (-1 if not found) | |
| void | useBuffer () |
| Callbacks. | |
| void | sequenceEnds () |
| End the computation. | |
| virtual void | useFeatures () |
| Callback called when the buffer has been used (the features are ready to be used) | |
| unsigned int | samplingFrequency () |
| Mirrors. | |
Creates a corpus from a set of audio files.
| CorpusBuilder::CorpusBuilder | ( | ) |
Constructor.
Sets up a new corpus builder.
| void CorpusBuilder::compute | ( | ) |
Compute.
Compute the features.
| bool CorpusBuilder::setup | ( | string | fileName | ) |
Set up from an XML file.
Longue vie à boost::filesystem !
1.8.1.1