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

Iteration 25 Iteration 25

Iteration 30 Iteration 30

Code from BasicOptimizer.scala:75 executed in 929.23 seconds (7.536 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: 1026621622052500
    Reset training subject: 1026629420091400
    Adding measurement 7bfe20c2 to history. Total: 0
    LBFGS Accumulation History: 1 points
    Constructing line search parameters: GD+Trust
    th(0)=-1.078487016260624;dx=-2.9561984882139477E-7
    New Minimum: -1.078487016260624 > -1.0784877613186836
    WOLFE (weak): th(2.154434690031884)=-1.0784877613186836; dx=-2.955772495537606E-7 evalInputDelta=7.450580596923828E-7
    New Minimum: -1.0784877613186836 > -1.078488551080227
    WOLFE (weak): th(4.308869380063768)=-1.078488551080227; dx=-2.9573213616279595E-7 evalInputDelta=1.5348196029663086E-6
    New Minimum: -1.078488551080227 > -1.0784917250275612
    WOLFE (weak): th(12.926608140191302)=-1.0784917250275612; dx=-2.956219922078331E-7 evalInputDelta=4.708766937255859E-6
    New Minimum: -1.0784917250275612 > -1.0785061344504356
    WOLFE (weak): th(51.70643256076521)=-1.0785061344504356; dx=-2.9554989269035605E-7 evalInputDelta=1.9118189811706543E-5
    New Minimum: -1.0785061344504356 > -1.078582912683487
    WOLFE (weak): th(258.53216280382605)=-1.078582912683487; dx=-2.9561414663921616E-7 evalInputDelta=9.589642286300659E-5
    New Minimum: -1.078582912683487 > -1.0790621936321259
    WOLFE (weak): th(1551.1929768229563)=-1.0790621936321259; dx=-2.954559247757755E-7 evalInputDelta=5.751773715019226E-4
    New Minimum: -1.0790621936321259 > -1.0825061649084091
    WOLFE (weak): th(10858.350837760694)=-1.0825061649084091; dx=-2.944878472842857E-7 evalInputDelta=0.004019148647785187
    New Minimum: -1.0825061649084091 > -1.1101755052804947
    WOLFE (weak): th(86866.80670208555)=-1.1101755052804947; dx=-2.863688765497146E-7 evalInputDelta=0.03168848901987076
    New Minimum: -1.1101755052804947 > -1.3274809047579765
    END: th(781801.26031877)=-1.3274809047579765; dx=-2.1807029028451894E-7 evalInputDelta=0.2489938884973526
    Fitness changed from -1.078487016260624 to -1.3274809047579765
    Iteration 1 complete. Error: -1.3274809047579765 Total: 97.9862; Orientation: 0.0084; Line Search: 74.9753
    <a id="p-3"></a>Iteration 1
    <a id="p-2"><

...skipping 24673 bytes...

    adient 5.497e-05, dot -0.750; [3f6a01eb-a915-44bb-a241-fc0ac76c8427 = 1.000/1.000e+00]
    Orientation rejected. Popping history element from -2.7054023519158363, -2.710938546806574, -2.7149822786450386, -2.72100318223238
    LBFGS Accumulation History: 3 points
    Removed measurement 24743e3e to history. Total: 4
    th(0)=-2.72100318223238;dx=-3.013300088350683E-9
    Armijo: th(2.3503415679462884E7)=-2.637127224355936; dx=3.689728902540268E-9 evalInputDelta=-0.08387595787644386
    Armijo: th(1.1751707839731442E7)=-2.702749338001013; dx=2.0290000464645307E-9 evalInputDelta=-0.01825384423136711
    New Minimum: -2.72100318223238 > -2.7236282266676426
    END: th(3917235.946577147)=-2.7236282266676426; dx=-7.39431926796312E-10 evalInputDelta=0.00262504443526268
    Fitness changed from -2.72100318223238 to -2.7236282266676426
    Iteration 29 complete. Error: -2.7236282266676426 Total: 37.7381; Orientation: 0.2642; Line Search: 30.0627
    Adding measurement 1be7bab2 to history. Total: 3
    Rejected: LBFGS Orientation magnitude: 4.743e+03, gradient 5.601e-05, dot -0.702; [3f6a01eb-a915-44bb-a241-fc0ac76c8427 = 1.000/1.000e+00]
    Orientation rejected. Popping history element from -2.710938546806574, -2.7149822786450386, -2.72100318223238, -2.7236282266676426
    LBFGS Accumulation History: 3 points
    Removed measurement 7f7702f6 to history. Total: 4
    th(0)=-2.7236282266676426;dx=-3.1295220292913013E-9
    Armijo: th(8439429.012345688)=-2.7216476816684008; dx=-1.0916930647391574E-10 evalInputDelta=-0.001980544999241829
    New Minimum: -2.7236282266676426 > -2.725830126553774
    END: th(4219714.506172844)=-2.725830126553774; dx=-5.358540969832483E-10 evalInputDelta=0.0022018998861312866
    Fitness changed from -2.7236282266676426 to -2.725830126553774
    Iteration 30 complete. Error: -2.725830126553774 Total: 30.2285; Orientation: 0.2716; Line Search: 22.4894
    <a id="p-21"></a>Iteration 30
    <a id="p-20"></a>![Iteration 30](etc/dbe22167-b684-4d29-9fcb-6ea0bec48db9.jpg)
    
    Final threshold in iteration 31: -2.725830126553774 (> -Infinity) after 929.233s (< 3600.000s)
    

Returns:

    -2.725830126553774