fix of some compiler warnings: comparison between unsigned int and int

This commit is contained in:
rluna
2019-01-03 16:37:50 +01:00
parent 75116e157e
commit e5eb1bbf9d
7 changed files with 28 additions and 40 deletions

View File

@@ -124,7 +124,7 @@ public:
fwrite(&str_size, sizeof(size_t), 1, file);
fwrite(m_activation_function_str.c_str(), sizeof(char), str_size, file);
for (int i = 0; i < m_nodes.size(); i++) {
for (size_t i = 0; i < m_nodes.size(); i++) {
m_nodes[i].SaveNode(file);
}
};
@@ -149,7 +149,7 @@ public:
m_deriv_activation_function = (*pair).second;
m_nodes.resize(m_num_nodes);
for (int i = 0; i < m_nodes.size(); i++) {
for (size_t i = 0; i < m_nodes.size(); i++) {
m_nodes[i].LoadNode(file);
}
@@ -165,4 +165,4 @@ protected:
std::function<double(double)> m_deriv_activation_function;
};
#endif //LAYER_H
#endif //LAYER_H