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 299.97 seconds (7.025 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: 585778578853400
Reset training subject: 585784587705300
Adding measurement 664499df to history. Total: 0
LBFGS Accumulation History: 1 points
Constructing line search parameters: GD+Trust
th(0)=-39.838444873968626;dx=-2.057325553109996E-6
New Minimum: -39.838444873968626 > -39.8384467698069
END: th(2.154434690031884)=-39.8384467698069; dx=-1.7962777268535288E-6 evalInputDelta=1.8958382739242552E-6
Fitness changed from -39.838444873968626 to -39.8384467698069
Iteration 1 complete. Error: -39.8384467698069 Total: 30.3697; Orientation: 0.1439; Line Search: 12.3061
<a id="p-3"></a>Iteration 1
<a id="p-2"></a>![Iteration 1](etc/f3d03e26-7462-44e9-a439-2c937ef3cad9.jpg)
Adding measurement 3fe12b43 to history. Total: 1
LBFGS Accumulation History: 2 points
th(0)=-39.8384467698069;dx=-1.7939012897329205E-6
New Minimum: -39.8384467698069 > -39.83845624899689
WOLFE (weak): th(4.641588833612779)=-39.83845624899689; dx=-1.7925096307583183E-6 evalInputDelta=9.479189991168369E-6
New Minimum: -39.83845624899689 > -39.83846572818462
WOLFE (weak): th(9.283177667225559)=-39.83846572818462; dx=-1.7915445321225063E-6 evalInputDelta=1.8958377722810837E-5
New Minimum: -39.83846572818462 > -39.83850364491302
WOLFE (weak): th(27.849533001676676)=-39.83850364491302; dx=-1.790395690732856E-6 evalInputDelta=5.687510611807056E-5
New Minimum: -39.83850364491302 > -39.8386685822616
WOLFE (weak): th(111.3981320067067)=-39.8386685822616; dx=-1.7901753613634166E-6 evalInputDelta=2.218124546971012E-4
New Minimum: -39.8386685822616 > -39.83954823658816
WOLFE (weak): th(556.9906600335335)=-39.83954823658816; dx=-1.7896433178627358E-6 evalInputDelta=0.001101466781257443
New Minimum: -39.83954823658816 > -39.84504753166844
WOLFE (weak): th(3341.9439602012008)=-39.84504753166844; dx=-1.78960145595401E-6 evalInputDelta=0.006600761861541571
New Minimum: -39.84504753166844 > -39.884623481468296
WOLFE (weak): th(23393.607721408407)=-39.884623481468296; dx=-1.7876131203773597E-6 evalInputDelta=0.046176711661395586
New Minimum: -39.884623481468296 > -40.205746250942305
WOLFE (weak): th(187148.86177126726)=-40.205746250942305; dx=-1.7662397139845298E-6 evalInputDelta=0.36729948113540445
New Minimum: -40.205746250942305 > -42.93826728638561
END: th(1684339.7559414054)=-42.93826728638561; dx=-1.5329865252550635E-6 evalInputDelta=3.09982051657871
Fitness changed from -39.8384467698069 to -42.93826728638561
Iteration 2 complete. Error: -42.93826728638561 Total: 67.7786; Orientation: 0.1365; Line Search: 60.4627
<a id="p-5"></a>Iteration 2
<a id="p-4"></a>![Iteration 2](etc/e400ecd2-3166-4916-8062-323fe97da546.jpg)
Adding measurement 47b28b54 to history. Total: 2
LBFGS Accumulation History: 3 points
th(0)=-42.93826728638561;dx=-1.4701187407166787E-6
New Minimum: -42.93826728638561 > -47.78326203964814
END: th(3628800.0000000005)=-47.78326203964814; dx=-9.880822044191989E-7 evalInputDelta=4.844994753262533
Fitness changed from -42.93826728638561 to -47.78326203964814
Iteration 3 complete. Error: -47.78326203964814 Total: 19.6236; Orientation: 0.1219; Line Search: 12.4910
<a id="p-7"></a>Iteration 3
<a id="p-6"></a>![Iteration 3](etc/64508800-2b04-4cf6-bd30-7ecb24b62aba.jpg)
Adding measurement 6664a954 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.138e+04, gradient 9.746e-04, dot -0.812; [8bc84f24-5093-4f6e-ace6-11eeec8989f9 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -47.78326203964814, -42.93826728638561, -39.8384467698069, -39.838444873968626
LBFGS Accumulation History: 3 points
Removed measurement 6664a954 to history. Total: 3
th(0)=-47.78326203964814;dx=-9.480725555528985E-7
New Minimum: -47.78326203964814 > -53.96335294318392
END: th(7818012.603187701)=-53.96335294318392; dx=-5.181417441976147E-7 evalInputDelta=6.180090903535778
Fitness changed from -47.78326203964814 to -53.96335294318392
Iteration 4 complete. Error: -53.96335294318392 Total: 22.1375; Orientation: 2.4928; Line Search: 12.4728
<a id="p-9"></a>Iteration 4
<a id="p-8"></a>![Iteration 4](etc/869c39c0-f01b-4ba6-8ed3-138a75157907.jpg)
Adding measurement 40101fe4 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.002e+04, gradient 8.424e-04, dot -0.602; [8bc84f24-5093-4f6e-ace6-11eeec8989f9 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -53.96335294318392, -42.93826728638561, -39.8384467698069, -39.838444873968626
LBFGS Accumulation History: 3 points
Removed measurement 40101fe4 to history. Total: 3
th(0)=-53.96335294318392;dx=-7.078816082814012E-7
New Minimum: -53.96335294318392 > -60.39558688159281
END: th(1.6843397559414055E7)=-60.39558688159281; dx=-1.5438758708751256E-7 evalInputDelta=6.432233938408892
Fitness changed from -53.96335294318392 to -60.39558688159281
Iteration 5 complete. Error: -60.39558688159281 Total: 22.2089; Orientation: 2.5186; Line Search: 12.5978
<a id="p-11"></a>Iteration 5
<a id="p-10"></a>![Iteration 5](etc/45495d78-a2ca-4679-b513-ccf39aa35643.jpg)
Adding measurement 71c3985e to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.206e+04, gradient 9.983e-04, dot -0.339; [8bc84f24-5093-4f6e-ace6-11eeec8989f9 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -60.39558688159281, -42.93826728638561, -39.8384467698069, -39.838444873968626
LBFGS Accumulation History: 3 points
Removed measurement 71c3985e to history. Total: 3
th(0)=-60.39558688159281;dx=-9.945214935742616E-7
Armijo: th(3.628800000000001E7)=-57.828717246317744; dx=2.438968845522959E-7 evalInputDelta=-2.5668696352750686
New Minimum: -60.39558688159281 > -63.71505177854606
WOLF (strong): th(1.8144000000000004E7)=-63.71505177854606; dx=2.58190722626934E-7 evalInputDelta=3.3194648969532494
New Minimum: -63.71505177854606 > -64.89773555121839
END: th(6048000.000000001)=-64.89773555121839; dx=-3.359384204933897E-7 evalInputDelta=4.502148669625576
Fitness changed from -60.39558688159281 to -64.89773555121839
Iteration 6 complete. Error: -64.89773555121839 Total: 35.0928; Orientation: 2.4890; Line Search: 25.3597
Adding measurement 3ecb5877 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.997e+04, gradient 7.092e-04, dot -0.613; [8bc84f24-5093-4f6e-ace6-11eeec8989f9 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -64.89773555121839, -42.93826728638561, -39.8384467698069, -39.838444873968626
LBFGS Accumulation History: 3 points
Removed measurement 3ecb5877 to history. Total: 3
th(0)=-64.89773555121839;dx=-5.023196103963907E-7
New Minimum: -64.89773555121839 > -69.18012899120916
END: th(1.3030021005312836E7)=-69.18012899120916; dx=-1.6641715673751925E-7 evalInputDelta=4.28239343999077
Fitness changed from -64.89773555121839 to -69.18012899120916
Iteration 7 complete. Error: -69.18012899120916 Total: 20.6700; Orientation: 2.4602; Line Search: 12.2660
Adding measurement 55793be8 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.592e+04, gradient 8.185e-04, dot -0.493; [8bc84f24-5093-4f6e-ace6-11eeec8989f9 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -69.18012899120916, -42.93826728638561, -39.8384467698069, -39.838444873968626
LBFGS Accumulation History: 3 points
Removed measurement 55793be8 to history. Total: 3
th(0)=-69.18012899120916;dx=-6.696321503035592E-7
New Minimum: -69.18012899120916 > -69.87610867455591
WOLF (strong): th(2.8072329265690096E7)=-69.87610867455591; dx=1.6161207327351306E-7 evalInputDelta=0.6959796833467493
New Minimum: -69.87610867455591 > -72.28733319964832
WOLF (strong): th(1.4036164632845048E7)=-72.28733319964832; dx=7.431194909460704E-8 evalInputDelta=3.107204208439157
END: th(4678721.544281683)=-71.71806369085239; dx=-3.164088115488208E-7 evalInputDelta=2.5379346996432304
Fitness changed from -69.18012899120916 to -72.28733319964832
Iteration 8 complete. Error: -72.28733319964832 Total: 33.2296; Orientation: 2.3949; Line Search: 24.7101
Adding measurement 592c07b9 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.685e+04, gradient 9.432e-04, dot -0.367; [8bc84f24-5093-4f6e-ace6-11eeec8989f9 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -72.28733319964832, -42.93826728638561, -39.8384467698069, -39.838444873968626
LBFGS Accumulation History: 3 points
Removed measurement 592c07b9 to history. Total: 3
th(0)=-72.28733319964832;dx=-8.873792356503693E-7
New Minimum: -72.28733319964832 > -77.1148982178815
WOLF (strong): th(1.0080000000000004E7)=-77.1148982178815; dx=3.751734910683048E-8 evalInputDelta=4.827565018233187
END: th(5040000.000000002)=-76.09179120657335; dx=-4.548387425511752E-7 evalInputDelta=3.8044580069250316
Fitness changed from -72.28733319964832 to -77.1148982178815
Iteration 9 complete. Error: -77.1148982178815 Total: 26.4428; Orientation: 2.3984; Line Search: 18.1144
Adding measurement 3d053c42 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.819e+04, gradient 7.456e-04, dot -0.513; [8bc84f24-5093-4f6e-ace6-11eeec8989f9 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -77.1148982178815, -42.93826728638561, -39.8384467698069, -39.838444873968626
LBFGS Accumulation History: 3 points
Removed measurement 3d053c42 to history. Total: 3
th(0)=-77.1148982178815;dx=-5.558419051998184E-7
New Minimum: -77.1148982178815 > -80.2653010170645
END: th(1.0858350837760698E7)=-80.2653010170645; dx=-2.7988342597247135E-8 evalInputDelta=3.1504027991829986
Fitness changed from -77.1148982178815 to -80.2653010170645
Iteration 10 complete. Error: -80.2653010170645 Total: 21.1560; Orientation: 2.4142; Line Search: 12.6963
<a id="p-13"></a>Iteration 10
<a id="p-12"></a>![Iteration 10](etc/6784b1d1-dbc1-4a98-b85f-5ab143e042dc.jpg)
Final threshold in iteration 11: -80.2653010170645 (> -Infinity) after 299.970s (< 5400.000s)

Returns

    -80.2653010170645