parity + debug output

This commit is contained in:
2016-05-19 23:30:56 +02:00
parent b8c4d25eb2
commit 2607867a25
3 changed files with 13 additions and 10 deletions

View File

@@ -48,7 +48,8 @@ float CascadeCorrelation::trainOutputs(Cascade::Network &network, const std::vec
}
while(iteration++ < _maxOutputLearningIterations && iterWithoutImporvement < _maxOutputLearningIterationsWithoutChange);
std::cout << "outputLearning: " << error << ", last: " << lastError << ", iters: " << iteration << "\n";
// std::cout << "outputLearning: " << error << ", last: " << lastError << ", iters: " << iteration << "\n";
for(std::size_t neuron = 0; neuron < outputs; neuron++) {
network.getOutputNeurons()[neuron]->setWeights(p[1][neuron + 1].getWeights());
}
@@ -144,7 +145,7 @@ float CascadeCorrelation::trainOutputsRandom(std::size_t step, Cascade::Network
FeedForward::Network &p = *possibleOutputs[bestNetwork];
std::cout << "network: " << bestNetwork << ", error: " << bestScore << "\n";
std::cout << "network: " << bestNetwork << "\n";
for(std::size_t neuron = 0; neuron < outputs; neuron++) {
network.getNeuron(network.getNeuronSize() - outputs + neuron)->setWeights(p[1][neuron + 1].getWeights());