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 85.49 seconds (1.076 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: 305079068521200
Reset training subject: 305080893135900
Adding measurement 1eb981eb to history. Total: 0
LBFGS Accumulation History: 1 points
Constructing line search parameters: GD+Trust
th(0)=-151.24924068978362;dx=-2.946430832669954E-5
New Minimum: -151.24924068978362 > -151.24928831684892
END: th(2.154434690031884)=-151.24928831684892; dx=-1.854301507506543E-5 evalInputDelta=4.7627065299593596E-5
Fitness changed from -151.24924068978362 to -151.24928831684892
Iteration 1 complete. Error: -151.24928831684892 Total: 8.2554; Orientation: 0.0680; Line Search: 3.2879
<a id="p-3"></a>Iteration 1
<a id="p-2"></a>![Iteration 1](etc/fdb13372-266c-4701-b6ac-8e9008820046.jpg)
Adding measurement 5676c46f to history. Total: 1
LBFGS Accumulation History: 2 points
th(0)=-151.24928831684892;dx=-1.845412937554007E-5
New Minimum: -151.24928831684892 > -151.2493767670733
WOLFE (weak): th(4.641588833612779)=-151.2493767670733; dx=-1.8438303639824295E-5 evalInputDelta=8.845022438208616E-5
New Minimum: -151.2493767670733 > -151.2494788249602
WOLFE (weak): th(9.283177667225559)=-151.2494788249602; dx=-1.8427107334891976E-5 evalInputDelta=1.9050811127385714E-4
New Minimum: -151.2494788249602 > -151.24985303662302
WOLFE (weak): th(27.849533001676676)=-151.24985303662302; dx=-1.8409876778596608E-5 evalInputDelta=5.647197741041055E-4
New Minimum: -151.24985303662302 > -151.25154718329452
WOLFE (weak): th(111.3981320067067)=-151.25154718329452; dx=-1.8395718058075672E-5 evalInputDelta=0.0022588664456009155
New Minimum: -151.25154718329452 > -151.26064354195069
WOLFE (weak): th(556.9906600335335)=-151.26064354195069; dx=-1.8377367885598155E-5 evalInputDelta=0.011355225101766564
New Minimum: -151.26064354195069 > -151.31741368640806
WOLFE (weak): th(3341.9439602012008)=-151.31741368640806; dx=-1.8383581950270657E-5 evalInputDelta=0.06812536955914084
New Minimum: -151.31741368640806 > -151.7253811125006
WOLFE (weak): th(23393.607721408407)=-151.7253811125006; dx=-1.8302283672474476E-5 evalInputDelta=0.47609279565168094
New Minimum: -151.7253811125006 > -155.0002055397796
WOLFE (weak): th(187148.86177126726)=-155.0002055397796; dx=-1.775438610564544E-5 evalInputDelta=3.7509172229306955
New Minimum: -155.0002055397796 > -178.74300702539833
END: th(1684339.7559414054)=-178.74300702539833; dx=-1.0592243357658802E-5 evalInputDelta=27.49371870854941
Fitness changed from -151.24928831684892 to -178.74300702539833
Iteration 2 complete. Error: -178.74300702539833 Total: 18.6344; Orientation: 0.0622; Line Search: 16.4211
<a id="p-5"></a>Iteration 2
<a id="p-4"></a>![Iteration 2](etc/151522b2-9779-4c26-a109-7b0769648851.jpg)
Adding measurement 577fc058 to history. Total: 2
LBFGS Accumulation History: 3 points
th(0)=-178.74300702539833;dx=-1.2925165564582097E-5
New Minimum: -178.74300702539833 > -210.79756223400227
END: th(3628800.0000000005)=-210.79756223400227; dx=-4.5111142446042296E-6 evalInputDelta=32.054555208603944
Fitness changed from -178.74300702539833 to -210.79756223400227
Iteration 3 complete. Error: -210.79756223400227 Total: 5.2627; Orientation: 0.0574; Line Search: 3.2383
<a id="p-7"></a>Iteration 3
<a id="p-6"></a>![Iteration 3](etc/f326a117-04c8-4dac-88b4-a6575caea1b2.jpg)
Adding measurement 78328f07 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.367e+04, gradient 3.160e-03, dot -0.415; [a1a11c45-f3e6-4b4d-a717-f2f3059f2c41 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -210.79756223400227, -178.74300702539833, -151.24928831684892, -151.24924068978362
LBFGS Accumulation History: 3 points
Removed measurement 78328f07 to history. Total: 3
th(0)=-210.79756223400227;dx=-9.97942995387314E-6
New Minimum: -210.79756223400227 > -236.5663542321592
WOLF (strong): th(7818012.603187701)=-236.5663542321592; dx=3.157400253495443E-8 evalInputDelta=25.768791998156928
END: th(3909006.3015938504)=-233.24852025323096; dx=-2.2665253049476318E-6 evalInputDelta=22.450958019228693
Fitness changed from -210.79756223400227 to -236.5663542321592
Iteration 4 complete. Error: -236.5663542321592 Total: 7.9536; Orientation: 1.1276; Line Search: 4.9803
<a id="p-9"></a>Iteration 4
<a id="p-8"></a>![Iteration 4](etc/2d4c49ee-b92d-49de-a618-d715cec7bb59.jpg)
Adding measurement 2959526e to history. Total: 3
Rejected: LBFGS Orientation magnitude: 9.468e+03, gradient 3.734e-03, dot -0.155; [a1a11c45-f3e6-4b4d-a717-f2f3059f2c41 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -236.5663542321592, -178.74300702539833, -151.24928831684892, -151.24924068978362
LBFGS Accumulation History: 3 points
Removed measurement 2959526e to history. Total: 3
th(0)=-236.5663542321592;dx=-1.3926245709774672E-5
New Minimum: -236.5663542321592 > -248.00022363205605
WOLF (strong): th(8421698.779707028)=-248.00022363205605; dx=4.358957363919532E-6 evalInputDelta=11.43386939989685
New Minimum: -248.00022363205605 > -264.6010503708928
WOLF (strong): th(4210849.389853514)=-264.6010503708928; dx=6.892247690398048E-7 evalInputDelta=28.03469613873358
END: th(1403616.4632845046)=-254.11793811722688; dx=-8.63213626636187E-6 evalInputDelta=17.551583885067686
Fitness changed from -236.5663542321592 to -264.6010503708928
Iteration 5 complete. Error: -264.6010503708928 Total: 9.9094; Orientation: 1.1314; Line Search: 6.9137
<a id="p-11"></a>Iteration 5
<a id="p-10"></a>![Iteration 5](etc/859d325c-4b56-4459-a4d8-da376d204593.jpg)
Adding measurement 3601742f to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.918e+04, gradient 2.951e-03, dot -0.269; [a1a11c45-f3e6-4b4d-a717-f2f3059f2c41 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -264.6010503708928, -178.74300702539833, -151.24928831684892, -151.24924068978362
LBFGS Accumulation History: 3 points
Removed measurement 3601742f to history. Total: 3
th(0)=-264.6010503708928;dx=-8.705321605222729E-6
New Minimum: -264.6010503708928 > -280.7667465921813
END: th(3024000.0000000005)=-280.7667465921813; dx=-1.4274846948961224E-6 evalInputDelta=16.1656962212885
Fitness changed from -264.6010503708928 to -280.7667465921813
Iteration 6 complete. Error: -280.7667465921813 Total: 6.3098; Orientation: 1.1089; Line Search: 3.3680
Adding measurement 195968a to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.850e+04, gradient 2.226e-03, dot -0.429; [a1a11c45-f3e6-4b4d-a717-f2f3059f2c41 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -280.7667465921813, -178.74300702539833, -151.24928831684892, -151.24924068978362
LBFGS Accumulation History: 3 points
Removed measurement 195968a to history. Total: 3
th(0)=-280.7667465921813;dx=-4.9375359437492584E-6
New Minimum: -280.7667465921813 > -292.8867130868518
WOLF (strong): th(6515010.502656418)=-292.8867130868518; dx=3.059401828678408E-7 evalInputDelta=12.119966494670507
END: th(3257505.251328209)=-291.67933485298084; dx=-1.587210970229111E-6 evalInputDelta=10.912588260799566
Fitness changed from -280.7667465921813 to -292.8867130868518
Iteration 7 complete. Error: -292.8867130868518 Total: 7.5622; Orientation: 1.0804; Line Search: 4.8950
Adding measurement 2b0f5318 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.227e+04, gradient 2.940e-03, dot -0.228; [a1a11c45-f3e6-4b4d-a717-f2f3059f2c41 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -292.8867130868518, -178.74300702539833, -151.24928831684892, -151.24924068978362
LBFGS Accumulation History: 3 points
Removed measurement 2b0f5318 to history. Total: 3
th(0)=-292.8867130868518;dx=-8.630432289562062E-6
New Minimum: -292.8867130868518 > -293.97316178329794
WOLF (strong): th(7018082.316422524)=-293.97316178329794; dx=4.025922345233018E-6 evalInputDelta=1.0864486964461548
New Minimum: -293.97316178329794 > -306.78308250279923
WOLF (strong): th(3509041.158211262)=-306.78308250279923; dx=9.392691888780717E-7 evalInputDelta=13.896369415947447
END: th(1169680.3860704207)=-301.9125908750262; dx=-5.397288403819874E-6 evalInputDelta=9.025877788174398
Fitness changed from -292.8867130868518 to -306.78308250279923
Iteration 8 complete. Error: -306.78308250279923 Total: 9.2028; Orientation: 1.1291; Line Search: 6.5084
Adding measurement 5fc1435 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.905e+04, gradient 2.209e-03, dot -0.340; [a1a11c45-f3e6-4b4d-a717-f2f3059f2c41 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -306.78308250279923, -178.74300702539833, -151.24928831684892, -151.24924068978362
LBFGS Accumulation History: 3 points
Removed measurement 5fc1435 to history. Total: 3
th(0)=-306.78308250279923;dx=-4.8642951816933426E-6
New Minimum: -306.78308250279923 > -314.9841780857878
END: th(2520000.000000001)=-314.9841780857878; dx=-1.3332426703964603E-6 evalInputDelta=8.201095582988557
Fitness changed from -306.78308250279923 to -314.9841780857878
Iteration 9 complete. Error: -314.9841780857878 Total: 6.0324; Orientation: 1.1627; Line Search: 3.3032
Adding measurement 764bc641 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.320e+04, gradient 1.636e-03, dot -0.481; [a1a11c45-f3e6-4b4d-a717-f2f3059f2c41 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -314.9841780857878, -178.74300702539833, -151.24928831684892, -151.24924068978362
LBFGS Accumulation History: 3 points
Removed measurement 764bc641 to history. Total: 3
th(0)=-314.9841780857878;dx=-2.6715544573375547E-6
New Minimum: -314.9841780857878 > -323.6040486359554
END: th(5429175.418880349)=-323.6040486359554; dx=-7.119188495322742E-7 evalInputDelta=8.619870550167605
Fitness changed from -314.9841780857878 to -323.6040486359554
Iteration 10 complete. Error: -323.6040486359554 Total: 6.0906; Orientation: 1.1118; Line Search: 3.3573
<a id="p-13"></a>Iteration 10
<a id="p-12"></a>![Iteration 10](etc/88f2a45f-e632-4a7c-83a1-308a44cf27d4.jpg)
Final threshold in iteration 11: -323.6040486359554 (> -Infinity) after 85.494s (< 5400.000s)

Returns

    -323.6040486359554