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 110.00 seconds (1.284 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: 42354178767700
Reset training subject: 42356517321700
Adding measurement 388faa8 to history. Total: 0
LBFGS Accumulation History: 1 points
Constructing line search parameters: GD+Trust
th(0)=-49.1325443170992;dx=-1.7666686343047448E-6
New Minimum: -49.1325443170992 > -49.13255143677343
WOLFE (weak): th(2.154434690031884)=-49.13255143677343; dx=-1.6582288956748123E-6 evalInputDelta=7.1196742297274795E-6
New Minimum: -49.13255143677343 > -49.132553216691825
WOLFE (weak): th(4.308869380063768)=-49.132553216691825; dx=-1.6590917226030804E-6 evalInputDelta=8.899592621958163E-6
New Minimum: -49.132553216691825 > -49.13256923595448
WOLFE (weak): th(12.926608140191302)=-49.13256923595448; dx=-1.6590769353530738E-6 evalInputDelta=2.4918855274336238E-5
New Minimum: -49.13256923595448 > -49.132642212529355
WOLFE (weak): th(51.70643256076521)=-49.132642212529355; dx=-1.658999301419947E-6 evalInputDelta=9.789543015159552E-5
New Minimum: -49.132642212529355 > -49.13301777318824
WOLFE (weak): th(258.53216280382605)=-49.13301777318824; dx=-1.6584883768559696E-6 evalInputDelta=4.734560890398143E-4
New Minimum: -49.13301777318824 > -49.13537430630604
WOLFE (weak): th(1551.1929768229563)=-49.13537430630604; dx=-1.6580569745971136E-6 evalInputDelta=0.0028299892068375243
New Minimum: -49.13537430630604 > -49.152354378229234
WOLFE (weak): th(10858.350837760694)=-49.152354378229234; dx=-1.6568611167542987E-6 evalInputDelta=0.019810061130030476
New Minimum: -49.152354378229234 > -49.29068832989365
WOLFE (weak): th(86866.80670208555)=-49.29068832989365; dx=-1.6469210756359119E-6 evalInputDelta=0.15814401279444468
New Minimum: -49.29068832989365 > -50.50063234745061
END: th(781801.26031877)=-50.50063234745061; dx=-1.5237148028441556E-6 evalInputDelta=1.3680880303514087
Fitness changed from -49.1325443170992 to -50.50063234745061
Iteration 1 complete. Error: -50.50063234745061 Total: 29.3959; Orientation: 0.0730; Line Search: 22.6838
<a id="p-3"></a>Iteration 1
<a id="p-2"></a>![Iteration 1](etc/81bc0420-f847-4be7-b742-b56402cca0fc.jpg)
Adding measurement 5e1c06a7 to history. Total: 1
LBFGS Accumulation History: 2 points
th(0)=-50.50063234745061;dx=-1.4724567866081034E-6
New Minimum: -50.50063234745061 > -53.02602303567883
END: th(1684339.7559414052)=-53.02602303567883; dx=-1.2745579424883833E-6 evalInputDelta=2.525390688228221
Fitness changed from -50.50063234745061 to -53.02602303567883
Iteration 2 complete. Error: -53.02602303567883 Total: 7.3299; Orientation: 0.0622; Line Search: 4.4831
<a id="p-5"></a>Iteration 2
<a id="p-4"></a>![Iteration 2](etc/cb16451d-2a6d-4766-87bc-62cba3b697aa.jpg)
Adding measurement 4eb2bcfa to history. Total: 2
LBFGS Accumulation History: 3 points
th(0)=-53.02602303567883;dx=-1.2073865273443282E-6
New Minimum: -53.02602303567883 > -57.25992424213455
END: th(3628800.0)=-57.25992424213455; dx=-9.419770849674605E-7 evalInputDelta=4.2339012064557195
Fitness changed from -53.02602303567883 to -57.25992424213455
Iteration 3 complete. Error: -57.25992424213455 Total: 7.5260; Orientation: 0.0601; Line Search: 4.4807
<a id="p-7"></a>Iteration 3
<a id="p-6"></a>![Iteration 3](etc/b1780d91-5f2d-4317-bb5e-6fb2b78d7b13.jpg)
Adding measurement 40395559 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.262e+04, gradient 9.361e-04, dot -0.924; [1dc2987d-7842-4d10-9d42-bb83f80ddbe2 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -57.25992424213455, -53.02602303567883, -50.50063234745061, -49.1325443170992
LBFGS Accumulation History: 3 points
Removed measurement 40395559 to history. Total: 3
th(0)=-57.25992424213455;dx=-8.751149815992523E-7
New Minimum: -57.25992424213455 > -63.425457027811326
END: th(7818012.6031877)=-63.425457027811326; dx=-5.951841468565165E-7 evalInputDelta=6.165532785676774
Fitness changed from -57.25992424213455 to -63.425457027811326
Iteration 4 complete. Error: -63.425457027811326 Total: 8.3250; Orientation: 1.1295; Line Search: 4.5079
<a id="p-9"></a>Iteration 4
<a id="p-8"></a>![Iteration 4](etc/f63e2be3-8bf1-4a6d-8261-5efe4ef9f3f5.jpg)
Adding measurement d3b8c4 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.932e+04, gradient 7.692e-04, dot -0.811; [1dc2987d-7842-4d10-9d42-bb83f80ddbe2 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -63.425457027811326, -53.02602303567883, -50.50063234745061, -49.1325443170992
LBFGS Accumulation History: 3 points
Removed measurement d3b8c4 to history. Total: 3
th(0)=-63.425457027811326;dx=-5.899356571919124E-7
New Minimum: -63.425457027811326 > -71.6366546962583
END: th(1.684339755941405E7)=-71.6366546962583; dx=-3.455060608756575E-7 evalInputDelta=8.211197668446978
Fitness changed from -63.425457027811326 to -71.6366546962583
Iteration 5 complete. Error: -71.6366546962583 Total: 8.4252; Orientation: 1.0549; Line Search: 4.6117
<a id="p-11"></a>Iteration 5
<a id="p-10"></a>![Iteration 5](etc/71ffb851-513b-40fa-bdd3-5d17cb0db9d3.jpg)
Adding measurement 1976bd8f to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.066e+04, gradient 6.674e-04, dot -0.672; [1dc2987d-7842-4d10-9d42-bb83f80ddbe2 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -71.6366546962583, -53.02602303567883, -50.50063234745061, -49.1325443170992
LBFGS Accumulation History: 3 points
Removed measurement 1976bd8f to history. Total: 3
th(0)=-71.6366546962583;dx=-4.4475645460694683E-7
New Minimum: -71.6366546962583 > -80.82321134864388
END: th(3.6288E7)=-80.82321134864388; dx=-1.181897241631201E-7 evalInputDelta=9.186556652385576
Fitness changed from -71.6366546962583 to -80.82321134864388
Iteration 6 complete. Error: -80.82321134864388 Total: 8.1529; Orientation: 1.0466; Line Search: 4.5229
Adding measurement 4842a56d to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.179e+04, gradient 7.899e-04, dot -0.380; [1dc2987d-7842-4d10-9d42-bb83f80ddbe2 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -80.82321134864388, -53.02602303567883, -50.50063234745061, -49.1325443170992
LBFGS Accumulation History: 3 points
Removed measurement 4842a56d to history. Total: 3
th(0)=-80.82321134864388;dx=-6.230912373239347E-7
Armijo: th(7.8180126031877E7)=-74.99812982816056; dx=1.5416310669427277E-7 evalInputDelta=-5.825081520483323
New Minimum: -80.82321134864388 > -83.15884728986383
WOLF (strong): th(3.90900630159385E7)=-83.15884728986383; dx=1.7387515592888578E-7 evalInputDelta=2.335635941219948
New Minimum: -83.15884728986383 > -85.94049365671873
END: th(1.3030021005312832E7)=-85.94049365671873; dx=-1.364091341182906E-7 evalInputDelta=5.117282308074849
Fitness changed from -80.82321134864388 to -85.94049365671873
Iteration 7 complete. Error: -85.94049365671873 Total: 12.2226; Orientation: 1.0394; Line Search: 9.0123
Adding measurement 5fd6d411 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.117e+04, gradient 5.815e-04, dot -0.566; [1dc2987d-7842-4d10-9d42-bb83f80ddbe2 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -85.94049365671873, -53.02602303567883, -50.50063234745061, -49.1325443170992
LBFGS Accumulation History: 3 points
Removed measurement 5fd6d411 to history. Total: 3
th(0)=-85.94049365671873;dx=-3.3765281619797966E-7
New Minimum: -85.94049365671873 > -90.47554097433411
END: th(2.807232926569009E7)=-90.47554097433411; dx=-3.752514141608303E-8 evalInputDelta=4.53504731761538
Fitness changed from -85.94049365671873 to -90.47554097433411
Iteration 8 complete. Error: -90.47554097433411 Total: 7.8669; Orientation: 1.0447; Line Search: 4.6225
Adding measurement 444dcecb to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.296e+04, gradient 7.322e-04, dot -0.389; [1dc2987d-7842-4d10-9d42-bb83f80ddbe2 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -90.47554097433411, -53.02602303567883, -50.50063234745061, -49.1325443170992
LBFGS Accumulation History: 3 points
Removed measurement 444dcecb to history. Total: 3
th(0)=-90.47554097433411;dx=-5.356958442605043E-7
Armijo: th(6.048000000000001E7)=-85.92608748694623; dx=1.6749912851970156E-7 evalInputDelta=-4.549453487387879
New Minimum: -90.47554097433411 > -92.62074082743852
WOLF (strong): th(3.0240000000000004E7)=-92.62074082743852; dx=1.7321483130737725E-7 evalInputDelta=2.1451998531044154
New Minimum: -92.62074082743852 > -94.25312815010402
END: th(1.0080000000000002E7)=-94.25312815010402; dx=-1.72641006854714E-7 evalInputDelta=3.7775871757699093
Fitness changed from -90.47554097433411 to -94.25312815010402
Iteration 9 complete. Error: -94.25312815010402 Total: 12.5795; Orientation: 1.0346; Line Search: 9.3867
Adding measurement 55491a70 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 4.136e+04, gradient 4.784e-04, dot -0.630; [1dc2987d-7842-4d10-9d42-bb83f80ddbe2 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -94.25312815010402, -53.02602303567883, -50.50063234745061, -49.1325443170992
LBFGS Accumulation History: 3 points
Removed measurement 55491a70 to history. Total: 3
th(0)=-94.25312815010402;dx=-2.2809641978369822E-7
New Minimum: -94.25312815010402 > -97.84909904550338
END: th(2.1716701675521392E7)=-97.84909904550338; dx=-1.1566583479743277E-7 evalInputDelta=3.595970895399361
Fitness changed from -94.25312815010402 to -97.84909904550338
Iteration 10 complete. Error: -97.84909904550338 Total: 7.7102; Orientation: 1.0146; Line Search: 4.5468
<a id="p-13"></a>Iteration 10
<a id="p-12"></a>![Iteration 10](etc/e0acf25b-bac5-41ea-8177-1706708270f0.jpg)
Final threshold in iteration 11: -97.84909904550338 (> -Infinity) after 109.998s (< 5400.000s)

Returns

    -97.84909904550338