int Argument_main(Argument *arg){ Match_ArgumentSet_create(arg); Affine_ArgumentSet_create(arg); Argument_process(arg, "affine.test", NULL, NULL); test_model(Affine_Model_Type_GLOBAL, -151); test_model(Affine_Model_Type_BESTFIT, 18); test_model(Affine_Model_Type_LOCAL, 32); test_model(Affine_Model_Type_OVERLAP, 18); return 0; }
int main() { int Error = 0; Error += test_compiler(); Error += test_model(); Error += test_operators(); return Error; }
int main() { //Class<vec, float> C; int Error = 0; Error += test_cpp_version(); Error += test_compiler(); Error += test_model(); Error += test_operators(); return Error; }
vector<Scores> eval_on_dirs(shared_ptr<Model>model, vector<string> testDirs) { // setup parameters vector<Scores> scores; map<string,Scores> scoresByPose; // default values scores = vector<Scores>(testDirs.size()); // open the output file FileStorage best_detections(params::out_dir() + "best_detections.yml",FileStorage::WRITE); TaskBlock test_each_directory("eval_model"); for(int iter = 0; iter < testDirs.size(); iter++) { test_each_directory.add_callee([&,iter]() { test_model(*model,testDirs[iter],scores[iter], scoresByPose, [&](string filename,DetectorResult&det,DetectorResult&closest,bool correct) { write_best_det(best_detections,filename,det,closest,correct); }); //if(POSE == "") //eval_pose_estimation(*model,testDirs[iter],scores[iter]); }); } test_each_directory.execute(); // release the output directory best_detections.release(); // log the results for(int iter = 0; iter < testDirs.size(); iter++) eval_log_result(testDirs[iter],scores[iter]); // by pose for(auto pose_score : scoresByPose) eval_log_result(pose_score.first,pose_score.second); // total eval_log_result("TOTAL",Scores(scores)); return scores; }