started moving learning algos to new namespace Machnine Learning
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
#include "../src/NeuronNetwork/FeedForward"
|
||||
#include "../src/NeuralNetwork/FeedForward"
|
||||
|
||||
#include <iostream>
|
||||
class X: public Shin::NeuronNetwork::Problem
|
||||
class X: public Shin::Problem
|
||||
{
|
||||
public: X(bool x,bool y):Problem() {data.push_back(x);data.push_back(y);}
|
||||
};
|
||||
@@ -10,7 +10,7 @@ int main()
|
||||
{
|
||||
srand(time(NULL));
|
||||
int lm=5;
|
||||
Shin::NeuronNetwork::FeedForward net({2,lm,1});
|
||||
Shin::NeuralNetwork::FeedForward net({2,lm,1});
|
||||
bool x=1;
|
||||
int prev_err=0;
|
||||
int err=0;
|
||||
@@ -47,7 +47,7 @@ int main()
|
||||
{
|
||||
bool x= rand()%2;
|
||||
bool y=rand()%2;
|
||||
Shin::NeuronNetwork::Solution s =net.solve(X(x,y));
|
||||
Shin::Solution s =net.solve(X(x,y));
|
||||
if(s[0]!= (x xor y))
|
||||
err++;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user