Iteration 1 Iteration 1

Iteration 2 Iteration 2

Iteration 3 Iteration 3

Iteration 4 Iteration 4

Iteration 5 Iteration 5

Iteration 10 Iteration 10

BasicOptimizer.scala:89 executed in 46.13 seconds (0.742 gc):

    val lineSearchInstance: LineSearchStrategy = lineSearchFactory
    val trainer = new IterativeTrainer(trainable)
    trainer.setOrientation(orientation())
    trainer.setMonitor(new TrainingMonitor() {
      override def clear(): Unit = trainingMonitor.clear()
  
      override def log(msg: String): Unit = {
        trainingMonitor.log(msg)
        BasicOptimizer.this.log(msg)
      }
  
      override def onStepFail(currentPoint: Step): Boolean = {
        BasicOptimizer.this.onStepFail(trainable.addRef().asInstanceOf[Trainable], currentPoint)
      }
  
      override def onStepComplete(currentPoint: Step): Unit = {
        if (0 < logEvery && (0 == currentPoint.iteration % logEvery || currentPoint.iteration < logEvery)) {
          val image = currentImage()
          timelineAnimation += image
          val caption = "Iteration " + currentPoint.iteration
          out.p(caption + "\n" + out.jpg(image, caption))
        }
        BasicOptimizer.this.onStepComplete(trainable.addRef().asInstanceOf[Trainable], currentPoint)
        trainingMonitor.onStepComplete(currentPoint)
        super.onStepComplete(currentPoint)
      }
    })
    trainer.setTimeout(trainingMinutes, TimeUnit.MINUTES)
    trainer.setMaxIterations(trainingIterations)
    trainer.setLineSearchFactory((_: CharSequence) => lineSearchInstance)
    trainer.setTerminateThreshold(java.lang.Double.NEGATIVE_INFINITY)
    val result = trainer.run.asInstanceOf[lang.Double]
    trainer.freeRef()
    result
Logging
Reset training subject: 137392048724000
Reset training subject: 137392972098500
Adding measurement 612f5bee to history. Total: 0
LBFGS Accumulation History: 1 points
Constructing line search parameters: GD+Trust
th(0)=-2.167605574180171;dx=-6.065414637624249E-4
New Minimum: -2.167605574180171 > -2.168992022113695
WOLFE (weak): th(2.154434690031884)=-2.168992022113695; dx=-6.069636801267519E-4 evalInputDelta=0.0013864479335241597
New Minimum: -2.168992022113695 > -2.170378577912185
WOLFE (weak): th(4.308869380063768)=-2.170378577912185; dx=-6.053806885119077E-4 evalInputDelta=0.0027730037320141676
New Minimum: -2.170378577912185 > -2.175929443233768
WOLFE (weak): th(12.926608140191302)=-2.175929443233768; dx=-6.076806928913198E-4 evalInputDelta=0.008323869053596944
New Minimum: -2.175929443233768 > -2.2009674218239255
WOLFE (weak): th(51.70643256076521)=-2.2009674218239255; dx=-6.094522585076002E-4 evalInputDelta=0.033361847643754494
New Minimum: -2.2009674218239255 > -2.3366431441961044
WOLFE (weak): th(258.53216280382605)=-2.3366431441961044; dx=-6.268560178458836E-4 evalInputDelta=0.16903757001593345
New Minimum: -2.3366431441961044 > -3.2589848584880396
WOLFE (weak): th(1551.1929768229563)=-3.2589848584880396; dx=-6.916729566468268E-4 evalInputDelta=1.0913792843078687
New Minimum: -3.2589848584880396 > -9.921594999862197
WOLFE (weak): th(10858.350837760694)=-9.921594999862197; dx=-5.568023146065918E-4 evalInputDelta=7.753989425682026
New Minimum: -9.921594999862197 > -16.39641216417538
END: th(86866.80670208555)=-16.39641216417538; dx=-3.863317293043962E-5 evalInputDelta=14.228806589995209
Fitness changed from -2.167605574180171 to -16.39641216417538
Iteration 1 complete. Error: -16.39641216417538 Total: 10.8595; Orientation: 0.0147; Line Search: 8.2349
<a id="p-3"></a>Iteration 1
<a id="p-2"></a>![Iteration 1](etc/3628874b-707b-4003-abbf-15bab30345e2.jpg)
Adding measurement 4b5bd081 to history. Total: 1
LBFGS Accumulation History: 2 points
th(0)=-16.39641216417538;dx=-0.0014624786852295915
New Minimum: -16.39641216417538 > -22.744100997351275
WOLF (strong): th(187148.86177126726)=-22.744100997351275; dx=1.9563900260884126E-5 evalInputDelta=6.347688833175894
New Minimum: -22.744100997351275 > -31.96339461728481
WOLF (strong): th(93574.43088563363)=-31.96339461728481; dx=1.9431774562844457E-5 evalInputDelta=15.566982453109429
New Minimum: -31.96339461728481 > -39.10516568339171
END: th(31191.476961877877)=-39.10516568339171; dx=-1.9944089996177467E-4 evalInputDelta=22.70875351921633
Fitness changed from -16.39641216417538 to -39.10516568339171
Iteration 2 complete. Error: -39.10516568339171 Total: 4.7224; Orientation: 0.0149; Line Search: 3.7217
<a id="p-5"></a>Iteration 2
<a id="p-4"></a>![Iteration 2](etc/73c26ab0-e905-4ef5-ab4b-fec086726521.jpg)
Adding measurement 45502ba2 to history. Total: 2
LBFGS Accumulation History: 3 points
th(0)=-39.10516568339171;dx=-0.0015848083314812253
New Minimum: -39.10516568339171 > -59.157026889524
WOLF (strong): th(67200.00000000001)=-59.157026889524; dx=2.7651496456941715E-5 evalInputDelta=20.051861206132287
New Minimum: -59.157026889524 > -63.46614822151705
END: th(33600.00000000001)=-63.46614822151705; dx=-1.9716439274341607E-4 evalInputDelta=24.36098253812534
Fitness changed from -39.10516568339171 to -63.46614822151705
Iteration 3 complete. Error: -63.46614822151705 Total: 3.6202; Orientation: 0.0148; Line Search: 2.6213
<a id="p-7"></a>Iteration 3
<a id="p-6"></a>![Iteration 3](etc/d0ff585c-2484-42a6-b080-019359f39562.jpg)
Adding measurement 2ace6a71 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 8.647e+03, gradient 4.355e-02, dot -0.382; [60009d48-ae44-454f-bbc3-9da6bee1450d = 1.000/1.000e+00]
Orientation rejected. Popping history element from -63.46614822151705, -39.10516568339171, -16.39641216417538, -2.167605574180171
LBFGS Accumulation History: 3 points
Removed measurement 2ace6a71 to history. Total: 3
th(0)=-63.46614822151705;dx=-0.0018902018377959418
New Minimum: -63.46614822151705 > -72.25472712892525
WOLF (strong): th(72389.00558507131)=-72.25472712892525; dx=1.5703772827577737E-4 evalInputDelta=8.788578907408201
New Minimum: -72.25472712892525 > -84.17572124308035
END: th(36194.502792535655)=-84.17572124308035; dx=-5.6937186792925014E-5 evalInputDelta=20.709573021563294
Fitness changed from -63.46614822151705 to -84.17572124308035
Iteration 4 complete. Error: -84.17572124308035 Total: 4.1764; Orientation: 0.2835; Line Search: 2.9337
<a id="p-9"></a>Iteration 4
<a id="p-8"></a>![Iteration 4](etc/8c531c94-96f9-4df6-9d76-72748a486b5e.jpg)
Adding measurement 1659da46 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.467e+04, gradient 4.596e-02, dot -0.358; [60009d48-ae44-454f-bbc3-9da6bee1450d = 1.000/1.000e+00]
Orientation rejected. Popping history element from -84.17572124308035, -39.10516568339171, -16.39641216417538, -2.167605574180171
LBFGS Accumulation History: 3 points
Removed measurement 1659da46 to history. Total: 3
th(0)=-84.17572124308035;dx=-0.0021041139755394026
Armijo: th(77978.69240469471)=-78.79728752141241; dx=2.522576881783353E-4 evalInputDelta=-5.378433721667932
New Minimum: -84.17572124308035 > -106.16781115876259
WOLF (strong): th(38989.346202347355)=-106.16781115876259; dx=1.8124733661181098E-4 evalInputDelta=21.992089915682243
New Minimum: -106.16781115876259 > -106.83390911468038
END: th(12996.448734115786)=-106.83390911468038; dx=-9.639771007508351E-4 evalInputDelta=22.658187871600035
Fitness changed from -84.17572124308035 to -106.83390911468038
Iteration 5 complete. Error: -106.83390911468038 Total: 4.8401; Orientation: 0.2781; Line Search: 3.6264
<a id="p-11"></a>Iteration 5
<a id="p-10"></a>![Iteration 5](etc/0fdccfdd-d317-41b1-ae18-6b39c2c10632.jpg)
Adding measurement 3061ada4 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.436e+04, gradient 3.707e-02, dot -0.442; [60009d48-ae44-454f-bbc3-9da6bee1450d = 1.000/1.000e+00]
Orientation rejected. Popping history element from -106.83390911468038, -39.10516568339171, -16.39641216417538, -2.167605574180171
LBFGS Accumulation History: 3 points
Removed measurement 3061ada4 to history. Total: 3
th(0)=-106.83390911468038;dx=-0.0013709379985334482
New Minimum: -106.83390911468038 > -129.22150990422736
END: th(28000.00000000001)=-129.22150990422736; dx=-4.8391067768429724E-4 evalInputDelta=22.38760078954698
Fitness changed from -106.83390911468038 to -129.22150990422736
Iteration 6 complete. Error: -129.22150990422736 Total: 3.3149; Orientation: 0.2903; Line Search: 1.9772
Adding measurement 5129fb13 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 4.289e+04, gradient 4.291e-02, dot -0.393; [60009d48-ae44-454f-bbc3-9da6bee1450d = 1.000/1.000e+00]
Orientation rejected. Popping history element from -129.22150990422736, -39.10516568339171, -16.39641216417538, -2.167605574180171
LBFGS Accumulation History: 3 points
Removed measurement 5129fb13 to history. Total: 3
th(0)=-129.22150990422736;dx=-0.0018369263576001142
Armijo: th(60324.17132089277)=-128.10545235196258; dx=1.6310584821017541E-4 evalInputDelta=-1.1160575522647775
New Minimum: -129.22150990422736 > -143.46019455147888
END: th(30162.085660446384)=-143.46019455147888; dx=-3.636067767002199E-5 evalInputDelta=14.238684647251517
Fitness changed from -129.22150990422736 to -143.46019455147888
Iteration 7 complete. Error: -143.46019455147888 Total: 3.7377; Orientation: 0.2759; Line Search: 2.6299
Adding measurement 1d7bc28b to history. Total: 3
Rejected: LBFGS Orientation magnitude: 6.610e+04, gradient 4.948e-02, dot -0.344; [60009d48-ae44-454f-bbc3-9da6bee1450d = 1.000/1.000e+00]
Orientation rejected. Popping history element from -143.46019455147888, -39.10516568339171, -16.39641216417538, -2.167605574180171
LBFGS Accumulation History: 3 points
Removed measurement 1d7bc28b to history. Total: 3
th(0)=-143.46019455147888;dx=-0.002430433360466254
Armijo: th(64982.24367057894)=-131.98627723718428; dx=4.406135890055703E-4 evalInputDelta=-11.473917314294596
New Minimum: -143.46019455147888 > -162.7389467486488
WOLF (strong): th(32491.12183528947)=-162.7389467486488; dx=2.1930601348806616E-4 evalInputDelta=19.278752197169922
New Minimum: -162.7389467486488 > -165.21688127382382
END: th(10830.37394509649)=-165.21688127382382; dx=-0.0010449309495270931 evalInputDelta=21.756686722344938
Fitness changed from -143.46019455147888 to -165.21688127382382
Iteration 8 complete. Error: -165.21688127382382 Total: 4.6683; Orientation: 0.2851; Line Search: 3.5450
Adding measurement d415940 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.416e+05, gradient 3.803e-02, dot -0.441; [60009d48-ae44-454f-bbc3-9da6bee1450d = 1.000/1.000e+00]
Orientation rejected. Popping history element from -165.21688127382382, -39.10516568339171, -16.39641216417538, -2.167605574180171
LBFGS Accumulation History: 3 points
Removed measurement d415940 to history. Total: 3
th(0)=-165.21688127382382;dx=-0.0014398792939530618
New Minimum: -165.21688127382382 > -184.48943688069735
END: th(23333.333333333347)=-184.48943688069735; dx=-6.095194822925648E-4 evalInputDelta=19.27255560687354
Fitness changed from -165.21688127382382 to -184.48943688069735
Iteration 9 complete. Error: -184.48943688069735 Total: 3.2136; Orientation: 0.3421; Line Search: 2.0268
Adding measurement 7911b4e5 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.605e+05, gradient 4.049e-02, dot -0.429; [60009d48-ae44-454f-bbc3-9da6bee1450d = 1.000/1.000e+00]
Orientation rejected. Popping history element from -184.48943688069735, -39.10516568339171, -16.39641216417538, -2.167605574180171
LBFGS Accumulation History: 3 points
Removed measurement 7911b4e5 to history. Total: 3
th(0)=-184.48943688069735;dx=-0.001632921991210318
New Minimum: -184.48943688069735 > -196.42691125041927
END: th(50270.14276741065)=-196.42691125041927; dx=-7.593191853713396E-5 evalInputDelta=11.937474369721912
Fitness changed from -184.48943688069735 to -196.42691125041927
Iteration 10 complete. Error: -196.42691125041927 Total: 2.8689; Orientation: 0.2772; Line Search: 1.7541
<a id="p-13"></a>Iteration 10
<a id="p-12"></a>![Iteration 10](etc/092c63c3-5d6d-4d68-9409-59b3aa354c76.jpg)
Final threshold in iteration 11: -196.42691125041927 (> -Infinity) after 46.128s (< 5400.000s)

Returns

    -196.42691125041927