Skip to content
This repository has been archived by the owner on Sep 3, 2024. It is now read-only.

Commit

Permalink
Fix compatibility check using invalid layer getting function
Browse files Browse the repository at this point in the history
  • Loading branch information
daedsidog committed Apr 26, 2019
1 parent 740e2e5 commit 7181147
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 3 deletions.
4 changes: 2 additions & 2 deletions Fanna/net.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,8 @@ void net::load(void) {
std::cout << "Loading " << netname << "..." << std::endl;
ann.create_from_file((std::stringstream() << netname << "\\" << netname << ".net").str());
if ((ann.get_num_input() != hindsight_level * 5)
|| ((ann.get_num_layers() != hidden_layers) && !cascade_training)
|| ((ann.get_total_neurons() != 1 + hindsight_level * 5 + int(round(double(double(hindsight_level) * 5) * hidden_layer_factor)) * hidden_layers) && !cascade_training)) {
|| ((ann.get_num_layers() != hidden_layers + 2) && !cascade_training)
|| ((ann.get_total_neurons() - (ann.get_num_layers() - 1) != 1 + hindsight_level * 5 + int(round(double(double(hindsight_level) * 5) * hidden_layer_factor)) * hidden_layers) && !cascade_training)) {
print_warning("Mismatch between ANN and configuration.");
reset();
}
Expand Down
Binary file modified Release/Fanna.dll
Binary file not shown.
1 change: 0 additions & 1 deletion Release/config.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,4 @@ cascade_training = 1 // Binary value. Only RPROP and QUICKPROP work when cascad
hidden_layers = 2
shuffle_data = 0 // Binary value
report_interval = 1
cascade_addend = 32
hidden_layer_factor = 2.0

0 comments on commit 7181147

Please sign in to comment.