MCPcopy Create free account
hub / github.com/FidoProject/Fido / getOutput

Method getOutput

src/Neuron.cpp:21–30  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

19}
20
21double Neuron::getOutput(std::vector<double> inputs) {
22 if(inputs.size() != weights.size() - 1) {
23 std::cout << "Wrong number of neuron inputs\n";
24 throw 1;
25 }
26 double returnNumber = 0;
27 for(unsigned int a = 0; a < inputs.size(); a++) returnNumber += inputs[a]*weights[a];
28 returnNumber += -1 * weights[weights.size()-1];
29 return returnNumber;
30}

Callers 13

getModelRewardsMethod · 0.45
getErrorMethod · 0.45
getWiresMethod · 0.45
trainMethod · 0.45
trainOnDataPointMethod · 0.45
pruning.cppFile · 0.45
backprop.cppFile · 0.45
adadelta.cppFile · 0.45
network.cppFile · 0.45
getPopulationFitnessFunction · 0.45
genetic.cppFile · 0.45

Calls 1

sizeMethod · 0.45

Tested by

no test coverage detected