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 83.12 seconds (0.940 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: 307957822351800
Reset training subject: 307959510122100
Corrupt weights measurement
LBFGS Accumulation History: 0 points
Constructing line search parameters: GD+Trust
New Minimum: -152.7356510758985 > -152.8638148377814
th(0)=-152.8638148377814;dx=-3.964129137135392E-5
New Minimum: -152.8638148377814 > -152.86389562180702
END: th(2.154434690031884)=-152.86389562180702; dx=-3.300255457475626E-5 evalInputDelta=8.078402561295661E-5
Fitness changed from -152.7356510758985 to -152.86389562180702
Iteration 1 complete. Error: -152.86389562180702 Total: 8.2415; Orientation: 0.0384; Line Search: 3.3084
<a id="p-3"></a>Iteration 1
<a id="p-2"></a>![Iteration 1](etc/2f5f9979-b46f-4516-b127-e8b1ac1610b4.jpg)
Adding measurement 4ff7529c to history. Total: 0
LBFGS Accumulation History: 1 points
th(0)=-152.86389562180702;dx=-3.300550839439052E-5
New Minimum: -152.86389562180702 > -152.86407065371608
WOLFE (weak): th(4.641588833612779)=-152.86407065371608; dx=-3.2971946335435457E-5 evalInputDelta=1.7503190906609234E-4
New Minimum: -152.86407065371608 > -152.86423895343964
WOLFE (weak): th(9.283177667225559)=-152.86423895343964; dx=-3.295356913758589E-5 evalInputDelta=3.433316326209024E-4
New Minimum: -152.86423895343964 > -152.86491215048093
WOLFE (weak): th(27.849533001676676)=-152.86491215048093; dx=-3.2976851666075246E-5 evalInputDelta=0.001016528673915218
New Minimum: -152.86491215048093 > -152.8679347686574
WOLFE (weak): th(111.3981320067067)=-152.8679347686574; dx=-3.2974628744430285E-5 evalInputDelta=0.004039146850374209
New Minimum: -152.8679347686574 > -152.88407009559495
WOLFE (weak): th(556.9906600335335)=-152.88407009559495; dx=-3.2955279458702116E-5 evalInputDelta=0.020174473787932357
New Minimum: -152.88407009559495 > -152.98489583104472
WOLFE (weak): th(3341.9439602012008)=-152.98489583104472; dx=-3.292661210684037E-5 evalInputDelta=0.12100020923770671
New Minimum: -152.98489583104472 > -153.70780552394282
WOLFE (weak): th(23393.607721408407)=-153.70780552394282; dx=-3.263488417757344E-5 evalInputDelta=0.8439099021358061
New Minimum: -153.70780552394282 > -159.38006594326032
WOLFE (weak): th(187148.86177126726)=-159.38006594326032; dx=-3.037124224802033E-5 evalInputDelta=6.516170321453302
New Minimum: -159.38006594326032 > -195.37009844218016
END: th(1684339.7559414054)=-195.37009844218016; dx=-1.4349060405622615E-5 evalInputDelta=42.50620282037315
Fitness changed from -152.86389562180702 to -195.37009844218016
Iteration 2 complete. Error: -195.37009844218016 Total: 18.0408; Orientation: 0.0616; Line Search: 16.1794
<a id="p-5"></a>Iteration 2
<a id="p-4"></a>![Iteration 2](etc/1155e022-d431-4c38-89f6-4b572d725b70.jpg)
Adding measurement 712ba31b to history. Total: 1
LBFGS Accumulation History: 2 points
th(0)=-195.37009844218016;dx=-1.4876499332757598E-5
New Minimum: -195.37009844218016 > -233.24568776691012
END: th(3628800.0000000005)=-233.24568776691012; dx=-5.478997373939206E-6 evalInputDelta=37.87558932472996
Fitness changed from -195.37009844218016 to -233.24568776691012
Iteration 3 complete. Error: -233.24568776691012 Total: 5.1056; Orientation: 0.0632; Line Search: 3.2254
<a id="p-7"></a>Iteration 3
<a id="p-6"></a>![Iteration 3](etc/50ba8613-8800-46d9-b168-7cfa2f19b0ca.jpg)
Adding measurement 406d4bae to history. Total: 2
LBFGS Accumulation History: 3 points
th(0)=-233.24568776691012;dx=-9.301961147337961E-6
New Minimum: -233.24568776691012 > -261.7404536672797
WOLF (strong): th(7818012.603187701)=-261.7404536672797; dx=4.710969187426031E-8 evalInputDelta=28.4947659003696
END: th(3909006.3015938504)=-257.12908841413446; dx=-2.9131015723743707E-6 evalInputDelta=23.883400647224335
Fitness changed from -233.24568776691012 to -261.7404536672797
Iteration 4 complete. Error: -261.7404536672797 Total: 6.7598; Orientation: 0.0617; Line Search: 4.8910
<a id="p-9"></a>Iteration 4
<a id="p-8"></a>![Iteration 4](etc/80f30d90-be1a-483c-a031-075bef986bc8.jpg)
Adding measurement 6e2b2214 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.710e+04, gradient 3.740e-03, dot -0.450; [21cc0124-50fe-4f43-83b0-6743630f174f = 1.000/1.000e+00]
Orientation rejected. Popping history element from -261.7404536672797, -233.24568776691012, -195.37009844218016, -152.86389562180702
LBFGS Accumulation History: 3 points
Removed measurement 6e2b2214 to history. Total: 3
th(0)=-261.7404536672797;dx=-1.3972288535662056E-5
Armijo: th(8421698.779707028)=-261.0522755221647; dx=6.243070052581941E-6 evalInputDelta=-0.6881781451150459
New Minimum: -261.7404536672797 > -285.9946393112521
WOLF (strong): th(4210849.389853514)=-285.9946393112521; dx=2.181235285270012E-6 evalInputDelta=24.25418564397239
END: th(1403616.4632845046)=-278.80523257305526; dx=-8.075507402635492E-6 evalInputDelta=17.06477890577554
Fitness changed from -261.7404536672797 to -285.9946393112521
Iteration 5 complete. Error: -285.9946393112521 Total: 9.4482; Orientation: 1.0803; Line Search: 6.5229
<a id="p-11"></a>Iteration 5
<a id="p-10"></a>![Iteration 5](etc/c2f53f44-4810-4746-9521-35018ca6d3e3.jpg)
Adding measurement 55968c35 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.326e+04, gradient 3.057e-03, dot -0.458; [21cc0124-50fe-4f43-83b0-6743630f174f = 1.000/1.000e+00]
Orientation rejected. Popping history element from -285.9946393112521, -233.24568776691012, -195.37009844218016, -152.86389562180702
LBFGS Accumulation History: 3 points
Removed measurement 55968c35 to history. Total: 3
th(0)=-285.9946393112521;dx=-9.335900023730228E-6
New Minimum: -285.9946393112521 > -302.4434058618994
END: th(3024000.0000000005)=-302.4434058618994; dx=-9.234837467925834E-7 evalInputDelta=16.448766550647292
Fitness changed from -285.9946393112521 to -302.4434058618994
Iteration 6 complete. Error: -302.4434058618994 Total: 6.4774; Orientation: 1.0481; Line Search: 3.2753
Adding measurement 19048fc1 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 4.291e+04, gradient 2.185e-03, dot -0.581; [21cc0124-50fe-4f43-83b0-6743630f174f = 1.000/1.000e+00]
Orientation rejected. Popping history element from -302.4434058618994, -233.24568776691012, -195.37009844218016, -152.86389562180702
LBFGS Accumulation History: 3 points
Removed measurement 19048fc1 to history. Total: 3
th(0)=-302.4434058618994;dx=-4.752040343497475E-6
New Minimum: -302.4434058618994 > -313.10680549384574
WOLF (strong): th(6515010.502656418)=-313.10680549384574; dx=6.786502288374083E-7 evalInputDelta=10.663399631946334
END: th(3257505.251328209)=-312.7842298174189; dx=-1.422606660332484E-6 evalInputDelta=10.340823955519511
Fitness changed from -302.4434058618994 to -313.10680549384574
Iteration 7 complete. Error: -313.10680549384574 Total: 7.5377; Orientation: 1.0808; Line Search: 4.9009
Adding measurement 64e1ff1b to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.868e+04, gradient 3.003e-03, dot -0.400; [21cc0124-50fe-4f43-83b0-6743630f174f = 1.000/1.000e+00]
Orientation rejected. Popping history element from -313.10680549384574, -233.24568776691012, -195.37009844218016, -152.86389562180702
LBFGS Accumulation History: 3 points
Removed measurement 64e1ff1b to history. Total: 3
th(0)=-313.10680549384574;dx=-9.006776161743453E-6
Armijo: th(7018082.316422524)=-309.69851172049505; dx=5.32311575071109E-6 evalInputDelta=-3.4082937733506924
New Minimum: -313.10680549384574 > -326.3705890628356
WOLF (strong): th(3509041.158211262)=-326.3705890628356; dx=1.6011025867324701E-6 evalInputDelta=13.26378356898988
END: th(1169680.3860704207)=-322.3647217637123; dx=-5.383695850007123E-6 evalInputDelta=9.257916269866541
Fitness changed from -313.10680549384574 to -326.3705890628356
Iteration 8 complete. Error: -326.3705890628356 Total: 9.2039; Orientation: 1.0508; Line Search: 6.5972
Adding measurement 67d7bddb to history. Total: 3
Rejected: LBFGS Orientation magnitude: 4.256e+04, gradient 2.250e-03, dot -0.467; [21cc0124-50fe-4f43-83b0-6743630f174f = 1.000/1.000e+00]
Orientation rejected. Popping history element from -326.3705890628356, -233.24568776691012, -195.37009844218016, -152.86389562180702
LBFGS Accumulation History: 3 points
Removed measurement 67d7bddb to history. Total: 3
th(0)=-326.3705890628356;dx=-5.059210347123641E-6
New Minimum: -326.3705890628356 > -334.5424887847049
END: th(2520000.000000001)=-334.5424887847049; dx=-1.1418265002000355E-6 evalInputDelta=8.171899721869295
Fitness changed from -326.3705890628356 to -334.5424887847049
Iteration 9 complete. Error: -334.5424887847049 Total: 5.8875; Orientation: 1.0506; Line Search: 3.3168
Adding measurement 7b587683 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 4.437e+04, gradient 1.594e-03, dot -0.596; [21cc0124-50fe-4f43-83b0-6743630f174f = 1.000/1.000e+00]
Orientation rejected. Popping history element from -334.5424887847049, -233.24568776691012, -195.37009844218016, -152.86389562180702
LBFGS Accumulation History: 3 points
Removed measurement 7b587683 to history. Total: 3
th(0)=-334.5424887847049;dx=-2.5347928256372436E-6
New Minimum: -334.5424887847049 > -342.4068040313435
END: th(5429175.418880349)=-342.4068040313435; dx=-5.928812545827661E-7 evalInputDelta=7.864315246638569
Fitness changed from -334.5424887847049 to -342.4068040313435
Iteration 10 complete. Error: -342.4068040313435 Total: 6.1345; Orientation: 0.9927; Line Search: 3.2859
<a id="p-13"></a>Iteration 10
<a id="p-12"></a>![Iteration 10](etc/1be2a586-b1ba-4d75-b9ec-7831627a7c6d.jpg)
Final threshold in iteration 11: -342.4068040313435 (> -Infinity) after 83.124s (< 5400.000s)

Returns

    -342.4068040313435