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 203.54 seconds (1.974 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: 21331695421686
Reset training subject: 21336344266702
Adding measurement 6d1175fe to history. Total: 0
LBFGS Accumulation History: 1 points
Constructing line search parameters: GD+Trust
th(0)=-0.474764809012413;dx=-8.047811420205428E-7
New Minimum: -0.474764809012413 > -0.47476547956466675
END: th(2.154434690031884)=-0.47476547956466675; dx=-7.102428430605451E-7 evalInputDelta=6.705522537231445E-7
Fitness changed from -0.474764809012413 to -0.47476547956466675
Iteration 1 complete. Error: -0.47476547956466675 Total: 22.6629; Orientation: 0.0442; Line Search: 8.7557
<a id="p-3"></a>Iteration 1
<a id="p-2"></a>![Iteration 1](etc/f9c7413b-3b15-4681-bb21-4cb4729ce9d1.jpg)

    Adding measurement 5aaf1b24 to history. Total: 1
    LBFGS Accumulation History: 2 points
    th(0)=-0.47476547956466675;dx=-7.102422811958784E-7
    New Minimum: -0.47476547956466675 > -0.4747672975063324
    WOLFE (weak): th(4.641588833612779)=-0.4747672975063324; dx=-7.10241097468728E-7 evalInputDelta=1.817941665649414E-6
    New Minimum: -0.4747672975063324 > -0.474768802523613
    WOLFE (weak): th(9.283177667225559)=-0.474768802523613; dx=-7.102410203323185E-7 evalInputDelta=3.3229589462280273E-6
    New Minimum: -0.474768802523613 > -0.4747754782438278
    WOLFE (weak): th(27.849533001676676)=-0.4747754782438278; dx=-7.102418806807688E-7 evalInputDelta=9.998679161071777E-6
    New Minimum: -0.4747754782438278 > -0.4748050272464752
    WOLFE (weak): th(111.3981320067067)=-0.4748050272464752; dx=-7.102027945915561E-7 evalInputDelta=3.954768180847168E-5
    New Minimum: -0.4748050272464752 > -0.47496333718299866
    WOLFE (weak): th(556.9906600335335)=-0.47496333718299866; dx=-7.100567008692918E-7 evalInputDelta=1.9785761833190918E-4
    New Minimum: -0.47496333718299866 > -0.4759515970945358
    WOLFE (weak): th(3341.9439602012008)=-0.4759515970945358; dx=-7.09322898595412E-7 evalInputDelta=0.0011861175298690796
    New Minimum: -0.4759515970945358 > -0.48303548991680145
    WOLFE (weak): th(23393.607721408407)=-0.48303548991680145; dx=-7.037514246101964E-7 evalInputDelta=0.008270010352134705
    New Minimum: -0.48303548991680145 > -0.538677915930748
    WOLFE (weak): th(187148.86177126726)=-0.538677915930748; dx=-6.55283824486345E-7 evalInputDelta=0.06391243636608124
    New Minimum: -0.538677915930748 > -0.8716158717870712
    END: th(1684339.7559414054)=-0.8716158717870712; dx=-2.765860563806949E-7 evalInputDelta=0.3968503922224045
    Fitness changed from -0.47476547956466675 to -0.8716158717870712
    Iteration 2 complete. Error: -0.8716158717870712 Total: 47.6414; Orientation: 0.0455; Line Search: 43.3152
    <a id="p-5"></a>Iteration 2
    <a id="p-4"></a>![Iteration 2](etc/649f0f2c-e1a4-4eb5-a28f-84bd39181e8d.jpg)

    Adding measurement 6cbc7eb3 to history. Total: 2
    LBFGS Accumulation History: 3 points
    th(0)=-0.8716158717870712;dx=-2.861545042109191E-7
    New Minimum: -0.8716158717870712 > -1.2020770460367203
    END: th(3628800.0000000005)=-1.2020770460367203; dx=-1.0879975734720169E-7 evalInputDelta=0.33046117424964905
    Fitness changed from -0.8716158717870712 to -1.2020770460367203
    Iteration 3 complete. Error: -1.2020770460367203 Total: 13.2517; Orientation: 0.0454; Line Search: 9.0901
    <a id="p-7"></a>Iteration 3
    <a id="p-6"></a>![Iteration 3](etc/63bffce5-e5ef-4e81-89de-e27fe125c770.jpg)

    Adding measurement 14849e8a to history. Total: 3
    Rejected: LBFGS Orientation magnitude: 1.664e+03, gradient 3.954e-04, dot -0.562; [51b6f9f0-df62-4452-adcd-8e52fb4596b9 = 1.000/1.000e+00]
    Orientation rejected. Popping history element from -1.2020770460367203, -0.8716158717870712, -0.47476547956466675, -0.474764809012413
    LBFGS Accumulation History: 3 points
    Removed measurement 14849e8a to history. Total: 3
    th(0)=-1.2020770460367203;dx=-1.5636050376031067E-7
    New Minimum: -1.2020770460367203 > -1.486951231956482
    END: th(7818012.603187701)=-1.486951231956482; dx=-2.446909515842122E-8 evalInputDelta=0.28487418591976166
    Fitness changed from -1.2020770460367203 to -1.486951231956482
    Iteration 4 complete. Error: -1.486951231956482 Total: 14.2758; Orientation: 1.0229; Line Search: 8.9507
    <a id="p-9"></a>Iteration 4
    <a id="p-8"></a>![Iteration 4](etc/e6a42960-6824-4b4e-a0d2-6a1159a11602.jpg)

    Adding measurement 3ced9160 to history. Total: 3
    Rejected: LBFGS Orientation magnitude: 1.508e+03, gradient 3.672e-04, dot -0.334; [51b6f9f0-df62-4452-adcd-8e52fb4596b9 = 1.000/1.000e+00]
    Orientation rejected. Popping history element from -1.486951231956482, -0.8716158717870712, -0.47476547956466675, -0.474764809012413
    LBFGS Accumulation History: 3 points
    Removed measurement 3ced9160 to history. Total: 3
    th(0)=-1.486951231956482;dx=-1.3483559953259227E-7
    New Minimum: -1.486951231956482 > -1.5650223046541214
    WOLF (strong): th(1.6843397559414055E7)=-1.5650223046541214; dx=3.107968479991149E-8 evalInputDelta=0.07807107269763947
    New Minimum: -1.5650223046541214 > -1.6661564260721207
    WOLF (strong): th(8421698.779707028)=-1.6661564260721207; dx=9.362744904873972E-9 evalInputDelta=0.17920519411563873
    END: th(2807232.926569009)=-1.6159991323947906; dx=-5.520770820646072E-8 evalInputDelta=0.12904790043830872
    Fitness changed from -1.486951231956482 to -1.6661564260721207
    Iteration 5 complete. Error: -1.6661564260721207 Total: 22.8050; Orientation: 1.0093; Line Search: 17.2413
    <a id="p-11"></a>Iteration 5
    <a id="p-10"></a>![Iteration 5](etc/c897bcd4-0cd0-4952-a4fa-6490e5a14851.jpg)

    Adding measurement 256aa3f8 to history. Total: 3
    Rejected: LBFGS Orientation magnitude: 1.591e+03, gradient 3.227e-04, dot -0.276; [51b6f9f0-df62-4452-adcd-8e52fb4596b9 = 1.000/1.000e+00]
    Orientation rejected. Popping history element from -1.6661564260721207, -0.8716158717870712, -0.47476547956466675, -0.474764809012413
    LBFGS Accumulation History: 3 points
    Removed measurement 256aa3f8 to history. Total: 3
    th(0)=-1.6661564260721207;dx=-1.0413467786316766E-7
    New Minimum: -1.6661564260721207 > -1.8209955543279648
    END: th(6048000.000000001)=-1.8209955543279648; dx=-1.4607561255669224E-8 evalInputDelta=0.15483912825584412
    Fitness changed from -1.6661564260721207 to -1.8209955543279648
    Iteration 6 complete. Error: -1.8209955543279648 Total: 13.7765; Orientation: 1.0028; Line Search: 8.5028
    Adding measurement 7ad72be3 to history. Total: 3
    Rejected: LBFGS Orientation magnitude: 2.073e+03, gradient 2.186e-04, dot -0.449; [51b6f9f0-df62-4452-adcd-8e52fb4596b9 = 1.000/1.000e+00]
    Orientation rejected. Popping history element from -1.8209955543279648, -0.8716158717870712, -0.47476547956466675, -0.474764809012413
    LBFGS Accumulation History: 3 points
    Removed measurement 7ad72be3 to history. Total: 3
    th(0)=-1.8209955543279648;dx=-4.778096523232226E-8
    New Minimum: -1.8209955543279648 > -1.9272556453943253
    WOLF (strong): th(1.3030021005312836E7)=-1.9272556453943253; dx=7.098978083256252E-9 evalInputDelta=0.10626009106636047
    END: th(6515010.502656418)=-1.9181593507528305; dx=-1.4365177865830925E-8 evalInputDelta=0.09716379642486572
    Fitness changed from -1.8209955543279648 to -1.9272556453943253
    Iteration 7 complete. Error: -1.9272556453943253 Total: 18.2374; Orientation: 1.0395; Line Search: 12.7705
    Adding measurement 6111b75a to history. Total: 3
    Rejected: LBFGS Orientation magnitude: 1.646e+03, gradient 2.857e-04, dot -0.217; [51b6f9f0-df62-4452-adcd-8e52fb4596b9 = 1.000/1.000e+00]
    Orientation rejected. Popping history element from -1.9272556453943253, -0.8716158717870712, -0.47476547956466675, -0.474764809012413
    LBFGS Accumulation History: 3 points
    Removed measurement 6111b75a to history. Total: 3
    th(0)=-1.9272556453943253;dx=-8.162190898800846E-8
    New Minimum: -1.9272556453943253 > -1.945613794028759
    WOLF (strong): th(1.4036164632845048E7)=-1.945613794028759; dx=3.0386480532700786E-8 evalInputDelta=0.018358148634433746
    New Minimum: -1.945613794028759 > -2.022509053349495
    WOLF (strong): th(7018082.316422524)=-2.022509053349495; dx=7.398602535338778E-9 evalInputDelta=0.09525340795516968
    END: th(2339360.7721408415)=-1.9958921298384666; dx=-3.742908009651484E-8 evalInputDelta=0.06863648444414139
    Fitness changed from -1.9272556453943253 to -2.022509053349495
    Iteration 8 complete. Error: -2.022509053349495 Total: 22.2745; Orientation: 1.0102; Line Search: 16.9056
    Adding measurement 311a8073 to history. Total: 3
    Rejected: LBFGS Orientation magnitude: 2.034e+03, gradient 1.933e-04, dot -0.355; [51b6f9f0-df62-4452-adcd-8e52fb4596b9 = 1.000/1.000e+00]
    Orientation rejected. Popping history element from -2.022509053349495, -0.8716158717870712, -0.47476547956466675, -0.474764809012413
    LBFGS Accumulation History: 3 points
    Removed measurement 311a8073 to history. Total: 3
    th(0)=-2.022509053349495;dx=-3.735127178077433E-8
    New Minimum: -2.022509053349495 > -2.084674894809723
    END: th(5040000.000000002)=-2.084674894809723; dx=-1.287744975886572E-8 evalInputDelta=0.062165841460227966
    Fitness changed from -2.022509053349495 to -2.084674894809723
    Iteration 9 complete. Error: -2.084674894809723 Total: 13.6914; Orientation: 1.0200; Line Search: 8.4285
    Adding measurement 2eb653be to history. Total: 3
    Rejected: LBFGS Orientation magnitude: 2.291e+03, gradient 1.406e-04, dot -0.507; [51b6f9f0-df62-4452-adcd-8e52fb4596b9 = 1.000/1.000e+00]
    Orientation rejected. Popping history element from -2.084674894809723, -0.8716158717870712, -0.47476547956466675, -0.474764809012413
    LBFGS Accumulation History: 3 points
    Removed measurement 2eb653be to history. Total: 3
    th(0)=-2.084674894809723;dx=-1.977430015240422E-8
    New Minimum: -2.084674894809723 > -2.1455428823828697
    END: th(1.0858350837760698E7)=-2.1455428823828697; dx=-4.632230603021139E-9 evalInputDelta=0.06086798757314682
    Fitness changed from -2.084674894809723 to -2.1455428823828697
    Iteration 10 complete. Error: -2.1455428823828697 Total: 14.8452; Orientation: 1.0129; Line Search: 9.1917
    <a id="p-13"></a>Iteration 10
    <a id="p-12"></a>![Iteration 10](etc/f013970d-8210-408a-9318-260a3cef922a.jpg)

    Final threshold in iteration 11: -2.1455428823828697 (> -Infinity) after 203.535s (< 5400.000s)

Returns

    -2.1455428823828697