Commit f698ede4 authored by Joseph Larralde's avatar Joseph Larralde
Browse files

update main.cpp

parent d255442c
...@@ -12,7 +12,9 @@ int main(int argc, const char * argv[]) { ...@@ -12,7 +12,9 @@ int main(int argc, const char * argv[]) {
regression myNN; regression myNN;
classification myKnn; classification myKnn;
// gmm classification uses the first element of trainingExample.output as a label
gmmClassification myGmm; gmmClassification myGmm;
// gmm regression uses trainingExample.output as output examples
gmmRegression myGmr; gmmRegression myGmr;
std::vector<trainingExample> trainingSet; std::vector<trainingExample> trainingSet;
...@@ -38,16 +40,14 @@ int main(int argc, const char * argv[]) { ...@@ -38,16 +40,14 @@ int main(int argc, const char * argv[]) {
regression myNNfromFile; regression myNNfromFile;
myNNfromFile.readJSON(filepath); myNNfromFile.readJSON(filepath);
std::vector<double> inputVec = { 2.0, 44.2 };
// std::cout << "before: " << myNN.process(inputVec)[0] << std::endl;
// std::cout << "from string: " << myNNfromString.process(inputVec)[0] << std::endl;
// std::cout << "from file: " << myNNfromFile.process(inputVec)[0] << std::endl;
// std::vector<double> out = myGmm.process(inputVec); std::vector<double> inputVec = { 2.0, 44.2 };
// std::cout << "GMM : " << out[0] << std::endl; std::cout << "before: " << myNN.process(inputVec)[0] << std::endl;
// std::cout << out.size() << std::endl; std::cout << "from string: " << myNNfromString.process(inputVec)[0] << std::endl;
std::cout << "from file: " << myNNfromFile.process(inputVec)[0] << std::endl;
std::cout << "GMM : " << myGmm.process(inputVec)[0] << std::endl; std::cout << "GMM : " << myGmm.process(inputVec)[0] << std::endl;
std::cout << "GMR : " << myGmr.process(inputVec)[0] << std::endl; std::cout << "GMR : " << myGmr.process(inputVec)[0] << std::endl;
inputVec = { 0.2, 0.7 }; inputVec = { 0.2, 0.7 };
std::cout << "GMM : " << myGmm.process(inputVec)[0] << std::endl; std::cout << "GMM : " << myGmm.process(inputVec)[0] << std::endl;
std::cout << "GMR : " << myGmr.process(inputVec)[0] << std::endl; std::cout << "GMR : " << myGmr.process(inputVec)[0] << std::endl;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment