Skip to content

Commit

Permalink
Fixed standard network results, Using LeakyRelu
Browse files Browse the repository at this point in the history
  • Loading branch information
bararchy committed Sep 27, 2017
1 parent 3bacffa commit 3b94e07
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
6 changes: 2 additions & 4 deletions spec/network_spec.cr
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,8 @@ describe Fann::Network do
train_data = Fann::TrainData.new(input, output)
data = train_data.train_data
ann.train_algorithem(LibFANN::TrainEnum::TrainRprop)
# ann.set_hidden_layer_activation_func(LibFANN::ActivationfuncEnum::Linear)
# ann.set_output_layer_activation_func(LibFANN::ActivationfuncEnum::Linear)
ann.set_hidden_layer_activation_func(LibFANN::ActivationfuncEnum::LeakyRelu)
ann.set_output_layer_activation_func(LibFANN::ActivationfuncEnum::LeakyRelu)
if data
ann.train_batch(data, {:max_runs => 8000, :desired_mse => 0.001, :log_each => 1000})
end
Expand All @@ -65,8 +65,6 @@ describe Fann::Network do
train_data = Fann::TrainData.new(input, output)
data = train_data.train_data
ann.train_algorithem(LibFANN::TrainEnum::TrainRprop)
# ann.set_hidden_layer_activation_func(LibFANN::ActivationfuncEnum::Linear)
# ann.set_output_layer_activation_func(LibFANN::ActivationfuncEnum::Linear)
if data
ann.train_batch(data, {:max_neurons => 500, :desired_mse => 0.1, :log_each => 10})
end
Expand Down
1 change: 0 additions & 1 deletion src/crystal-fann/lib_fann.cr
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,6 @@ lib LibFANN
end

# Structs

struct Error
errno_f : ErrnoEnum
error_log : File*
Expand Down

0 comments on commit 3b94e07

Please sign in to comment.