Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042
00043
00044
00045
00046
00047
00048
00049
00050
00051
00052
00053
00054
00055
00056 #include <iostream>
00057
00058 #include "liatools.h"
00059 #include "ComputeJFAStats.h"
00060
00061 using namespace alize;
00062 using namespace std;
00063
00064 int main(int argc, char* argv[]) {
00065 ConfigChecker cc;
00066 try {
00067
00068 cc.addStringParam("ndxFilename",true,true,"NDX of multiple GMM speaker recordings");
00069 cc.addStringParam("inputWorldFilename",true,true,"the world model file");
00070 cc.addStringParam("saveMatrixFormat",true,true,"matrix format: DB (binary) or DT (ascii)");
00071 cc.addStringParam("saveMatrixFilesExtension",true,true,"matrix file extension");
00072
00073
00074
00075
00076 cc.addStringParam("loadMatrixFormat",false,true,"matrix format: DB (binary) or DT (ascii)");
00077 cc.addStringParam("nullOrderStatSpeaker",false,true,"Name of the Null order speaker stat matrix to store");
00078 cc.addStringParam("nullOrderStatSession",false,true,"Name of the Null order session stat matrix to store");
00079 cc.addStringParam("firstOrderStatSpeaker",false,true,"Name of the First order speaker stat matrix to store");
00080 cc.addStringParam("firstOrderStatSession",false,true,"Name of the First order session stat matrix to store");
00081
00082
00083
00084
00085 CmdLine cmdLine(argc, argv);
00086 if (cmdLine.displayHelpRequired()){
00087 cout << "****************************************" << endl;
00088 cout << "********** ComputeJFAStats.exe ************" << endl;
00089 cout << "****************************************" << endl;
00090 cout << endl;
00091 cout << "Compute sufficient statisitc for Joint Factor Analysis" << endl;
00092 cout <<endl<<cc.getParamList()<<endl;
00093 return 0;
00094 }
00095 if (cmdLine.displayVersionRequired()){
00096 cout <<"Version 2.0 Mistral Package"<<endl;
00097 }
00098
00099 Config tmp;
00100 cmdLine.copyIntoConfig (tmp);
00101 Config config;
00102 if (tmp.existsParam("config")) config.load(tmp.getParam("config"));
00103 cmdLine.copyIntoConfig(config);
00104 cc.check(config);
00105 debug=config.getParam_debug();
00106 if (config.existsParam("verbose"))verbose=config.getParam("verbose").toBool();else verbose=false;
00107 if (verbose) verboseLevel=1;else verboseLevel=0;
00108 if (config.existsParam("verboseLevel"))verboseLevel=config.getParam("verboseLevel").toLong();
00109 if (verboseLevel>0) verbose=true;
00110 if (cmdLine.displayHelpRequired()) {cout << cc.getParamList() << endl;}
00111 ComputeJFAStats(config);
00112 }
00113 catch (Exception& e) {cout << e.toString() << cc.getParamList() << endl;}
00114 if (debug) {
00115 }
00116 return 0;
00117 }