Iteration 1 Iteration 1

Iteration 2 Iteration 2

Iteration 3 Iteration 3

Iteration 4 Iteration 4

Iteration 5 Iteration 5

Iteration 10 Iteration 10

Iteration 15 Iteration 15

Iteration 20 Iteration 20

Code from BasicOptimizer.scala:75 executed in 198.22 seconds (5.502 gc):

    val lineSearchInstance: LineSearchStrategy = lineSearchFactory
    IterativeTrainer.wrap(trainable)
      .setOrientation(orientation())
      .setMonitor(new TrainingMonitor() {
        override def clear(): Unit = trainingMonitor.clear()
  
        override def log(msg: String): Unit = trainingMonitor.log(msg)
  
        override def onStepFail(currentPoint: Step): Boolean = {
          BasicOptimizer.this.onStepFail(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, currentPoint)
          trainingMonitor.onStepComplete(currentPoint)
          super.onStepComplete(currentPoint)
        }
      })
      .setTimeout(trainingMinutes, TimeUnit.MINUTES)
      .setMaxIterations(trainingIterations)
      .setLineSearchFactory((_: CharSequence) => lineSearchInstance)
      .setTerminateThreshold(java.lang.Double.NEGATIVE_INFINITY)
      .runAndFree
      .asInstanceOf[lang.Double]

Logging:

    Reset training subject: 1405952707820700
    Reset training subject: 1405955782923500
    Adding measurement 438c9aa7 to history. Total: 0
    LBFGS Accumulation History: 1 points
    Constructing line search parameters: GD+Trust
    th(0)=20.690632916986942;dx=-6.753755270699263E-4
    New Minimum: 20.690632916986942 > 20.689790536649525
    WOLFE (weak): th(2.154434690031884)=20.689790536649525; dx=-6.750042616524085E-4 evalInputDelta=8.423803374171257E-4
    New Minimum: 20.689790536649525 > 20.688947421498597
    WOLFE (weak): th(4.308869380063768)=20.688947421498597; dx=-6.750654943262201E-4 evalInputDelta=0.001685495488345623
    New Minimum: 20.688947421498597 > 20.685581978410482
    WOLFE (weak): th(12.926608140191302)=20.685581978410482; dx=-6.737202938473409E-4 evalInputDelta=0.005050938576459885
    New Minimum: 20.685581978410482 > 20.67056882660836
    WOLFE (weak): th(51.70643256076521)=20.67056882660836; dx=-6.632398369194096E-4 evalInputDelta=0.020064090378582478
    New Minimum: 20.67056882660836 > 20.583908481523395
    WOLFE (weak): th(258.53216280382605)=20.583908481523395; dx=-6.154682299913871E-4 evalInputDelta=0.1067244354635477
    New Minimum: 20.583908481523395 > 20.140518100000918
    END: th(1551.1929768229563)=20.140518100000918; dx=-5.212826780768253E-4 evalInputDelta=0.5501148169860244
    Fitness changed from 20.690632916986942 to 20.140518100000918
    Iteration 1 complete. Error: 20.140518100000918 Total: 28.3833; Orientation: 0.0146; Line Search: 19.9097
    <a id="p-3"></a>Iteration 1
    <a id="p-2"></a>![Iteration 1](etc/c25763f3-d16c-4dc5-8afc-bb04b533b632.jpg)
    
    Adding measurement 64387c17 to history. Total: 1
    LBFGS Accumulation History: 2 points
    th(0)=20.140518100000918;dx=-5.428608572981442E-4
    New Minimum: 20.140518100000918 > 19.319032229483128
    END: th(3341.943960201201)=19.319032229483128; dx=-3.9057374955211825E-4 evalInputDelta=0.8214858705177903
    Fitness changed from 20.140518100000918 to 19.319032229483128
    Iteration 2 complete. Error: 19.319032229483128 Total: 7.7076; Orientation: 0.0042; Line Search: 5.0591
    <a id="p-5"><

...skipping 14234 bytes...

    ing measurement 5b251fb9 to history. Total: 3
    Rejected: LBFGS Orientation magnitude: 1.369e+03, gradient 1.796e-03, dot -0.621; [3bd93ac3-7f7a-40a6-bd87-7c43e77e2773 = 1.000/1.000e+00]
    Orientation rejected. Popping history element from 6.491687893867493, 6.38591093569994, 6.251383297145367, 6.1422571167349815
    LBFGS Accumulation History: 3 points
    Removed measurement 160e99e0 to history. Total: 4
    th(0)=6.1422571167349815;dx=-3.225231412598838E-6
    Armijo: th(448840.56042330945)=6.265633948147297; dx=1.7199714932082707E-6 evalInputDelta=-0.12337683141231537
    New Minimum: 6.1422571167349815 > 6.077984690666199
    WOLF (strong): th(224420.28021165472)=6.077984690666199; dx=9.94788584893631E-7 evalInputDelta=0.0642724260687828
    New Minimum: 6.077984690666199 > 6.062078006565571
    END: th(74806.76007055158)=6.062078006565571; dx=-1.174368157987777E-6 evalInputDelta=0.0801791101694107
    Fitness changed from 6.1422571167349815 to 6.062078006565571
    Iteration 19 complete. Error: 6.062078006565571 Total: 12.2708; Orientation: 0.0912; Line Search: 9.9016
    Adding measurement 35eee641 to history. Total: 3
    Rejected: LBFGS Orientation magnitude: 1.361e+03, gradient 1.239e-03, dot -0.856; [3bd93ac3-7f7a-40a6-bd87-7c43e77e2773 = 1.000/1.000e+00]
    Orientation rejected. Popping history element from 6.38591093569994, 6.251383297145367, 6.1422571167349815, 6.062078006565571
    LBFGS Accumulation History: 3 points
    Removed measurement 2ba42204 to history. Total: 4
    th(0)=6.062078006565571;dx=-1.535131670880564E-6
    New Minimum: 6.062078006565571 > 5.968041889369488
    END: th(161166.2789448883)=5.968041889369488; dx=-1.0319009542897557E-6 evalInputDelta=0.09403611719608307
    Fitness changed from 6.062078006565571 to 5.968041889369488
    Iteration 20 complete. Error: 5.968041889369488 Total: 7.0974; Orientation: 0.0915; Line Search: 4.7072
    <a id="p-17"></a>Iteration 20
    <a id="p-16"></a>![Iteration 20](etc/c80b1133-b3eb-44d5-a29e-af77e2954a7f.jpg)
    
    Final threshold in iteration 21: 5.968041889369488 (> -Infinity) after 198.205s (< 3600.000s)
    

Returns:

    5.968041889369488