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 218.65 seconds (3.913 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: 692654572183600
Reset training subject: 692659198860000
Adding measurement 5e30f189 to history. Total: 0
LBFGS Accumulation History: 1 points
Constructing line search parameters: GD+Trust
th(0)=-1508.0114389486573;dx=-0.006799014840040083
New Minimum: -1508.0114389486573 > -1508.0271880838222
WOLFE (weak): th(2.154434690031884)=-1508.0271880838222; dx=-0.0066104937112344015 evalInputDelta=0.015749135164924155
New Minimum: -1508.0271880838222 > -1508.0429370545123
WOLFE (weak): th(4.308869380063768)=-1508.0429370545123; dx=-0.00661475771975555 evalInputDelta=0.03149810585500745
New Minimum: -1508.0429370545123 > -1508.1059312926263
WOLFE (weak): th(12.926608140191302)=-1508.1059312926263; dx=-0.006614044363431553 evalInputDelta=0.09449234396902284
New Minimum: -1508.1059312926263 > -1508.389372807963
WOLFE (weak): th(51.70643256076521)=-1508.389372807963; dx=-0.00661152494407272 evalInputDelta=0.37793385930558543
New Minimum: -1508.389372807963 > -1509.8999139015805
WOLFE (weak): th(258.53216280382605)=-1509.8999139015805; dx=-0.0066028705582973305 evalInputDelta=1.8884749529231613
New Minimum: -1509.8999139015805 > -1519.2902948416408
WOLFE (weak): th(1551.1929768229563)=-1519.2902948416408; dx=-0.006538129775151737 evalInputDelta=11.278855892983529
New Minimum: -1519.2902948416408 > -1583.618719894407
END: th(10858.350837760694)=-1583.618719894407; dx=-0.005963208084272708 evalInputDelta=75.60728094574961
Fitness changed from -1508.0114389486573 to -1583.618719894407
Iteration 1 complete. Error: -1583.618719894407 Total: 50.3024; Orientation: 0.1038; Line Search: 36.8606
<a id="p-3"></a>Iteration 1
<a id="p-2"></a>![Iteration 1](etc/8df9c657-68e3-4b19-a4ab-914f5b74030b.jpg)
Adding measurement 309ed1d9 to history. Total: 1
LBFGS Accumulation History: 2 points
th(0)=-1583.618719894407;dx=-0.005643280014422497
New Minimum: -1583.618719894407 > -1715.5547936454843
END: th(23393.607721408407)=-1715.5547936454843; dx=-0.0045762794360217065 evalInputDelta=131.9360737510774
Fitness changed from -1583.618719894407 to -1715.5547936454843
Iteration 2 complete. Error: -1715.5547936454843 Total: 14.5048; Orientation: 0.0917; Line Search: 8.9204
<a id="p-5"></a>Iteration 2
<a id="p-4"></a>![Iteration 2](etc/3b96d795-8a11-4150-a46d-64f7051fdf8c.jpg)
Adding measurement b52fa28 to history. Total: 2
LBFGS Accumulation History: 3 points
th(0)=-1715.5547936454843;dx=-0.004229540692674082
New Minimum: -1715.5547936454843 > -1912.8768909681564
END: th(50400.00000000001)=-1912.8768909681564; dx=-0.0029104148966586814 evalInputDelta=197.3220973226721
Fitness changed from -1715.5547936454843 to -1912.8768909681564
Iteration 3 complete. Error: -1912.8768909681564 Total: 14.6201; Orientation: 0.0940; Line Search: 8.9446
<a id="p-7"></a>Iteration 3
<a id="p-6"></a>![Iteration 3](etc/88e03184-677f-4d39-b113-5fe13c1007b9.jpg)
Adding measurement 5057d950 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.367e+04, gradient 5.353e-02, dot -0.861; [6418c884-2027-4b76-bf48-528c46cbb2da = 1.000/1.000e+00]
Orientation rejected. Popping history element from -1912.8768909681564, -1715.5547936454843, -1583.618719894407, -1508.0114389486573
LBFGS Accumulation History: 3 points
Removed measurement 5057d950 to history. Total: 3
th(0)=-1912.8768909681564;dx=-0.0028621804550930845
New Minimum: -1912.8768909681564 > -2170.05967659878
END: th(108583.50837760697)=-2170.05967659878; dx=-0.0016035405591048788 evalInputDelta=257.18278563062336
Fitness changed from -1912.8768909681564 to -2170.05967659878
Iteration 4 complete. Error: -2170.05967659878 Total: 16.9621; Orientation: 1.8382; Line Search: 9.4666
<a id="p-9"></a>Iteration 4
<a id="p-8"></a>![Iteration 4](etc/a0aa83d8-1d3a-4ea0-95dd-b5276d186388.jpg)
Adding measurement f51e97f to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.334e+04, gradient 4.950e-02, dot -0.669; [6418c884-2027-4b76-bf48-528c46cbb2da = 1.000/1.000e+00]
Orientation rejected. Popping history element from -2170.05967659878, -1715.5547936454843, -1583.618719894407, -1508.0114389486573
LBFGS Accumulation History: 3 points
Removed measurement f51e97f to history. Total: 3
th(0)=-2170.05967659878;dx=-0.0024446311815543662
New Minimum: -2170.05967659878 > -2429.1634362471373
END: th(233936.07721408413)=-2429.1634362471373; dx=-4.442439088923181E-4 evalInputDelta=259.1037596483575
Fitness changed from -2170.05967659878 to -2429.1634362471373
Iteration 5 complete. Error: -2429.1634362471373 Total: 17.0020; Orientation: 1.7956; Line Search: 9.5862
<a id="p-11"></a>Iteration 5
<a id="p-10"></a>![Iteration 5](etc/da84967b-2766-48c0-8cfe-2ebf064dd4b3.jpg)
Adding measurement 40673708 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.264e+04, gradient 5.821e-02, dot -0.393; [6418c884-2027-4b76-bf48-528c46cbb2da = 1.000/1.000e+00]
Orientation rejected. Popping history element from -2429.1634362471373, -1715.5547936454843, -1583.618719894407, -1508.0114389486573
LBFGS Accumulation History: 3 points
Removed measurement 40673708 to history. Total: 3
th(0)=-2429.1634362471373;dx=-0.0033743210727055347
Armijo: th(504000.0000000002)=-2349.2666940983945; dx=6.697739154001586E-4 evalInputDelta=-79.89674214874276
New Minimum: -2429.1634362471373 > -2561.885536084702
WOLF (strong): th(252000.0000000001)=-2561.885536084702; dx=5.949787543238883E-4 evalInputDelta=132.72209983756466
New Minimum: -2561.885536084702 > -2605.875956372444
END: th(84000.00000000003)=-2605.875956372444; dx=-7.493233177638401E-4 evalInputDelta=176.71252012530658
Fitness changed from -2429.1634362471373 to -2605.875956372444
Iteration 6 complete. Error: -2605.875956372444 Total: 26.3855; Orientation: 1.7299; Line Search: 18.8983
Adding measurement 6aa591e3 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.829e+04, gradient 4.611e-02, dot -0.513; [6418c884-2027-4b76-bf48-528c46cbb2da = 1.000/1.000e+00]
Orientation rejected. Popping history element from -2605.875956372444, -1715.5547936454843, -1583.618719894407, -1508.0114389486573
LBFGS Accumulation History: 3 points
Removed measurement 6aa591e3 to history. Total: 3
th(0)=-2605.875956372444;dx=-0.002121210564943206
New Minimum: -2605.875956372444 > -2759.07502616366
END: th(180972.5139626783)=-2759.07502616366; dx=-1.4217796277140956E-4 evalInputDelta=153.19906979121606
Fitness changed from -2605.875956372444 to -2759.07502616366
Iteration 7 complete. Error: -2759.07502616366 Total: 15.0470; Orientation: 1.6168; Line Search: 9.2103
Adding measurement 3c4758af to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.134e+04, gradient 5.693e-02, dot -0.393; [6418c884-2027-4b76-bf48-528c46cbb2da = 1.000/1.000e+00]
Orientation rejected. Popping history element from -2759.07502616366, -1715.5547936454843, -1583.618719894407, -1508.0114389486573
LBFGS Accumulation History: 3 points
Removed measurement 3c4758af to history. Total: 3
th(0)=-2759.07502616366;dx=-0.003239993544235999
Armijo: th(389893.4620234736)=-2644.672002347361; dx=8.2735395042511E-4 evalInputDelta=-114.40302381629908
New Minimum: -2759.07502616366 > -2846.162064956948
WOLF (strong): th(194946.7310117368)=-2846.162064956948; dx=7.400257484103854E-4 evalInputDelta=87.08703879328823
New Minimum: -2846.162064956948 > -2894.2733975904903
END: th(64982.24367057893)=-2894.2733975904903; dx=-7.326831128770478E-4 evalInputDelta=135.19837142683036
Fitness changed from -2759.07502616366 to -2894.2733975904903
Iteration 8 complete. Error: -2894.2733975904903 Total: 24.0418; Orientation: 1.5998; Line Search: 17.9961
Adding measurement 78668709 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.772e+04, gradient 4.075e-02, dot -0.565; [6418c884-2027-4b76-bf48-528c46cbb2da = 1.000/1.000e+00]
Orientation rejected. Popping history element from -2894.2733975904903, -1715.5547936454843, -1583.618719894407, -1508.0114389486573
LBFGS Accumulation History: 3 points
Removed measurement 78668709 to history. Total: 3
th(0)=-2894.2733975904903;dx=-0.0016549560478407587
New Minimum: -2894.2733975904903 > -3012.7824348930344
END: th(140000.00000000006)=-3012.7824348930344; dx=-3.7395121046870006E-4 evalInputDelta=118.50903730254413
Fitness changed from -2894.2733975904903 to -3012.7824348930344
Iteration 9 complete. Error: -3012.7824348930344 Total: 14.8863; Orientation: 1.6099; Line Search: 8.8486
Adding measurement 246743e4 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.057e+04, gradient 4.813e-02, dot -0.462; [6418c884-2027-4b76-bf48-528c46cbb2da = 1.000/1.000e+00]
Orientation rejected. Popping history element from -3012.7824348930344, -1715.5547936454843, -1583.618719894407, -1508.0114389486573
LBFGS Accumulation History: 3 points
Removed measurement 246743e4 to history. Total: 3
th(0)=-3012.7824348930344;dx=-0.002312214160852405
New Minimum: -3012.7824348930344 > -3013.6054818107827
WOLF (strong): th(301620.8566044639)=-3013.6054818107827; dx=5.156880266095707E-4 evalInputDelta=0.8230469177483428
New Minimum: -3013.6054818107827 > -3096.4253583769787
WOLF (strong): th(150810.42830223194)=-3096.4253583769787; dx=2.215351210776622E-4 evalInputDelta=83.64292348394429
END: th(50270.142767410645)=-3092.6721455724983; dx=-7.437581104300696E-4 evalInputDelta=79.88971067946386
Fitness changed from -3012.7824348930344 to -3096.4253583769787
Iteration 10 complete. Error: -3096.4253583769787 Total: 23.9427; Orientation: 1.6367; Line Search: 18.0734
<a id="p-13"></a>Iteration 10
<a id="p-12"></a>![Iteration 10](etc/db8f0fad-e90b-4a6f-a8f3-47434972dfe3.jpg)
Final threshold in iteration 11: -3096.4253583769787 (> -Infinity) after 218.651s (< 5400.000s)

Returns

    -3096.4253583769787