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 148.75 seconds (2.347 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: 457669550030000
Reset training subject: 457672412482300
Adding measurement 8185deb to history. Total: 0
LBFGS Accumulation History: 1 points
Constructing line search parameters: GD+Trust
th(0)=-103.82098493331877;dx=-1.5084398514447663E-5
New Minimum: -103.82098493331877 > -103.82101704540615
END: th(2.154434690031884)=-103.82101704540615; dx=-1.2248327561216534E-5 evalInputDelta=3.2112087382074606E-5
Fitness changed from -103.82098493331877 to -103.82101704540615
Iteration 1 complete. Error: -103.82101704540615 Total: 13.9626; Orientation: 0.1050; Line Search: 5.6103
<a id="p-3"></a>Iteration 1
<a id="p-2"></a>![Iteration 1](etc/0a68d99c-dcf1-4f91-b810-7fd07c89b252.jpg)
Adding measurement 2aab59a to history. Total: 1
LBFGS Accumulation History: 2 points
th(0)=-103.82101704540615;dx=-1.2268793389151603E-5
New Minimum: -103.82101704540615 > -103.82107591754055
WOLFE (weak): th(4.641588833612779)=-103.82107591754055; dx=-1.2252087901381656E-5 evalInputDelta=5.887213440303185E-5
New Minimum: -103.82107591754055 > -103.82113478964158
WOLFE (weak): th(9.283177667225559)=-103.82113478964158; dx=-1.2245563506201696E-5 evalInputDelta=1.1774423542476598E-4
New Minimum: -103.82113478964158 > -103.82137562970719
WOLFE (weak): th(27.849533001676676)=-103.82137562970719; dx=-1.220902412656805E-5 evalInputDelta=3.5858430103985484E-4
New Minimum: -103.82137562970719 > -103.82245137517941
WOLFE (weak): th(111.3981320067067)=-103.82245137517941; dx=-1.2200894148947172E-5 evalInputDelta=0.0014343297732608562
New Minimum: -103.82245137517941 > -103.82818849612764
WOLFE (weak): th(556.9906600335335)=-103.82818849612764; dx=-1.2229092757752393E-5 evalInputDelta=0.007171450721486394
New Minimum: -103.82818849612764 > -103.86404902187246
WOLFE (weak): th(3341.9439602012008)=-103.86404902187246; dx=-1.2195148813512171E-5 evalInputDelta=0.04303197646630963
New Minimum: -103.86404902187246 > -104.12162726270918
WOLFE (weak): th(23393.607721408407)=-104.12162726270918; dx=-1.217220738228044E-5 evalInputDelta=0.3006102173030314
New Minimum: -104.12162726270918 > -106.18344361636414
WOLFE (weak): th(187148.86177126726)=-106.18344361636414; dx=-1.1711713589982438E-5 evalInputDelta=2.362426570957993
New Minimum: -106.18344361636414 > -121.34618300516392
END: th(1684339.7559414054)=-121.34618300516392; dx=-7.583335555378311E-6 evalInputDelta=17.52516595975777
Fitness changed from -103.82101704540615 to -121.34618300516392
Iteration 2 complete. Error: -121.34618300516392 Total: 31.8425; Orientation: 0.1040; Line Search: 28.5088
<a id="p-5"></a>Iteration 2
<a id="p-4"></a>![Iteration 2](etc/bb7787df-c546-4d42-be25-b1b9a985a6c9.jpg)
Adding measurement 79ac67d2 to history. Total: 2
LBFGS Accumulation History: 3 points
th(0)=-121.34618300516392;dx=-7.686270908044645E-6
New Minimum: -121.34618300516392 > -140.80107779393808
END: th(3628800.0000000005)=-140.80107779393808; dx=-3.2766115834002467E-6 evalInputDelta=19.454894788774155
Fitness changed from -121.34618300516392 to -140.80107779393808
Iteration 3 complete. Error: -140.80107779393808 Total: 9.1479; Orientation: 0.1037; Line Search: 5.8498
<a id="p-7"></a>Iteration 3
<a id="p-6"></a>![Iteration 3](etc/4bf8744c-7d1a-48fb-90c3-0e4ce7b43570.jpg)
Adding measurement a0fa41b to history. Total: 3
Rejected: LBFGS Orientation magnitude: 9.454e+03, gradient 2.217e-03, dot -0.532; [310de9eb-dc6a-4e0d-8fa8-dc9a3c9b098a = 1.000/1.000e+00]
Orientation rejected. Popping history element from -140.80107779393808, -121.34618300516392, -103.82101704540615, -103.82098493331877
LBFGS Accumulation History: 3 points
Removed measurement a0fa41b to history. Total: 3
th(0)=-140.80107779393808;dx=-4.9087676129908305E-6
New Minimum: -140.80107779393808 > -158.5598008527168
END: th(7818012.603187701)=-158.5598008527168; dx=-7.256195103007059E-7 evalInputDelta=17.758723058778713
Fitness changed from -140.80107779393808 to -158.5598008527168
Iteration 4 complete. Error: -158.5598008527168 Total: 10.9839; Orientation: 1.8418; Line Search: 5.8638
<a id="p-9"></a>Iteration 4
<a id="p-8"></a>![Iteration 4](etc/ac3f0b53-75fd-40b8-a3bb-1d3c6831920b.jpg)
Adding measurement d6462f0 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 9.657e+03, gradient 2.433e-03, dot -0.284; [310de9eb-dc6a-4e0d-8fa8-dc9a3c9b098a = 1.000/1.000e+00]
Orientation rejected. Popping history element from -158.5598008527168, -121.34618300516392, -103.82101704540615, -103.82098493331877
LBFGS Accumulation History: 3 points
Removed measurement d6462f0 to history. Total: 3
th(0)=-158.5598008527168;dx=-5.912449760053806E-6
Armijo: th(1.6843397559414055E7)=-153.676031552986; dx=1.665712563589174E-6 evalInputDelta=-4.883769299730801
New Minimum: -158.5598008527168 > -169.4245201589799
WOLF (strong): th(8421698.779707028)=-169.4245201589799; dx=1.1944814591918864E-6 evalInputDelta=10.864719306263112
New Minimum: -169.4245201589799 > -170.22289757273523
END: th(2807232.926569009)=-170.22289757273523; dx=-2.172969602424089E-6 evalInputDelta=11.663096720018444
Fitness changed from -158.5598008527168 to -170.22289757273523
Iteration 5 complete. Error: -170.22289757273523 Total: 16.7752; Orientation: 1.7524; Line Search: 11.6881
<a id="p-11"></a>Iteration 5
<a id="p-10"></a>![Iteration 5](etc/47bdd0ea-ba57-40d2-8796-2216dc5ae8c8.jpg)
Adding measurement 56ee43b0 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.807e+04, gradient 1.726e-03, dot -0.552; [310de9eb-dc6a-4e0d-8fa8-dc9a3c9b098a = 1.000/1.000e+00]
Orientation rejected. Popping history element from -170.22289757273523, -121.34618300516392, -103.82101704540615, -103.82098493331877
LBFGS Accumulation History: 3 points
Removed measurement 56ee43b0 to history. Total: 3
th(0)=-170.22289757273523;dx=-2.9746354764892604E-6
New Minimum: -170.22289757273523 > -181.10344949687737
END: th(6048000.000000001)=-181.10344949687737; dx=-9.527330965847119E-7 evalInputDelta=10.88055192414214
Fitness changed from -170.22289757273523 to -181.10344949687737
Iteration 6 complete. Error: -181.10344949687737 Total: 10.6665; Orientation: 1.6953; Line Search: 5.5722
Adding measurement 5198a7f2 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.246e+04, gradient 1.875e-03, dot -0.467; [310de9eb-dc6a-4e0d-8fa8-dc9a3c9b098a = 1.000/1.000e+00]
Orientation rejected. Popping history element from -181.10344949687737, -121.34618300516392, -103.82101704540615, -103.82098493331877
LBFGS Accumulation History: 3 points
Removed measurement 5198a7f2 to history. Total: 3
th(0)=-181.10344949687737;dx=-3.5157872036179645E-6
New Minimum: -181.10344949687737 > -184.28220505984112
WOLF (strong): th(1.3030021005312836E7)=-184.28220505984112; dx=8.218807726186285E-7 evalInputDelta=3.178755562963744
New Minimum: -184.28220505984112 > -189.0957115619485
WOLF (strong): th(6515010.502656418)=-189.0957115619485; dx=1.357013317921581E-7 evalInputDelta=7.992262065071117
END: th(2171670.167552139)=-186.88491447285267; dx=-1.709309708666624E-6 evalInputDelta=5.781464975975297
Fitness changed from -181.10344949687737 to -189.0957115619485
Iteration 7 complete. Error: -189.0957115619485 Total: 15.6883; Orientation: 1.6964; Line Search: 11.0861
Adding measurement 4c3fb34e to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.394e+04, gradient 2.090e-03, dot -0.366; [310de9eb-dc6a-4e0d-8fa8-dc9a3c9b098a = 1.000/1.000e+00]
Orientation rejected. Popping history element from -189.0957115619485, -121.34618300516392, -103.82101704540615, -103.82098493331877
LBFGS Accumulation History: 3 points
Removed measurement 4c3fb34e to history. Total: 3
th(0)=-189.0957115619485;dx=-4.352908270206765E-6
New Minimum: -189.0957115619485 > -199.14494912459298
END: th(4678721.544281682)=-199.14494912459298; dx=-2.672547366855489E-8 evalInputDelta=10.049237562644493
Fitness changed from -189.0957115619485 to -199.14494912459298
Iteration 8 complete. Error: -199.14494912459298 Total: 9.8931; Orientation: 1.7177; Line Search: 5.4598
Adding measurement 54671cbd to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.104e+04, gradient 1.701e-03, dot -0.477; [310de9eb-dc6a-4e0d-8fa8-dc9a3c9b098a = 1.000/1.000e+00]
Orientation rejected. Popping history element from -199.14494912459298, -121.34618300516392, -103.82101704540615, -103.82098493331877
LBFGS Accumulation History: 3 points
Removed measurement 54671cbd to history. Total: 3
th(0)=-199.14494912459298;dx=-2.8841017047659426E-6
New Minimum: -199.14494912459298 > -203.41733507919574
WOLF (strong): th(1.0080000000000002E7)=-203.41733507919574; dx=7.85797148981139E-7 evalInputDelta=4.272385954602754
New Minimum: -203.41733507919574 > -206.18291513615645
END: th(5040000.000000001)=-206.18291513615645; dx=-1.911468217437906E-7 evalInputDelta=7.037966011563469
Fitness changed from -199.14494912459298 to -206.18291513615645
Iteration 9 complete. Error: -206.18291513615645 Total: 13.1552; Orientation: 1.8190; Line Search: 8.6924
Adding measurement 1b9bf84 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.471e+04, gradient 1.672e-03, dot -0.473; [310de9eb-dc6a-4e0d-8fa8-dc9a3c9b098a = 1.000/1.000e+00]
Orientation rejected. Popping history element from -206.18291513615645, -121.34618300516392, -103.82101704540615, -103.82098493331877
LBFGS Accumulation History: 3 points
Removed measurement 1b9bf84 to history. Total: 3
th(0)=-206.18291513615645;dx=-2.794335519144773E-6
New Minimum: -206.18291513615645 > -208.3999090792156
WOLF (strong): th(1.0858350837760696E7)=-208.3999090792156; dx=9.093218473173278E-7 evalInputDelta=2.216993943059151
New Minimum: -208.3999090792156 > -212.52119241572683
WOLF (strong): th(5429175.418880348)=-212.52119241572683; dx=8.492842654780403E-8 evalInputDelta=6.338277279570377
END: th(1809725.1396267826)=-210.29740149944615; dx=-1.6433674641989254E-6 evalInputDelta=4.1144863632897
Fitness changed from -206.18291513615645 to -212.52119241572683
Iteration 10 complete. Error: -212.52119241572683 Total: 16.0543; Orientation: 1.8672; Line Search: 11.5600
<a id="p-13"></a>Iteration 10
<a id="p-12"></a>![Iteration 10](etc/9dfcfacc-8d9e-45a9-bf40-2db96c15ea7a.jpg)
Final threshold in iteration 11: -212.52119241572683 (> -Infinity) after 148.753s (< 5400.000s)

Returns

    -212.52119241572683