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 1219.66 seconds (154.509 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: 447975656855500
Reset training subject: 448001711956800
Adding measurement 41395d53 to history. Total: 0
LBFGS Accumulation History: 1 points
Constructing line search parameters: GD+Trust
th(0)=-8.131921312962376;dx=-4.493130764159688E-7
New Minimum: -8.131921312962376 > -8.13192198246981
WOLFE (weak): th(2.154434690031884)=-8.13192198246981; dx=-4.3758576408073513E-7 evalInputDelta=6.695074343809893E-7
New Minimum: -8.13192198246981 > -8.13192332148451
WOLFE (weak): th(4.308869380063768)=-8.13192332148451; dx=-4.3599882973957557E-7 evalInputDelta=2.008522134389068E-6
New Minimum: -8.13192332148451 > -8.131929681801335
WOLFE (weak): th(12.926608140191302)=-8.131929681801335; dx=-4.37584819967055E-7 evalInputDelta=8.368838958716651E-6
New Minimum: -8.131929681801335 > -8.131956796780406
WOLFE (weak): th(51.70643256076521)=-8.131956796780406; dx=-4.36847785254427E-7 evalInputDelta=3.548381802964684E-5
New Minimum: -8.131956796780406 > -8.13209839575778
WOLFE (weak): th(258.53216280382605)=-8.13209839575778; dx=-4.3715998516801325E-7 evalInputDelta=1.7708279540329386E-4
New Minimum: -8.13209839575778 > -8.132987098998676
WOLFE (weak): th(1551.1929768229563)=-8.132987098998676; dx=-4.374964572089168E-7 evalInputDelta=0.0010657860362996985
New Minimum: -8.132987098998676 > -8.139385239030013
WOLFE (weak): th(10858.350837760694)=-8.139385239030013; dx=-4.3730254280193097E-7 evalInputDelta=0.007463926067636351
New Minimum: -8.139385239030013 > -8.191640023860986
WOLFE (weak): th(86866.80670208555)=-8.191640023860986; dx=-4.365424445189319E-7 evalInputDelta=0.05971871089860947
New Minimum: -8.191640023860986 > -8.666951670197497
WOLFE (weak): th(781801.26031877)=-8.666951670197497; dx=-4.3126437518631337E-7 evalInputDelta=0.5350303572351205
New Minimum: -8.666951670197497 > -12.809335324290771
END: th(7818012.6031877)=-12.809335324290771; dx=-3.0128605236017333E-7 evalInputDelta=4.677414011328395
Fitness changed from -8.131921312962376 to -12.809335324290771
Iteration 1 complete. Error: -12.809335324290771 Total: 338.1357; Orientation: 0.1078; Line Search: 263.4138
<a id="p-3"></a>Iteration 1
<a id="p-2"></a>![Iteration 1](etc/6d6d692c-84ce-48a6-8807-39c477049829.jpg)
Adding measurement 3a89fa00 to history. Total: 1
LBFGS Accumulation History: 2 points
th(0)=-12.809335324290771;dx=-3.840204258890331E-7
New Minimum: -12.809335324290771 > -19.693125283558192
END: th(1.684339755941405E7)=-19.693125283558192; dx=-1.5705918760762302E-7 evalInputDelta=6.883789959267421
Fitness changed from -12.809335324290771 to -19.693125283558192
Iteration 2 complete. Error: -19.693125283558192 Total: 75.9649; Orientation: 0.1143; Line Search: 47.6469
<a id="p-5"></a>Iteration 2
<a id="p-4"></a>![Iteration 2](etc/8a19fc42-63b5-4d0f-a13c-955caa8636b6.jpg)
Adding measurement 568c1d51 to history. Total: 2
LBFGS Accumulation History: 3 points
th(0)=-19.693125283558192;dx=-3.289380056061727E-7
New Minimum: -19.693125283558192 > -27.03172905146454
END: th(3.6288E7)=-27.03172905146454; dx=-3.996390687709869E-8 evalInputDelta=7.338603767906349
Fitness changed from -19.693125283558192 to -27.03172905146454
Iteration 3 complete. Error: -27.03172905146454 Total: 74.0406; Orientation: 0.1097; Line Search: 48.6734
<a id="p-7"></a>Iteration 3
<a id="p-6"></a>![Iteration 3](etc/59424f8b-1bb1-4ea2-88f1-ecbaba55944d.jpg)
Adding measurement 2d091823 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 5.010e+04, gradient 5.724e-04, dot -0.391; [9ad58374-fa02-45ca-b3a6-f6b1118a2bd5 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -27.03172905146454, -19.693125283558192, -12.809335324290771, -8.131921312962376
LBFGS Accumulation History: 3 points
Removed measurement 2d091823 to history. Total: 3
th(0)=-27.03172905146454;dx=-3.2719309114701575E-7
New Minimum: -27.03172905146454 > -31.91034715738559
WOLF (strong): th(7.8180126031877E7)=-31.91034715738559; dx=2.8046370616310798E-8 evalInputDelta=4.878618105921049
New Minimum: -31.91034715738559 > -33.83221367207201
WOLF (strong): th(3.90900630159385E7)=-33.83221367207201; dx=1.3356606860592213E-8 evalInputDelta=6.800484620607467
END: th(1.3030021005312832E7)=-32.0750147650635; dx=-1.562305758394951E-7 evalInputDelta=5.043285713598959
Fitness changed from -27.03172905146454 to -33.83221367207201
Iteration 4 complete. Error: -33.83221367207201 Total: 131.5181; Orientation: 2.0427; Line Search: 102.2635
<a id="p-9"></a>Iteration 4
<a id="p-8"></a>![Iteration 4](etc/086d88b1-f4b6-462f-a3de-220de007ac76.jpg)
Adding measurement 15599415 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 4.395e+04, gradient 5.474e-04, dot -0.325; [9ad58374-fa02-45ca-b3a6-f6b1118a2bd5 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -33.83221367207201, -19.693125283558192, -12.809335324290771, -8.131921312962376
LBFGS Accumulation History: 3 points
Removed measurement 15599415 to history. Total: 3
th(0)=-33.83221367207201;dx=-2.9927579150763997E-7
New Minimum: -33.83221367207201 > -40.5472587029524
END: th(2.807232926569009E7)=-40.5472587029524; dx=-1.160979878443611E-8 evalInputDelta=6.71504503088039
Fitness changed from -33.83221367207201 to -40.5472587029524
Iteration 5 complete. Error: -40.5472587029524 Total: 78.8697; Orientation: 2.0699; Line Search: 50.9628
<a id="p-11"></a>Iteration 5
<a id="p-10"></a>![Iteration 5](etc/fb988f20-f62b-4f22-a1d2-a6de757a81a5.jpg)
Adding measurement 42056ff1 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 5.652e+04, gradient 4.610e-04, dot -0.364; [9ad58374-fa02-45ca-b3a6-f6b1118a2bd5 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -40.5472587029524, -19.693125283558192, -12.809335324290771, -8.131921312962376
LBFGS Accumulation History: 3 points
Removed measurement 42056ff1 to history. Total: 3
th(0)=-40.5472587029524;dx=-2.1248886936659977E-7
New Minimum: -40.5472587029524 > -42.50612124722653
WOLF (strong): th(6.048000000000001E7)=-42.50612124722653; dx=4.5719193274432434E-8 evalInputDelta=1.9588625442741332
New Minimum: -42.50612124722653 > -44.54551036556467
WOLF (strong): th(3.0240000000000004E7)=-44.54551036556467; dx=1.3806999469183119E-8 evalInputDelta=3.998251662612269
END: th(1.0080000000000002E7)=-43.27185728294813; dx=-1.257850693932166E-7 evalInputDelta=2.7245985799957353
Fitness changed from -40.5472587029524 to -44.54551036556467
Iteration 6 complete. Error: -44.54551036556467 Total: 122.4326; Orientation: 2.1532; Line Search: 95.6734
Adding measurement 6b852205 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 6.337e+04, gradient 4.692e-04, dot -0.347; [9ad58374-fa02-45ca-b3a6-f6b1118a2bd5 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -44.54551036556467, -19.693125283558192, -12.809335324290771, -8.131921312962376
LBFGS Accumulation History: 3 points
Removed measurement 6b852205 to history. Total: 3
th(0)=-44.54551036556467;dx=-2.1997925571226554E-7
New Minimum: -44.54551036556467 > -48.35821309504899
END: th(2.1716701675521392E7)=-48.35821309504899; dx=-6.011501262433766E-10 evalInputDelta=3.8127027294843217
Fitness changed from -44.54551036556467 to -48.35821309504899
Iteration 7 complete. Error: -48.35821309504899 Total: 74.8085; Orientation: 2.1613; Line Search: 49.3595
Adding measurement 53ae8126 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 6.893e+04, gradient 3.930e-04, dot -0.396; [9ad58374-fa02-45ca-b3a6-f6b1118a2bd5 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -48.35821309504899, -19.693125283558192, -12.809335324290771, -8.131921312962376
LBFGS Accumulation History: 3 points
Removed measurement 53ae8126 to history. Total: 3
th(0)=-48.35821309504899;dx=-1.5378777784942633E-7
New Minimum: -48.35821309504899 > -49.86570772393168
WOLF (strong): th(4.678721544281682E7)=-49.86570772393168; dx=3.6916754786570663E-8 evalInputDelta=1.5074946288826894
New Minimum: -49.86570772393168 > -50.95653841736875
END: th(2.339360772140841E7)=-50.95653841736875; dx=-4.5584903481568345E-10 evalInputDelta=2.5983253223197593
Fitness changed from -48.35821309504899 to -50.95653841736875
Iteration 8 complete. Error: -50.95653841736875 Total: 104.1160; Orientation: 2.0291; Line Search: 78.3763
Adding measurement 6be7d85d to history. Total: 3
Rejected: LBFGS Orientation magnitude: 7.389e+04, gradient 3.979e-04, dot -0.383; [9ad58374-fa02-45ca-b3a6-f6b1118a2bd5 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -50.95653841736875, -19.693125283558192, -12.809335324290771, -8.131921312962376
LBFGS Accumulation History: 3 points
Removed measurement 6be7d85d to history. Total: 3
th(0)=-50.95653841736875;dx=-1.5804185804671076E-7
New Minimum: -50.95653841736875 > -51.32356222146807
WOLF (strong): th(5.0400000000000015E7)=-51.32356222146807; dx=4.633892340332178E-8 evalInputDelta=0.36702380409932545
New Minimum: -51.32356222146807 > -53.18221093905995
WOLF (strong): th(2.5200000000000007E7)=-53.18221093905995; dx=2.322467849715682E-8 evalInputDelta=2.2256725216912017
END: th(8400000.000000002)=-52.64128671259074; dx=-8.887713080553151E-8 evalInputDelta=1.6847482952219934
Fitness changed from -50.95653841736875 to -53.18221093905995
Iteration 9 complete. Error: -53.18221093905995 Total: 131.1916; Orientation: 2.1496; Line Search: 102.9113
Adding measurement 79c4fcef to history. Total: 3
Rejected: LBFGS Orientation magnitude: 7.309e+04, gradient 4.184e-04, dot -0.346; [9ad58374-fa02-45ca-b3a6-f6b1118a2bd5 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -53.18221093905995, -19.693125283558192, -12.809335324290771, -8.131921312962376
LBFGS Accumulation History: 3 points
Removed measurement 79c4fcef to history. Total: 3
th(0)=-53.18221093905995;dx=-1.7502032432503973E-7
New Minimum: -53.18221093905995 > -55.792382553000756
END: th(1.8097251396267828E7)=-55.792382553000756; dx=-1.508144818146556E-9 evalInputDelta=2.610171613940807
Fitness changed from -53.18221093905995 to -55.792382553000756
Iteration 10 complete. Error: -55.792382553000756 Total: 87.9865; Orientation: 2.4545; Line Search: 58.9592
<a id="p-13"></a>Iteration 10
<a id="p-12"></a>![Iteration 10](etc/6b83b696-dd4f-4615-a105-fc8e4f57bb3c.jpg)
Final threshold in iteration 11: -55.792382553000756 (> -Infinity) after 1219.655s (< 5400.000s)

Returns

    -55.792382553000756