Open kalber opened 7 years ago
I've been trying to make a solution to this problem, but I also can't seem to figure out what you can do with a LayerConnection of two networks. For some reason you can't use it as follows:
var AND = new Architect.Perceptron(2,2,1);
var NOT = new Architect.Perceptron(1,1,1);
AND.project(NOT); // project AND output in NOT input
A.activate([1,1]); // should output 1
B.activate(); // This line throws an error, while it works for when you replace AND and NOT by layers!
Which I think is quite odd. However, why wo you want to connect an AND and a NOT in the first place? Why not just write it like this:
networkNOT.activate([networkAND.activate([0,0])])
This will output the AND to a NOT. And even better, why train an AND a NOT, when you can just train a NAND! It's easier than connecting two seperate networks.
And how do you propagate through both of them?
I have two networks, logic gate "AND" and logic gate "NOT", both trained.
i want to pass the output from the "AND" to the input the "NOT". i try something like this: var networkAND = new Perceptron(2,2,1); //To Train here networkAND... var networkNOT = new Perceptron(1,1,1); //To Train here networkNOT... networkAND.project(networkNOT);
that returns a LayerConnection, but i don't know what i can do with that.
I hope you understand my point.
Thanks in advance.