class

Ai4cr::NeuralNetwork::Cmn::Chain

Inherits JSON::Serializable / Reference / Object

Constructors

new(pull : JSON::PullParser)
Source

NOTE: When passing in the array for net_set, .. if you're including just one type of MiniNet, e.g.: net0 = Ai4cr::NeuralNetwork::Cmn::MiniNet::Sigmoid.new(height: 256, width: 300, history_size: 60) net1 = Ai4cr::NeuralNetwork::Cmn::MiniNet::Sigmoid.new(height: 300, width: 3, history_size: 60)

... and you try to pass in like below, you'll get a type error: cns = Ai4cr::NeuralNetwork::Cmn::Chain.new([net0, net1])

... So, you'll need to init the array like: arr = Array(Ai4cr::NeuralNetwork::Cmn::MiniNet).new arr << net0 arr << net1

... and then pass it in like: cns = Ai4cr::NeuralNetwork::Cmn::Chain.new(arr)

Source
new(*, __pull_for_json_serializable pull : JSON::PullParser)
Source

Instance methods

calc_structure
Source
error_stats
Source
errors
Source
eval(inputs_given)
Source
guesses_best
Source
net_set
Source
net_set=(net_set : Array(MiniNet))
Source
net_set_indexes_reversed
Source
net_set_size
Source
structure
Source
train(inputs_given, outputs_expected, until_min_avg_error = 0.1)

TODO: utilize until_min_avg_error

Source
validate
Source
validate!
Source
weight_height_mismatches
Source