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 149.73 seconds (2.596 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: 461000941988200
Reset training subject: 461003865110100
Adding measurement 2feab262 to history. Total: 0
LBFGS Accumulation History: 1 points
Constructing line search parameters: GD+Trust
th(0)=-101.66145481252927;dx=-1.5398683758629395E-5
New Minimum: -101.66145481252927 > -101.66148760675323
END: th(2.154434690031884)=-101.66148760675323; dx=-1.2548069629253944E-5 evalInputDelta=3.279422395507936E-5
Fitness changed from -101.66145481252927 to -101.66148760675323
Iteration 1 complete. Error: -101.66148760675323 Total: 14.3570; Orientation: 0.1034; Line Search: 5.7365
<a id="p-3"></a>Iteration 1
<a id="p-2"></a>![Iteration 1](etc/bae5a863-7145-40bd-8fc9-de3e8f555b2f.jpg)
Adding measurement 1a238972 to history. Total: 1
LBFGS Accumulation History: 2 points
th(0)=-101.66148760675323;dx=-1.2584997134574881E-5
New Minimum: -101.66148760675323 > -101.66155319516943
WOLFE (weak): th(4.641588833612779)=-101.66155319516943; dx=-1.2589582964005402E-5 evalInputDelta=6.558841620574185E-5
New Minimum: -101.66155319516943 > -101.6616078521506
WOLFE (weak): th(9.283177667225559)=-101.6616078521506; dx=-1.2580946044036748E-5 evalInputDelta=1.2024539736898987E-4
New Minimum: -101.6616078521506 > -101.66185380820225
WOLFE (weak): th(27.849533001676676)=-101.66185380820225; dx=-1.257024447581422E-5 evalInputDelta=3.662014490259935E-4
New Minimum: -101.66185380820225 > -101.66295787025892
WOLFE (weak): th(111.3981320067067)=-101.66295787025892; dx=-1.256317088980914E-5 evalInputDelta=0.001470263505694902
New Minimum: -101.66295787025892 > -101.6688441769702
WOLFE (weak): th(556.9906600335335)=-101.6688441769702; dx=-1.2560177711922863E-5 evalInputDelta=0.007356570216970226
New Minimum: -101.6688441769702 > -101.70562997298684
WOLFE (weak): th(3341.9439602012008)=-101.70562997298684; dx=-1.255155777026679E-5 evalInputDelta=0.044142366233614894
New Minimum: -101.70562997298684 > -101.96989761004939
WOLFE (weak): th(23393.607721408407)=-101.96989761004939; dx=-1.2504836583773614E-5 evalInputDelta=0.3084100032961601
New Minimum: -101.96989761004939 > -104.08473974926943
WOLFE (weak): th(187148.86177126726)=-104.08473974926943; dx=-1.2016069704290454E-5 evalInputDelta=2.423252142516205
New Minimum: -104.08473974926943 > -119.52941759563524
END: th(1684339.7559414054)=-119.52941759563524; dx=-7.653733791925608E-6 evalInputDelta=17.86792998888201
Fitness changed from -101.66148760675323 to -119.52941759563524
Iteration 2 complete. Error: -119.52941759563524 Total: 31.7507; Orientation: 0.1020; Line Search: 28.3360
<a id="p-5"></a>Iteration 2
<a id="p-4"></a>![Iteration 2](etc/e424643c-091f-4592-86f3-8ab62c507a4d.jpg)
Adding measurement 5f054faa to history. Total: 2
LBFGS Accumulation History: 3 points
th(0)=-119.52941759563524;dx=-7.783125757910589E-6
New Minimum: -119.52941759563524 > -139.05938540188436
END: th(3628800.0000000005)=-139.05938540188436; dx=-3.2607458314926317E-6 evalInputDelta=19.529967806249118
Fitness changed from -119.52941759563524 to -139.05938540188436
Iteration 3 complete. Error: -139.05938540188436 Total: 8.8223; Orientation: 0.0901; Line Search: 5.3697
<a id="p-7"></a>Iteration 3
<a id="p-6"></a>![Iteration 3](etc/9c7eb22c-d835-423d-8752-df1b59e65062.jpg)
Adding measurement 39a012df to history. Total: 3
Rejected: LBFGS Orientation magnitude: 8.953e+03, gradient 2.255e-03, dot -0.516; [bb58dd79-b105-483f-85e5-d41be99ded98 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -139.05938540188436, -119.52941759563524, -101.66148760675323, -101.66145481252927
LBFGS Accumulation History: 3 points
Removed measurement 39a012df to history. Total: 3
th(0)=-139.05938540188436;dx=-5.071653356781371E-6
New Minimum: -139.05938540188436 > -156.41338508099258
END: th(7818012.603187701)=-156.41338508099258; dx=-5.540679255012261E-7 evalInputDelta=17.353999679108227
Fitness changed from -139.05938540188436 to -156.41338508099258
Iteration 4 complete. Error: -156.41338508099258 Total: 10.9867; Orientation: 1.8759; Line Search: 5.6244
<a id="p-9"></a>Iteration 4
<a id="p-8"></a>![Iteration 4](etc/4dadee93-fbcf-48c8-b24d-f268f5eaddb4.jpg)
Adding measurement 75d0af81 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 8.853e+03, gradient 2.532e-03, dot -0.260; [bb58dd79-b105-483f-85e5-d41be99ded98 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -156.41338508099258, -119.52941759563524, -101.66148760675323, -101.66145481252927
LBFGS Accumulation History: 3 points
Removed measurement 75d0af81 to history. Total: 3
th(0)=-156.41338508099258;dx=-6.39932267071928E-6
Armijo: th(1.6843397559414055E7)=-148.38163954955124; dx=1.9026184604375923E-6 evalInputDelta=-8.031745531441345
New Minimum: -156.41338508099258 > -166.7771597021274
WOLF (strong): th(8421698.779707028)=-166.7771597021274; dx=1.5293686841303025E-6 evalInputDelta=10.363774621134809
New Minimum: -166.7771597021274 > -168.90947656237464
END: th(2807232.926569009)=-168.90947656237464; dx=-2.1917269930183354E-6 evalInputDelta=12.496091481382052
Fitness changed from -156.41338508099258 to -168.90947656237464
Iteration 5 complete. Error: -168.90947656237464 Total: 16.9740; Orientation: 1.7894; Line Search: 11.6884
<a id="p-11"></a>Iteration 5
<a id="p-10"></a>![Iteration 5](etc/7a920d2c-787b-40aa-bde0-a7f66560adf9.jpg)
Adding measurement 7066def1 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.789e+04, gradient 1.764e-03, dot -0.534; [bb58dd79-b105-483f-85e5-d41be99ded98 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -168.90947656237464, -119.52941759563524, -101.66148760675323, -101.66145481252927
LBFGS Accumulation History: 3 points
Removed measurement 7066def1 to history. Total: 3
th(0)=-168.90947656237464;dx=-3.1016647734662547E-6
New Minimum: -168.90947656237464 > -179.82327023614465
END: th(6048000.000000001)=-179.82327023614465; dx=-8.552484221626051E-7 evalInputDelta=10.913793673770016
Fitness changed from -168.90947656237464 to -179.82327023614465
Iteration 6 complete. Error: -179.82327023614465 Total: 10.8956; Orientation: 1.7797; Line Search: 5.8010
Adding measurement 6ae78282 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.187e+04, gradient 1.944e-03, dot -0.442; [bb58dd79-b105-483f-85e5-d41be99ded98 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -179.82327023614465, -119.52941759563524, -101.66148760675323, -101.66145481252927
LBFGS Accumulation History: 3 points
Removed measurement 6ae78282 to history. Total: 3
th(0)=-179.82327023614465;dx=-3.7681669747351645E-6
New Minimum: -179.82327023614465 > -181.36020003586734
WOLF (strong): th(1.3030021005312836E7)=-181.36020003586734; dx=1.0457225688872572E-6 evalInputDelta=1.5369297997226852
New Minimum: -181.36020003586734 > -187.64822456303932
WOLF (strong): th(6515010.502656418)=-187.64822456303932; dx=3.353590954653067E-7 evalInputDelta=7.8249543268946695
END: th(2171670.167552139)=-185.94152446391158; dx=-1.7398539319386943E-6 evalInputDelta=6.118254227766926
Fitness changed from -179.82327023614465 to -187.64822456303932
Iteration 7 complete. Error: -187.64822456303932 Total: 15.6836; Orientation: 1.8304; Line Search: 11.2684
Adding measurement 38526850 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.330e+04, gradient 2.167e-03, dot -0.343; [bb58dd79-b105-483f-85e5-d41be99ded98 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -187.64822456303932, -119.52941759563524, -101.66148760675323, -101.66145481252927
LBFGS Accumulation History: 3 points
Removed measurement 38526850 to history. Total: 3
th(0)=-187.64822456303932;dx=-4.660332858601109E-6
New Minimum: -187.64822456303932 > -198.25734360501184
WOLF (strong): th(4678721.544281682)=-198.25734360501184; dx=9.236295434980233E-8 evalInputDelta=10.60911904197252
END: th(2339360.772140841)=-196.0776242996382; dx=-2.1736884057694865E-6 evalInputDelta=8.429399736598867
Fitness changed from -187.64822456303932 to -198.25734360501184
Iteration 8 complete. Error: -198.25734360501184 Total: 13.0871; Orientation: 1.6922; Line Search: 8.3962
Adding measurement 4089ec57 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.072e+04, gradient 1.743e-03, dot -0.460; [bb58dd79-b105-483f-85e5-d41be99ded98 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -198.25734360501184, -119.52941759563524, -101.66148760675323, -101.66145481252927
LBFGS Accumulation History: 3 points
Removed measurement 4089ec57 to history. Total: 3
th(0)=-198.25734360501184;dx=-3.0299394612288563E-6
New Minimum: -198.25734360501184 > -205.40415777732682
END: th(5040000.000000001)=-205.40415777732682; dx=-9.496632923667386E-8 evalInputDelta=7.146814172314976
Fitness changed from -198.25734360501184 to -205.40415777732682
Iteration 9 complete. Error: -205.40415777732682 Total: 10.6025; Orientation: 1.7713; Line Search: 5.6788
Adding measurement 45c4bf77 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.403e+04, gradient 1.710e-03, dot -0.454; [bb58dd79-b105-483f-85e5-d41be99ded98 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -205.40415777732682, -119.52941759563524, -101.66148760675323, -101.66145481252927
LBFGS Accumulation History: 3 points
Removed measurement 45c4bf77 to history. Total: 3
th(0)=-205.40415777732682;dx=-2.9111100280551155E-6
New Minimum: -205.40415777732682 > -206.84386347666032
WOLF (strong): th(1.0858350837760696E7)=-206.84386347666032; dx=1.0879554711913578E-6 evalInputDelta=1.4397056993335013
New Minimum: -206.84386347666032 > -211.77703797192896
WOLF (strong): th(5429175.418880348)=-211.77703797192896; dx=1.9242443454478514E-7 evalInputDelta=6.372880194602146
END: th(1809725.1396267826)=-209.6889592136773; dx=-1.6696216238700886E-6 evalInputDelta=4.284801436350477
Fitness changed from -205.40415777732682 to -211.77703797192896
Iteration 10 complete. Error: -211.77703797192896 Total: 15.9733; Orientation: 1.7036; Line Search: 11.3945
<a id="p-13"></a>Iteration 10
<a id="p-12"></a>![Iteration 10](etc/a14ac1cc-f246-46d5-bd53-03bc0159752c.jpg)
Final threshold in iteration 11: -211.77703797192896 (> -Infinity) after 149.734s (< 5400.000s)

Returns

    -211.77703797192896