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

Code from BasicOptimizer.scala:75 executed in 115.81 seconds (1.833 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: 900054130309900
    Reset training subject: 900055123212500
    Adding measurement 452ec287 to history. Total: 0
    LBFGS Accumulation History: 1 points
    Constructing line search parameters: GD+Trust
    th(0)=1.4620341956615448;dx=-3.302801116576718E-7
    New Minimum: 1.4620341956615448 > 1.4620337039232254
    WOLFE (weak): th(2.154434690031884)=1.4620337039232254; dx=-3.3028131151048744E-7 evalInputDelta=4.917383193969727E-7
    New Minimum: 1.4620337039232254 > 1.4620329588651657
    WOLFE (weak): th(4.308869380063768)=1.4620329588651657; dx=-3.302810962838615E-7 evalInputDelta=1.2367963790893555E-6
    New Minimum: 1.4620329588651657 > 1.4620305001735687
    WOLFE (weak): th(12.926608140191302)=1.4620305001735687; dx=-3.302810772901591E-7 evalInputDelta=3.6954879760742188E-6
    New Minimum: 1.4620305001735687 > 1.4620198458433151
    WOLFE (weak): th(51.70643256076521)=1.4620198458433151; dx=-3.302760928148587E-7 evalInputDelta=1.4349818229675293E-5
    New Minimum: 1.4620198458433151 > 1.461962416768074
    WOLFE (weak): th(258.53216280382605)=1.461962416768074; dx=-3.302578571064784E-7 evalInputDelta=7.177889347076416E-5
    New Minimum: 1.461962416768074 > 1.4616042077541351
    WOLFE (weak): th(1551.1929768229563)=1.4616042077541351; dx=-3.306390732095289E-7 evalInputDelta=4.2998790740966797E-4
    New Minimum: 1.4616042077541351 > 1.459037721157074
    WOLFE (weak): th(10858.350837760694)=1.459037721157074; dx=-3.2911300688992205E-7 evalInputDelta=0.002996474504470825
    New Minimum: 1.459037721157074 > 1.438677579164505
    WOLFE (weak): th(86866.80670208555)=1.438677579164505; dx=-3.199228655429477E-7 evalInputDelta=0.023356616497039795
    New Minimum: 1.438677579164505 > 1.3061667382717133
    END: th(781801.26031877)=1.3061667382717133; dx=-2.1357542815952788E-7 evalInputDelta=0.15586745738983154
    Fitness changed from 1.4620341956615448 to 1.3061667382717133
    Iteration 1 complete. Error: 1.3061667382717133 Total: 13.2788; Orientation: 0.0150; Line Search: 10.2748
    <a id="p-3"></a>Iteration 1
    <a id="p-2"></a>![Iteration 1](etc/dbb2e736-

...skipping 19943 bytes...

    8ff1 to history. Total: 3
    Rejected: LBFGS Orientation magnitude: 2.506e+03, gradient 4.335e-05, dot -0.696; [a13f0abe-45b5-46cb-a186-a1d80936ea8c = 1.000/1.000e+00]
    Orientation rejected. Popping history element from -0.2109748125076294, -0.22959448397159576, -0.2352561503648758, -0.23934021592140198
    LBFGS Accumulation History: 3 points
    Removed measurement 40b01718 to history. Total: 4
    th(0)=-0.23934021592140198;dx=-1.879439130098054E-9
    Armijo: th(8.203125000000007E7)=-0.20492437481880188; dx=2.6187891149998234E-11 evalInputDelta=-0.0344158411026001
    New Minimum: -0.23934021592140198 > -0.24319112300872803
    END: th(4.101562500000004E7)=-0.24319112300872803; dx=-4.785687666298924E-10 evalInputDelta=0.00385090708732605
    Fitness changed from -0.23934021592140198 to -0.24319112300872803
    Iteration 24 complete. Error: -0.24319112300872803 Total: 4.3587; Orientation: 0.4095; Line Search: 2.9818
    Adding measurement 3ee68377 to history. Total: 3
    Rejected: LBFGS Orientation magnitude: 2.500e+03, gradient 4.476e-05, dot -0.654; [a13f0abe-45b5-46cb-a186-a1d80936ea8c = 1.000/1.000e+00]
    Orientation rejected. Popping history element from -0.22959448397159576, -0.2352561503648758, -0.23934021592140198, -0.24319112300872803
    LBFGS Accumulation History: 3 points
    Removed measurement 1f12d5e0 to history. Total: 4
    th(0)=-0.24319112300872803;dx=-2.0036202972524417E-9
    Armijo: th(8.836548533333907E7)=-0.19426393508911133; dx=2.1599074871407665E-10 evalInputDelta=-0.0489271879196167
    New Minimum: -0.24319112300872803 > -0.2452404499053955
    END: th(4.418274266666953E7)=-0.2452404499053955; dx=-3.4052622221177666E-10 evalInputDelta=0.0020493268966674805
    Fitness changed from -0.24319112300872803 to -0.2452404499053955
    Iteration 25 complete. Error: -0.2452404499053955 Total: 4.4287; Orientation: 0.4369; Line Search: 3.0162
    <a id="p-19"></a>Iteration 25
    <a id="p-18"></a>![Iteration 25](etc/d8fe3cf4-d954-4c37-afc3-94982bf39145.jpg)
    
    Final threshold in iteration 26: -0.2452404499053955 (> -Infinity) after 115.811s (< 3600.000s)
    

Returns:

    -0.2452404499053955