Skip to content

Commit

Permalink
Exception handling
Browse files Browse the repository at this point in the history
  • Loading branch information
pierotofy committed Mar 16, 2023
1 parent 2139880 commit c8fdf01
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions pctrain.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ int main(int argc, char **argv){
exit(0);
}

// try {
try {
auto filenames = result["input"].as<std::vector<std::string>>();
std::string modelFilename = result["output"].as<std::string>();

Expand Down Expand Up @@ -72,10 +72,10 @@ int main(int argc, char **argv){
// gbm::classify(evalPointSet, modelFilename, evalFeatures, labels, true, true);
savePointSet(*evalPointSet, "evaluation_results.ply");
}
// } catch(std::exception &e){
// std::cerr << "Error: " << e.what() << std::endl;
// exit(EXIT_FAILURE);
// }
} catch(std::exception &e){
std::cerr << "Error: " << e.what() << std::endl;
exit(EXIT_FAILURE);
}

return 0;
}

0 comments on commit c8fdf01

Please # to comment.