2
$\begingroup$

I solved the xor problem using neural network... but I'm really confused

my neural network structure looks like this!

structure

the first result was like... result1

and the second result was like... result2

could there be multiple answers in weights and bias in neural network? or is it just because of the local minium... (both two result has VERY small cost)

I used the GA method to optimize the cost function.. I this that could be the reason why I have two totally different answers meaning that those result could be caught on the local minimum.. but please regard that both two result has super small cost

$\endgroup$

1 Answer 1

1
$\begingroup$

Yes, there are multiple solutions to solve the XOR problem using a neural net with the structure you show. With standard back-propagation training or with a GA, the solution you find will depend upon the initial sets of weights, and how weights are adjusted over the course of training/evolution.

If you run it multiple times, however, what you will start to notice consistent patterns to the signs of the weights and biases. Doing lots of comparisons you'll notice a symmetry among those patterns as well.

Regarding the cost being small but not zero, if you're using a sigmoid function for the last layer, the output can never truly be 0 or 1, but very close, so your cost will always be greater than zero.

$\endgroup$
1
  • $\begingroup$ thanks for the comment! I appreciate it! $\endgroup$
    – GazelGoes
    Commented Sep 4, 2020 at 23:39

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.