gizemkiraz / aforge

Automatically exported from code.google.com/p/aforge
Other
0 stars 0 forks source link

BackPropagationLearning with large hidden layers. #268

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?

    Shared network As New ActivationNetwork(New SigmoidFunction(), 7, 40, 3)
    Shared teacher As New BackPropagationLearning(network)
    Shared er As Double = Double.PositiveInfinity
    Shared ins() As Double = {0.540703052728955, 0.168380684996999, 0.266965635827911, 1, 1.33333333333333, 0.333333333333333, 0}
    Shared outs() As Double = {0.1, 0.333333333333333, 0.333333333333333}

    Public Shared Sub Main(ByVal args As String())
        Dim res As String = "Inputs: "

        For i As Integer = 0 To ins.Length - 1
            res &= ins(i) & vbTab
        Next

        res &= vbCrLf & "Before: " 

        Dim o() As Double = network.Compute(ins)

        For i As Integer = 0 To o.Length - 1
            res &= o(i) & vbTab
        Next

        For i As Integer = 1 To 50000
            er = teacher.Run(ins, outs)
        Next

        res &= vbCrLf & "After: "

        o = network.Compute(ins)

        For i As Integer = 0 To o.Length - 1
            res &= o(i) & vbTab
        Next

        MsgBox(er & vbCrLf & res)
    End Sub

What is the expected output? What do you see instead?
- Regardless of the number of training cycles or training inputs/outputs, the 
computed output is always 1,1,1.  

What version of the product are you using?
- 2.2.2

Please provide any additional information below.
- The problem appears to be with the size of the hidden layer.  If it's reduced 
to something below 10 neurons it seems to work Ok.

Original issue reported on code.google.com by chriscro...@gmail.com on 6 Dec 2011 at 12:21

GoogleCodeExporter commented 8 years ago
See this:
www.aforgenet.com/forum/viewtopic.php?f=2&t=2453

Original comment by andrew.k...@gmail.com on 6 Dec 2011 at 9:46

GoogleCodeExporter commented 8 years ago
Rejection has never felt so good.  :)

Original comment by chriscro...@gmail.com on 6 Dec 2011 at 12:36