Skip to content
Snippets Groups Projects
Commit afa2630b authored by Martin Beseda's avatar Martin Beseda
Browse files

[NEW] [DEL] Removed main.cpp and 'test_cases' executable and created...

[NEW] [DEL] Removed main.cpp and 'test_cases' executable and created dev_sandbox.cpp and 'dev_sandbox' target instead.
parent 0a9d435c
No related branches found
No related tags found
No related merge requests found
......@@ -5,8 +5,8 @@
add_executable(seminar seminar.cpp)
target_link_libraries(seminar PUBLIC lib4neuro)
add_executable(test_cases main.cpp)
target_link_libraries(test_cases PUBLIC lib4neuro)
add_executable(dev_sandbox dev_sandbox.cpp)
target_link_libraries(dev_sandbox PUBLIC lib4neuro)
add_executable(net_test_1 net_test_1.cpp)
target_link_libraries(net_test_1 PUBLIC lib4neuro)
......@@ -35,7 +35,7 @@ target_link_libraries(x2_fitting PUBLIC lib4neuro)
set(EXAMPLES_OUTPUT_DIR ${PROJECT_BINARY_DIR}/examples)
set_target_properties(
test_cases
dev_sandbox
net_test_1
net_test_2
net_test_3
......@@ -53,7 +53,7 @@ set_target_properties(
)
target_include_directories(
test_cases
dev_sandbox
PRIVATE
${ROOT_DIR}/include
)
......
/**
* This file serves for testing of various examples, have fun!
*
* @author Michal Kravčenko
* @date 14.6.18 -
*/
#include <iostream>
#include <cstdio>
#include <fstream>
#include <vector>
#include <utility>
#include <algorithm>
#include <assert.h>
#include "4neuro.h"
int main(int argc,
char** argv) {
std::vector<std::pair<std::vector<double>, std::vector<double>>> data_vec;
std::vector<double> inp, out;
for (int i = 0; i < 3; i++) {
inp.push_back(i);
out.push_back(i + 4);
}
data_vec.emplace_back(std::make_pair(inp,
out));
lib4neuro::DataSet DataSet(&data_vec);
int elements = DataSet.get_n_elements();
std::string filename = "/home/martin/4Neuro/build/unit-tests/testDataSet";
DataSet.store_text(filename);
//Test of correct file creations
lib4neuro::DataSet newDataSet(filename);
return 0;
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment