Iteration 1 Iteration 1

Iteration 2 Iteration 2

Iteration 3 Iteration 3

Iteration 4 Iteration 4

Iteration 5 Iteration 5

Iteration 10 Iteration 10

Iteration 15 Iteration 15

BasicOptimizer.scala:89 executed in 60.98 seconds (1.254 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: 146078257669800
Reset training subject: 146079171101100
Adding measurement 23b12124 to history. Total: 0
LBFGS Accumulation History: 1 points
Constructing line search parameters: GD+Trust
th(0)=-258.7464824640134;dx=-0.053382094392836296
New Minimum: -258.7464824640134 > -258.8746831239007
WOLFE (weak): th(2.154434690031884)=-258.8746831239007; dx=-0.05214635506734896 evalInputDelta=0.12820065988728402
New Minimum: -258.8746831239007 > -259.0029108185852
WOLFE (weak): th(4.308869380063768)=-259.0029108185852; dx=-0.052182472126319726 evalInputDelta=0.25642835457176716
New Minimum: -259.0029108185852 > -259.51607609163636
WOLFE (weak): th(12.926608140191302)=-259.51607609163636; dx=-0.05223164154328146 evalInputDelta=0.7695936276229531
New Minimum: -259.51607609163636 > -261.83067942374515
WOLFE (weak): th(51.70643256076521)=-261.83067942374515; dx=-0.05235323863564224 evalInputDelta=3.0841969597317416
New Minimum: -261.83067942374515 > -274.3637953293036
WOLFE (weak): th(258.53216280382605)=-274.3637953293036; dx=-0.05267632700022157 evalInputDelta=15.617312865290216
New Minimum: -274.3637953293036 > -348.4958975726974
END: th(1551.1929768229563)=-348.4958975726974; dx=-0.04098385232116207 evalInputDelta=89.74941510868399
Fitness changed from -258.7464824640134 to -348.4958975726974
Iteration 1 complete. Error: -348.4958975726974 Total: 9.5266; Orientation: 0.0141; Line Search: 6.8528
<a id="p-3"></a>Iteration 1
<a id="p-2"></a>![Iteration 1](etc/244321e5-c5be-4cf1-88ba-60732c8fec11.jpg)
Adding measurement 2e480af6 to history. Total: 1
LBFGS Accumulation History: 2 points
th(0)=-348.4958975726974;dx=-0.05413212704687101
New Minimum: -348.4958975726974 > -481.6643508450672
END: th(3341.943960201201)=-481.6643508450672; dx=-0.020518722007675443 evalInputDelta=133.1684532723698
Fitness changed from -348.4958975726974 to -481.6643508450672
Iteration 2 complete. Error: -481.6643508450672 Total: 2.6488; Orientation: 0.0155; Line Search: 1.7446
<a id="p-5"></a>Iteration 2
<a id="p-4"></a>![Iteration 2](etc/56315e8a-e294-4574-ae3b-b4eca7607993.jpg)
Adding measurement 3318b890 to history. Total: 2
LBFGS Accumulation History: 3 points
th(0)=-481.6643508450672;dx=-0.051287140321403066
New Minimum: -481.6643508450672 > -604.3357148555759
END: th(7200.000000000001)=-604.3357148555759; dx=-0.00497318536588831 evalInputDelta=122.67136401050874
Fitness changed from -481.6643508450672 to -604.3357148555759
Iteration 3 complete. Error: -604.3357148555759 Total: 2.8766; Orientation: 0.0146; Line Search: 1.9456
<a id="p-7"></a>Iteration 3
<a id="p-6"></a>![Iteration 3](etc/d0b3b650-2151-4d89-a349-5e7ea7d3ef28.jpg)
Adding measurement 2cfbd71e to history. Total: 3
Rejected: LBFGS Orientation magnitude: 4.595e+03, gradient 2.543e-01, dot -0.197; [06000ea5-14c4-48b0-8add-376b14510881 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -604.3357148555759, -481.6643508450672, -348.4958975726974, -258.7464824640134
LBFGS Accumulation History: 3 points
Removed measurement 2cfbd71e to history. Total: 3
th(0)=-604.3357148555759;dx=-0.06431769970561854
Armijo: th(15511.929768229566)=-550.3255002723388; dx=0.004181579973725632 evalInputDelta=-54.01021458323714
New Minimum: -604.3357148555759 > -697.5529773787795
WOLF (strong): th(7755.964884114783)=-697.5529773787795; dx=0.0015889462211296013 evalInputDelta=93.21726252320354
New Minimum: -697.5529773787795 > -736.1623886752161
END: th(2585.3216280382608)=-736.1623886752161; dx=-0.029817007670111986 evalInputDelta=131.82667381964018
Fitness changed from -604.3357148555759 to -736.1623886752161
Iteration 4 complete. Error: -736.1623886752161 Total: 4.6747; Orientation: 0.3038; Line Search: 3.4297
<a id="p-9"></a>Iteration 4
<a id="p-8"></a>![Iteration 4](etc/31504c72-be4d-4907-b8f3-48cdbdf21ee3.jpg)
Adding measurement 35eb78b7 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 7.414e+03, gradient 2.110e-01, dot -0.272; [06000ea5-14c4-48b0-8add-376b14510881 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -736.1623886752161, -481.6643508450672, -348.4958975726974, -258.7464824640134
LBFGS Accumulation History: 3 points
Removed measurement 35eb78b7 to history. Total: 3
th(0)=-736.1623886752161;dx=-0.044458264488733884
New Minimum: -736.1623886752161 > -856.5352444587438
END: th(5569.9066003353355)=-856.5352444587438; dx=-0.013732886450962399 evalInputDelta=120.37285578352771
Fitness changed from -736.1623886752161 to -856.5352444587438
Iteration 5 complete. Error: -856.5352444587438 Total: 2.9565; Orientation: 0.2997; Line Search: 1.7505
<a id="p-11"></a>Iteration 5
<a id="p-10"></a>![Iteration 5](etc/547471b2-573e-430d-b93b-49f3794fe221.jpg)
Adding measurement 259ca335 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 8.904e+03, gradient 2.503e-01, dot -0.236; [06000ea5-14c4-48b0-8add-376b14510881 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -856.5352444587438, -481.6643508450672, -348.4958975726974, -258.7464824640134
LBFGS Accumulation History: 3 points
Removed measurement 259ca335 to history. Total: 3
th(0)=-856.5352444587438;dx=-0.06242373519035434
Armijo: th(12000.000000000002)=-804.843191249078; dx=0.0035465185288090393 evalInputDelta=-51.6920532096658
New Minimum: -856.5352444587438 > -934.7853697507252
END: th(6000.000000000001)=-934.7853697507252; dx=-0.002975882641265064 evalInputDelta=78.25012529198136
Fitness changed from -856.5352444587438 to -934.7853697507252
Iteration 6 complete. Error: -934.7853697507252 Total: 4.0488; Orientation: 0.3064; Line Search: 2.7848
Adding measurement 7458477c to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.076e+04, gradient 2.722e-01, dot -0.215; [06000ea5-14c4-48b0-8add-376b14510881 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -934.7853697507252, -481.6643508450672, -348.4958975726974, -258.7464824640134
LBFGS Accumulation History: 3 points
Removed measurement 7458477c to history. Total: 3
th(0)=-934.7853697507252;dx=-0.07373745314562308
Armijo: th(12926.608140191305)=-800.1209283602074; dx=0.008591382650906965 evalInputDelta=-134.66444139051782
New Minimum: -934.7853697507252 > -1024.8920674880844
WOLF (strong): th(6463.304070095653)=-1024.8920674880844; dx=0.0055709477218451875 evalInputDelta=90.10669773735924
New Minimum: -1024.8920674880844 > -1066.4635483690945
END: th(2154.434690031884)=-1066.4635483690945; dx=-0.03494256988227894 evalInputDelta=131.67817861836932
Fitness changed from -934.7853697507252 to -1066.4635483690945
Iteration 7 complete. Error: -1066.4635483690945 Total: 4.6270; Orientation: 0.2993; Line Search: 3.4725
Adding measurement 5170ee4f to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.778e+04, gradient 2.147e-01, dot -0.303; [06000ea5-14c4-48b0-8add-376b14510881 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -1066.4635483690945, -481.6643508450672, -348.4958975726974, -258.7464824640134
LBFGS Accumulation History: 3 points
Removed measurement 5170ee4f to history. Total: 3
th(0)=-1066.4635483690945;dx=-0.04604099927623977
New Minimum: -1066.4635483690945 > -1187.0937726228708
END: th(4641.58883361278)=-1187.0937726228708; dx=-0.0186018097239349 evalInputDelta=120.6302242537763
Fitness changed from -1066.4635483690945 to -1187.0937726228708
Iteration 8 complete. Error: -1187.0937726228708 Total: 2.9038; Orientation: 0.3109; Line Search: 1.7241
Adding measurement 1b359ef to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.500e+04, gradient 2.333e-01, dot -0.289; [06000ea5-14c4-48b0-8add-376b14510881 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -1187.0937726228708, -481.6643508450672, -348.4958975726974, -258.7464824640134
LBFGS Accumulation History: 3 points
Removed measurement 1b359ef to history. Total: 3
th(0)=-1187.0937726228708;dx=-0.05391771881753195
Armijo: th(10000.000000000004)=-1156.6545508491288; dx=0.002319013209242079 evalInputDelta=-30.43922177374202
New Minimum: -1187.0937726228708 > -1271.3002694092377
END: th(5000.000000000002)=-1271.3002694092377; dx=-0.006799382196592786 evalInputDelta=84.20649678636687
Fitness changed from -1187.0937726228708 to -1271.3002694092377
Iteration 9 complete. Error: -1271.3002694092377 Total: 3.8780; Orientation: 0.2740; Line Search: 2.7964
Adding measurement 23dd51ab to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.851e+04, gradient 2.729e-01, dot -0.232; [06000ea5-14c4-48b0-8add-376b14510881 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -1271.3002694092377, -481.6643508450672, -348.4958975726974, -258.7464824640134
LBFGS Accumulation History: 3 points
Removed measurement 23dd51ab to history. Total: 3
th(0)=-1271.3002694092377;dx=-0.07433248673026699
Armijo: th(10772.173450159424)=-1109.580382396877; dx=0.006399417063717945 evalInputDelta=-161.7198870123607
New Minimum: -1271.3002694092377 > -1307.9048130502465
WOLF (strong): th(5386.086725079712)=-1307.9048130502465; dx=0.006802598557178049 evalInputDelta=36.60454364100883
New Minimum: -1307.9048130502465 > -1369.2631686421716
END: th(1795.3622416932374)=-1369.2631686421716; dx=-0.032163770950951784 evalInputDelta=97.96289923293398
Fitness changed from -1271.3002694092377 to -1369.2631686421716
Iteration 10 complete. Error: -1369.2631686421716 Total: 4.6595; Orientation: 0.2814; Line Search: 3.5361
<a id="p-13"></a>Iteration 10
<a id="p-12"></a>![Iteration 10](etc/13c342ff-a5e6-4854-a562-51ced3c62d3e.jpg)
Adding measurement e51dc66 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 5.959e+04, gradient 2.112e-01, dot -0.332; [06000ea5-14c4-48b0-8add-376b14510881 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -1369.2631686421716, -481.6643508450672, -348.4958975726974, -258.7464824640134
LBFGS Accumulation History: 3 points
Removed measurement e51dc66 to history. Total: 3
th(0)=-1369.2631686421716;dx=-0.044360222532233304
New Minimum: -1369.2631686421716 > -1459.317220483607
END: th(3867.990694677318)=-1459.317220483607; dx=-0.018959120106160077 evalInputDelta=90.05405184143524
Fitness changed from -1369.2631686421716 to -1459.317220483607
Iteration 11 complete. Error: -1459.317220483607 Total: 2.9855; Orientation: 0.2991; Line Search: 1.7489
Adding measurement 34d68a78 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.089e+05, gradient 2.233e-01, dot -0.338; [06000ea5-14c4-48b0-8add-376b14510881 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -1459.317220483607, -481.6643508450672, -348.4958975726974, -258.7464824640134
LBFGS Accumulation History: 3 points
Removed measurement 34d68a78 to history. Total: 3
th(0)=-1459.317220483607;dx=-0.049547072056598015
New Minimum: -1459.317220483607 > -1463.2563001743747
END: th(8333.33333333334)=-1463.2563001743747; dx=-0.0012485337715399285 evalInputDelta=3.9390796907678123
Fitness changed from -1459.317220483607 to -1463.2563001743747
Iteration 12 complete. Error: -1463.2563001743747 Total: 3.0118; Orientation: 0.2658; Line Search: 1.6852
Adding measurement 172f4d94 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 7.322e+04, gradient 2.921e-01, dot -0.225; [06000ea5-14c4-48b0-8add-376b14510881 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -1463.2563001743747, -481.6643508450672, -348.4958975726974, -258.7464824640134
LBFGS Accumulation History: 3 points
Removed measurement 172f4d94 to history. Total: 3
th(0)=-1463.2563001743747;dx=-0.08434462351502664
Armijo: th(17953.62241693238)=-1112.7471635551358; dx=0.006601197092437604 evalInputDelta=-350.5091366192389
Armijo: th(8976.81120846619)=-1436.449877301676; dx=0.013842511286083159 evalInputDelta=-26.806422872698704
New Minimum: -1463.2563001743747 > -1647.646730946898
END: th(2992.2704028220633)=-1647.646730946898; dx=-0.024259434764299505 evalInputDelta=184.39043077252336
Fitness changed from -1463.2563001743747 to -1647.646730946898
Iteration 13 complete. Error: -1647.646730946898 Total: 4.5823; Orientation: 0.2779; Line Search: 3.4568
Adding measurement 3f2522c0 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.605e+06, gradient 2.389e-01, dot -0.325; [06000ea5-14c4-48b0-8add-376b14510881 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -1647.646730946898, -481.6643508450672, -348.4958975726974, -258.7464824640134
LBFGS Accumulation History: 3 points
Removed measurement 3f2522c0 to history. Total: 3
th(0)=-1647.646730946898;dx=-0.05701265703254326
New Minimum: -1647.646730946898 > -1741.9998564867908
END: th(6446.651157795532)=-1741.9998564867908; dx=-0.002735044624553362 evalInputDelta=94.35312553989274
Fitness changed from -1647.646730946898 to -1741.9998564867908
Iteration 14 complete. Error: -1741.9998564867908 Total: 2.9033; Orientation: 0.2831; Line Search: 1.7661
Adding measurement a9de019 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.801e+08, gradient 2.942e-01, dot -0.255; [06000ea5-14c4-48b0-8add-376b14510881 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -1741.9998564867908, -481.6643508450672, -348.4958975726974, -258.7464824640134
LBFGS Accumulation History: 3 points
Removed measurement a9de019 to history. Total: 3
th(0)=-1741.9998564867908;dx=-0.0861670979456986
Armijo: th(13888.888888888901)=-1397.1323308835138; dx=0.010002047283999803 evalInputDelta=-344.86752560327704
Armijo: th(6944.444444444451)=-1718.726999846107; dx=0.01806617626037419 evalInputDelta=-23.272856640683813
New Minimum: -1741.9998564867908 > -1878.4886212058884
END: th(2314.814814814817)=-1878.4886212058884; dx=-0.027794972661927278 evalInputDelta=136.48876471909762
Fitness changed from -1741.9998564867908 to -1878.4886212058884
Iteration 15 complete. Error: -1878.4886212058884 Total: 4.5903; Orientation: 0.2712; Line Search: 3.3796
<a id="p-15"></a>Iteration 15
<a id="p-14"></a>![Iteration 15](etc/f51676c1-62d6-40db-8b6b-8feb66c6bf7a.jpg)
Final threshold in iteration 16: -1878.4886212058884 (> -Infinity) after 60.975s (< 5400.000s)

Returns

    -1878.4886212058884