void PerformanceFunctionalTest::test_set_default(void) { message += "test_set_default\n"; PerformanceFunctional pf; // Test pf.set_default(); }
void PerformanceFunctionalTest::test_get_neural_network_pointer(void) { message += "test_get_neural_network_pointer\n"; PerformanceFunctional pf; NeuralNetwork nn; // Test pf.set_neural_network_pointer(&nn); assert_true(pf.get_neural_network_pointer() != NULL, LOG); }
void PerformanceFunctionalTest::test_get_display(void) { message += "test_get_display\n"; PerformanceFunctional pf; // Test pf.set_display(true); assert_true(pf.get_display() == true, LOG); pf.set_display(false); assert_true(pf.get_display() == false, LOG); }
void PerformanceFunctionalTest::test_save(void) { message += "test_save\n"; std::string file_name = "../data/performance_functional.xml"; PerformanceFunctional pf; pf.set_objective_type(PerformanceFunctional::MINKOWSKI_ERROR_OBJECTIVE); pf.set_regularization_type( PerformanceFunctional::NEURAL_PARAMETERS_NORM_REGULARIZATION); pf.save(file_name); }
void PerformanceFunctionalTest::test_to_XML(void) { message += "test_to_XML\n"; PerformanceFunctional pf; pf.set_objective_type(PerformanceFunctional::MINKOWSKI_ERROR_OBJECTIVE); pf.set_regularization_type(PerformanceFunctional::NEURAL_PARAMETERS_NORM_REGULARIZATION); tinyxml2::XMLDocument* document = pf.to_XML(); assert_true(document != NULL, LOG); delete document; }