2015-03-23 20:58:30 +00:00
|
|
|
#pragma once
|
|
|
|
|
|
|
|
#include <vector>
|
|
|
|
|
|
|
|
#include "Neuron.h"
|
|
|
|
|
|
|
|
class Layer : public std::vector < Neuron >
|
|
|
|
{
|
|
|
|
public:
|
2015-10-15 20:37:13 +00:00
|
|
|
Layer(size_t numNeurons);
|
2015-03-23 20:58:30 +00:00
|
|
|
|
|
|
|
void setOutputValues(const std::vector<double> & outputValues);
|
|
|
|
void feedForward(const Layer &inputLayer);
|
|
|
|
double getWeightedSum(int outputNeuron) const;
|
|
|
|
void connectTo(const Layer & nextLayer);
|
2015-10-16 20:59:04 +00:00
|
|
|
|
|
|
|
void updateInputWeights(const Layer &prevLayer);
|
2015-03-23 20:58:30 +00:00
|
|
|
};
|