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.48 seconds (2.658 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: 462903817006400
Reset training subject: 462906882524900
Adding measurement 52026efc to history. Total: 0
LBFGS Accumulation History: 1 points
Constructing line search parameters: GD+Trust
th(0)=-105.01702529393111;dx=-1.53797552295909E-5
New Minimum: -105.01702529393111 > -105.01705704029361
END: th(2.154434690031884)=-105.01705704029361; dx=-1.239844212261775E-5 evalInputDelta=3.17463624952552E-5
Fitness changed from -105.01702529393111 to -105.01705704029361
Iteration 1 complete. Error: -105.01705704029361 Total: 14.4196; Orientation: 0.1060; Line Search: 5.7632
<a id="p-3"></a>Iteration 1
<a id="p-2"></a>![Iteration 1](etc/b881f2c8-9710-4fb2-aa3e-66a8cc38722d.jpg)
Adding measurement 23df2e2f to history. Total: 1
LBFGS Accumulation History: 2 points
th(0)=-105.01705704029361;dx=-1.2414318125222088E-5
New Minimum: -105.01705704029361 > -105.01712053298978
WOLFE (weak): th(4.641588833612779)=-105.01712053298978; dx=-1.240180613776864E-5 evalInputDelta=6.349269617089703E-5
New Minimum: -105.01712053298978 > -105.0171734435406
WOLFE (weak): th(9.283177667225559)=-105.0171734435406; dx=-1.239335247759376E-5 evalInputDelta=1.16403246991581E-4
New Minimum: -105.0171734435406 > -105.01741683173103
WOLFE (weak): th(27.849533001676676)=-105.01741683173103; dx=-1.2381100907404683E-5 evalInputDelta=3.5979143741826647E-4
New Minimum: -105.01741683173103 > -105.01850678062115
WOLFE (weak): th(111.3981320067067)=-105.01850678062115; dx=-1.236469656278585E-5 evalInputDelta=0.0014497403275441911
New Minimum: -105.01850678062115 > -105.02428966972677
WOLFE (weak): th(556.9906600335335)=-105.02428966972677; dx=-1.2356369327279437E-5 evalInputDelta=0.007232629433161719
New Minimum: -105.02428966972677 > -105.06043477045307
WOLFE (weak): th(3341.9439602012008)=-105.06043477045307; dx=-1.235218420885535E-5 evalInputDelta=0.04337773015946311
New Minimum: -105.06043477045307 > -105.32013604131939
WOLFE (weak): th(23393.607721408407)=-105.32013604131939; dx=-1.2324474403561154E-5 evalInputDelta=0.3030790010257789
New Minimum: -105.32013604131939 > -107.39962083028564
WOLFE (weak): th(187148.86177126726)=-107.39962083028564; dx=-1.1892105368171528E-5 evalInputDelta=2.3825637899920338
New Minimum: -107.39962083028564 > -122.85771754941841
END: th(1684339.7559414054)=-122.85771754941841; dx=-7.878812550760764E-6 evalInputDelta=17.840660509124803
Fitness changed from -105.01705704029361 to -122.85771754941841
Iteration 2 complete. Error: -122.85771754941841 Total: 32.4824; Orientation: 0.1014; Line Search: 28.9332
<a id="p-5"></a>Iteration 2
<a id="p-4"></a>![Iteration 2](etc/c94d8a12-0d67-4d6a-b681-e98443eaebb2.jpg)
Adding measurement d97f718 to history. Total: 2
LBFGS Accumulation History: 3 points
th(0)=-122.85771754941841;dx=-8.06480383062227E-6
New Minimum: -122.85771754941841 > -143.4266794525643
END: th(3628800.0000000005)=-143.4266794525643; dx=-3.5941799149986197E-6 evalInputDelta=20.568961903145876
Fitness changed from -122.85771754941841 to -143.4266794525643
Iteration 3 complete. Error: -143.4266794525643 Total: 9.2629; Orientation: 0.1028; Line Search: 5.7270
<a id="p-7"></a>Iteration 3
<a id="p-6"></a>![Iteration 3](etc/ac04083e-a114-47e1-8894-fcd35813bfdb.jpg)
Adding measurement 3e608524 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.056e+04, gradient 2.285e-03, dot -0.552; [d25f62d6-4364-4565-bb86-e650de9fb6eb = 1.000/1.000e+00]
Orientation rejected. Popping history element from -143.4266794525643, -122.85771754941841, -105.01705704029361, -105.01702529393111
LBFGS Accumulation History: 3 points
Removed measurement 3e608524 to history. Total: 3
th(0)=-143.4266794525643;dx=-5.222448744392047E-6
New Minimum: -143.4266794525643 > -163.16530706293594
END: th(7818012.603187701)=-163.16530706293594; dx=-9.337055080924987E-7 evalInputDelta=19.73862761037165
Fitness changed from -143.4266794525643 to -163.16530706293594
Iteration 4 complete. Error: -163.16530706293594 Total: 11.1419; Orientation: 1.9709; Line Search: 5.8951
<a id="p-9"></a>Iteration 4
<a id="p-8"></a>![Iteration 4](etc/44bfa948-43fe-4321-a8d3-d97cf63ca9b6.jpg)
Adding measurement 3270d9e4 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.110e+04, gradient 2.469e-03, dot -0.301; [d25f62d6-4364-4565-bb86-e650de9fb6eb = 1.000/1.000e+00]
Orientation rejected. Popping history element from -163.16530706293594, -122.85771754941841, -105.01705704029361, -105.01702529393111
LBFGS Accumulation History: 3 points
Removed measurement 3270d9e4 to history. Total: 3
th(0)=-163.16530706293594;dx=-6.077957339849894E-6
Armijo: th(1.6843397559414055E7)=-161.45152428091117; dx=1.5064453435784095E-6 evalInputDelta=-1.713782782024765
New Minimum: -163.16530706293594 > -175.85239442538207
WOLF (strong): th(8421698.779707028)=-175.85239442538207; dx=9.541211865527113E-7 evalInputDelta=12.687087362446135
END: th(2807232.926569009)=-175.38239017739588; dx=-2.3879216862404173E-6 evalInputDelta=12.217083114459939
Fitness changed from -163.16530706293594 to -175.85239442538207
Iteration 5 complete. Error: -175.85239442538207 Total: 17.5926; Orientation: 1.8228; Line Search: 11.8138
<a id="p-11"></a>Iteration 5
<a id="p-10"></a>![Iteration 5](etc/e5d29883-0317-40cc-9a9c-6525e6ac6c6a.jpg)
Adding measurement 23b865ae to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.328e+04, gradient 2.622e-03, dot -0.221; [d25f62d6-4364-4565-bb86-e650de9fb6eb = 1.000/1.000e+00]
Orientation rejected. Popping history element from -175.85239442538207, -122.85771754941841, -105.01705704029361, -105.01702529393111
LBFGS Accumulation History: 3 points
Removed measurement 23b865ae to history. Total: 3
th(0)=-175.85239442538207;dx=-6.848961954826907E-6
New Minimum: -175.85239442538207 > -194.9035771127561
WOLF (strong): th(6048000.000000001)=-194.9035771127561; dx=2.9957570583166896E-7 evalInputDelta=19.051182687374023
END: th(3024000.0000000005)=-191.50677951109432; dx=-2.944712658160536E-6 evalInputDelta=15.65438508571225
Fitness changed from -175.85239442538207 to -194.9035771127561
Iteration 6 complete. Error: -194.9035771127561 Total: 13.9857; Orientation: 1.8550; Line Search: 8.8766
Adding measurement 388ca784 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.449e+04, gradient 1.983e-03, dot -0.388; [d25f62d6-4364-4565-bb86-e650de9fb6eb = 1.000/1.000e+00]
Orientation rejected. Popping history element from -194.9035771127561, -122.85771754941841, -105.01705704029361, -105.01702529393111
LBFGS Accumulation History: 3 points
Removed measurement 388ca784 to history. Total: 3
th(0)=-194.9035771127561;dx=-3.931236121243794E-6
New Minimum: -194.9035771127561 > -206.05250325879746
WOLF (strong): th(6515010.502656418)=-206.05250325879746; dx=5.140028649585442E-8 evalInputDelta=11.148926146041362
END: th(3257505.251328209)=-204.08812223352834; dx=-1.5994981519708724E-6 evalInputDelta=9.184545120772242
Fitness changed from -194.9035771127561 to -206.05250325879746
Iteration 7 complete. Error: -206.05250325879746 Total: 13.3177; Orientation: 1.6935; Line Search: 8.7094
Adding measurement 1e928827 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.959e+04, gradient 1.895e-03, dot -0.403; [d25f62d6-4364-4565-bb86-e650de9fb6eb = 1.000/1.000e+00]
Orientation rejected. Popping history element from -206.05250325879746, -122.85771754941841, -105.01705704029361, -105.01702529393111
LBFGS Accumulation History: 3 points
Removed measurement 1e928827 to history. Total: 3
th(0)=-206.05250325879746;dx=-3.5721827150423707E-6
New Minimum: -206.05250325879746 > -215.1563634509272
WOLF (strong): th(7018082.316422524)=-215.1563634509272; dx=4.2391160238348954E-7 evalInputDelta=9.10386019212973
END: th(3509041.158211262)=-214.60869320534198; dx=-1.170740810392502E-6 evalInputDelta=8.55618994654452
Fitness changed from -206.05250325879746 to -215.1563634509272
Iteration 8 complete. Error: -215.1563634509272 Total: 12.8757; Orientation: 1.7072; Line Search: 8.5309
Adding measurement 6cf4b8ef to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.311e+04, gradient 1.926e-03, dot -0.372; [d25f62d6-4364-4565-bb86-e650de9fb6eb = 1.000/1.000e+00]
Orientation rejected. Popping history element from -215.1563634509272, -122.85771754941841, -105.01705704029361, -105.01702529393111
LBFGS Accumulation History: 3 points
Removed measurement 6cf4b8ef to history. Total: 3
th(0)=-215.1563634509272;dx=-3.7103074767493094E-6
New Minimum: -215.1563634509272 > -223.581089250752
WOLF (strong): th(7560000.000000003)=-223.581089250752; dx=8.235980571325972E-7 evalInputDelta=8.424725799824813
New Minimum: -223.581089250752 > -224.29784517672815
END: th(3780000.0000000014)=-224.29784517672815; dx=-9.948547985958882E-7 evalInputDelta=9.141481725800958
Fitness changed from -215.1563634509272 to -224.29784517672815
Iteration 9 complete. Error: -224.29784517672815 Total: 13.3165; Orientation: 1.7074; Line Search: 8.9056
Adding measurement 47ec1f84 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 4.087e+04, gradient 1.326e-03, dot -0.586; [d25f62d6-4364-4565-bb86-e650de9fb6eb = 1.000/1.000e+00]
Orientation rejected. Popping history element from -224.29784517672815, -122.85771754941841, -105.01705704029361, -105.01702529393111
LBFGS Accumulation History: 3 points
Removed measurement 47ec1f84 to history. Total: 3
th(0)=-224.29784517672815;dx=-1.7537800800519335E-6
New Minimum: -224.29784517672815 > -232.58344107649953
END: th(8143763.128320524)=-232.58344107649953; dx=-5.422609615152457E-7 evalInputDelta=8.28559589977138
Fitness changed from -224.29784517672815 to -232.58344107649953
Iteration 10 complete. Error: -232.58344107649953 Total: 10.3875; Orientation: 1.6984; Line Search: 5.8724
<a id="p-13"></a>Iteration 10
<a id="p-12"></a>![Iteration 10](etc/764ced87-5d9f-4e6b-a65a-a87ddb2c1207.jpg)
Final threshold in iteration 11: -232.58344107649953 (> -Infinity) after 149.479s (< 5400.000s)

Returns

    -232.58344107649953