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 133.63 seconds (1.345 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: 328390048381800
Reset training subject: 328392706881200
Adding measurement 6ea50c1e to history. Total: 0
LBFGS Accumulation History: 1 points
Constructing line search parameters: GD+Trust
th(0)=-128.64720355780335;dx=-2.9230331114651874E-5
New Minimum: -128.64720355780335 > -128.64725603810896
END: th(2.154434690031884)=-128.64725603810896; dx=-2.1333401332696284E-5 evalInputDelta=5.248030561233463E-5
Fitness changed from -128.64720355780335 to -128.64725603810896
Iteration 1 complete. Error: -128.64725603810896 Total: 12.6779; Orientation: 0.0629; Line Search: 4.9737
<a id="p-3"></a>Iteration 1
<a id="p-2"></a>![Iteration 1](etc/241782b3-0df6-4d23-bea9-b95c05949bc0.jpg)
Adding measurement 2a9d17a8 to history. Total: 1
LBFGS Accumulation History: 2 points
th(0)=-128.64725603810896;dx=-2.1213724548572813E-5
New Minimum: -128.64725603810896 > -128.6473684958346
WOLFE (weak): th(4.641588833612779)=-128.6473684958346; dx=-2.1205627333584803E-5 evalInputDelta=1.1245772563484024E-4
New Minimum: -128.6473684958346 > -128.64748095346195
WOLFE (weak): th(9.283177667225559)=-128.64748095346195; dx=-2.1199314598995114E-5 evalInputDelta=2.2491535298740928E-4
New Minimum: -128.64748095346195 > -128.64792328584238
WOLFE (weak): th(27.849533001676676)=-128.64792328584238; dx=-2.1183925817831694E-5 evalInputDelta=6.672477334177529E-4
New Minimum: -128.64792328584238 > -128.64991751124876
WOLFE (weak): th(111.3981320067067)=-128.64991751124876; dx=-2.1175061386822058E-5 evalInputDelta=0.0026614731397955893
New Minimum: -128.64991751124876 > -128.66057034966485
WOLFE (weak): th(556.9906600335335)=-128.66057034966485; dx=-2.1160998197559475E-5 evalInputDelta=0.013314311555888025
New Minimum: -128.66057034966485 > -128.72710626578788
WOLFE (weak): th(3341.9439602012008)=-128.72710626578788; dx=-2.1143098304902478E-5 evalInputDelta=0.07985022767891792
New Minimum: -128.72710626578788 > -129.20425314607687
WOLFE (weak): th(23393.607721408407)=-129.20425314607687; dx=-2.099804301963633E-5 evalInputDelta=0.5569971079679021
New Minimum: -129.20425314607687 > -132.95298015964948
WOLFE (weak): th(187148.86177126726)=-132.95298015964948; dx=-1.952060288858625E-5 evalInputDelta=4.305724121540521
New Minimum: -132.95298015964948 > -153.3930053078756
END: th(1684339.7559414054)=-153.3930053078756; dx=-5.935472936333126E-6 evalInputDelta=24.745749269766634
Fitness changed from -128.64725603810896 to -153.3930053078756
Iteration 2 complete. Error: -153.3930053078756 Total: 29.0092; Orientation: 0.0628; Line Search: 25.7982
<a id="p-5"></a>Iteration 2
<a id="p-4"></a>![Iteration 2](etc/a08de628-ddde-415c-84b9-44f6a8d49149.jpg)
Adding measurement 4c75eac7 to history. Total: 2
LBFGS Accumulation History: 3 points
th(0)=-153.3930053078756;dx=-9.697764488345345E-6
New Minimum: -153.3930053078756 > -171.40241464992013
END: th(3628800.0000000005)=-171.40241464992013; dx=-1.1576424264655667E-6 evalInputDelta=18.009409342044535
Fitness changed from -153.3930053078756 to -171.40241464992013
Iteration 3 complete. Error: -171.40241464992013 Total: 8.2814; Orientation: 0.0600; Line Search: 5.0713
<a id="p-7"></a>Iteration 3
<a id="p-6"></a>![Iteration 3](etc/99dba44f-3c0b-413a-a994-2aec1779b362.jpg)
Adding measurement 1776b7c6 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 4.747e+03, gradient 3.022e-03, dot -0.320; [57ed8745-f7ce-481e-87fd-4d46351528a6 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -171.40241464992013, -153.3930053078756, -128.64725603810896, -128.64720355780335
LBFGS Accumulation History: 3 points
Removed measurement 1776b7c6 to history. Total: 3
th(0)=-171.40241464992013;dx=-9.129222441936888E-6
Armijo: th(7818012.603187701)=-169.7339729270092; dx=3.061891746798716E-6 evalInputDelta=-1.6684417229109272
New Minimum: -171.40241464992013 > -181.91506774166334
WOLF (strong): th(3909006.3015938504)=-181.91506774166334; dx=1.4452684025032808E-6 evalInputDelta=10.512653091743204
END: th(1303002.1005312835)=-180.51315004776941; dx=-3.74448728756983E-6 evalInputDelta=9.110735397849282
Fitness changed from -171.40241464992013 to -181.91506774166334
Iteration 4 complete. Error: -181.91506774166334 Total: 14.7676; Orientation: 1.0933; Line Search: 10.5219
<a id="p-9"></a>Iteration 4
<a id="p-8"></a>![Iteration 4](etc/5f6e2461-bc20-4c02-890e-f25360d04831.jpg)
Adding measurement 41c3f503 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 6.903e+03, gradient 3.180e-03, dot -0.226; [57ed8745-f7ce-481e-87fd-4d46351528a6 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -181.91506774166334, -153.3930053078756, -128.64725603810896, -128.64720355780335
LBFGS Accumulation History: 3 points
Removed measurement 41c3f503 to history. Total: 3
th(0)=-181.91506774166334;dx=-1.0098316477972491E-5
New Minimum: -181.91506774166334 > -195.13814544619578
WOLF (strong): th(2807232.926569009)=-195.13814544619578; dx=7.246243269131675E-7 evalInputDelta=13.223077704532443
END: th(1403616.4632845046)=-193.01179435815536; dx=-4.0725147846724635E-6 evalInputDelta=11.09672661649202
Fitness changed from -181.91506774166334 to -195.13814544619578
Iteration 5 complete. Error: -195.13814544619578 Total: 11.7585; Orientation: 1.1431; Line Search: 7.6674
<a id="p-11"></a>Iteration 5
<a id="p-10"></a>![Iteration 5](etc/375b9a63-c879-4014-b085-c95cc5dac6f0.jpg)
Adding measurement 3b71e8c3 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.160e+04, gradient 2.499e-03, dot -0.355; [57ed8745-f7ce-481e-87fd-4d46351528a6 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -195.13814544619578, -153.3930053078756, -128.64725603810896, -128.64720355780335
LBFGS Accumulation History: 3 points
Removed measurement 3b71e8c3 to history. Total: 3
th(0)=-195.13814544619578;dx=-6.238719471580447E-6
New Minimum: -195.13814544619578 > -203.7177984643376
WOLF (strong): th(3024000.0000000005)=-203.7177984643376; dx=4.5617718031447897E-7 evalInputDelta=8.579653018141812
END: th(1512000.0000000002)=-202.36104506312333; dx=-2.5403378291319478E-6 evalInputDelta=7.222899616927549
Fitness changed from -195.13814544619578 to -203.7177984643376
Iteration 6 complete. Error: -203.7177984643376 Total: 11.6185; Orientation: 1.0820; Line Search: 7.6256
Adding measurement 15165547 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.742e+04, gradient 2.405e-03, dot -0.409; [57ed8745-f7ce-481e-87fd-4d46351528a6 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -203.7177984643376, -153.3930053078756, -128.64725603810896, -128.64720355780335
LBFGS Accumulation History: 3 points
Removed measurement 15165547 to history. Total: 3
th(0)=-203.7177984643376;dx=-5.782865825867237E-6
New Minimum: -203.7177984643376 > -210.13278520903364
WOLF (strong): th(3257505.251328209)=-210.13278520903364; dx=1.3104021230078416E-6 evalInputDelta=6.414986744696051
New Minimum: -210.13278520903364 > -210.32430864942694
END: th(1628752.6256641045)=-210.32430864942694; dx=-1.7177222578735479E-6 evalInputDelta=6.606510185089348
Fitness changed from -203.7177984643376 to -210.32430864942694
Iteration 7 complete. Error: -210.32430864942694 Total: 11.2828; Orientation: 1.1158; Line Search: 7.7056
Adding measurement 5164a99d to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.232e+04, gradient 1.655e-03, dot -0.649; [57ed8745-f7ce-481e-87fd-4d46351528a6 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -210.32430864942694, -153.3930053078756, -128.64725603810896, -128.64720355780335
LBFGS Accumulation History: 3 points
Removed measurement 5164a99d to history. Total: 3
th(0)=-210.32430864942694;dx=-2.7312834976486673E-6
New Minimum: -210.32430864942694 > -217.2186415455833
END: th(3509041.158211262)=-217.2186415455833; dx=-1.1803422854918508E-6 evalInputDelta=6.894332896156357
Fitness changed from -210.32430864942694 to -217.2186415455833
Iteration 8 complete. Error: -217.2186415455833 Total: 8.9082; Orientation: 1.0233; Line Search: 5.1179
Adding measurement 70cc304d to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.352e+04, gradient 1.854e-03, dot -0.524; [57ed8745-f7ce-481e-87fd-4d46351528a6 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -217.2186415455833, -153.3930053078756, -128.64725603810896, -128.64720355780335
LBFGS Accumulation History: 3 points
Removed measurement 70cc304d to history. Total: 3
th(0)=-217.2186415455833;dx=-3.4348846080950058E-6
Armijo: th(7560000.000000003)=-217.15641667551668; dx=1.338060857778227E-6 evalInputDelta=-0.06222487006661481
New Minimum: -217.2186415455833 > -221.74314133874827
WOLF (strong): th(3780000.0000000014)=-221.74314133874827; dx=2.8398294615730034E-7 evalInputDelta=4.524499793164978
END: th(1260000.0000000005)=-220.63491439171108; dx=-1.6914433769641186E-6 evalInputDelta=3.4162728461277823
Fitness changed from -217.2186415455833 to -221.74314133874827
Iteration 9 complete. Error: -221.74314133874827 Total: 13.7313; Orientation: 1.0209; Line Search: 10.0594
Adding measurement 264c4934 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.111e+04, gradient 2.284e-03, dot -0.354; [57ed8745-f7ce-481e-87fd-4d46351528a6 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -221.74314133874827, -153.3930053078756, -128.64725603810896, -128.64720355780335
LBFGS Accumulation History: 3 points
Removed measurement 264c4934 to history. Total: 3
th(0)=-221.74314133874827;dx=-5.2059921749484715E-6
New Minimum: -221.74314133874827 > -227.64610410522337
WOLF (strong): th(2714587.7094401745)=-227.64610410522337; dx=8.665800798359821E-7 evalInputDelta=5.902962766475099
END: th(1357293.8547200873)=-227.12980618253138; dx=-2.0163203048596042E-6 evalInputDelta=5.386664843783109
Fitness changed from -221.74314133874827 to -227.64610410522337
Iteration 10 complete. Error: -227.64610410522337 Total: 11.0989; Orientation: 1.0824; Line Search: 7.5397
<a id="p-13"></a>Iteration 10
<a id="p-12"></a>![Iteration 10](etc/62df64c1-b8d8-40b4-91f3-b90e3749da53.jpg)
Final threshold in iteration 11: -227.64610410522337 (> -Infinity) after 133.633s (< 5400.000s)

Returns

    -227.64610410522337