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 136.68 seconds (1.864 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: 2437835803463
Reset training subject: 2438752743085
Adding measurement 76154ae2 to history. Total: 0
LBFGS Accumulation History: 1 points
Constructing line search parameters: GD+Trust
th(0)=-0.3312281938788862;dx=-3.163491084383299E-4
New Minimum: -0.3312281938788862 > -0.3319257007456154
WOLFE (weak): th(2.154434690031884)=-0.3319257007456154; dx=-3.1629869964885135E-4 evalInputDelta=6.975068667292028E-4
New Minimum: -0.3319257007456154 > -0.3326223609329347
WOLFE (weak): th(4.308869380063768)=-0.3326223609329347; dx=-3.162031365962261E-4 evalInputDelta=0.0013941670540484896
New Minimum: -0.3326223609329347 > -0.33541436826419974
WOLFE (weak): th(12.926608140191302)=-0.33541436826419974; dx=-3.1694291056079117E-4 evalInputDelta=0.004186174385313546
New Minimum: -0.33541436826419974 > -0.34807421173390574
WOLFE (weak): th(51.70643256076521)=-0.34807421173390574; dx=-3.183011604527481E-4 evalInputDelta=0.016846017855019546
New Minimum: -0.34807421173390574 > -0.41453268238543406
WOLFE (weak): th(258.53216280382605)=-0.41453268238543406; dx=-3.1771788591418546E-4 evalInputDelta=0.08330448850654787
New Minimum: -0.41453268238543406 > -0.8410625042498284
WOLFE (weak): th(1551.1929768229563)=-0.8410625042498284; dx=-3.203238651040031E-4 evalInputDelta=0.5098343103709422
New Minimum: -0.8410625042498284 > -2.2032360292418325
END: th(10858.350837760694)=-2.2032360292418325; dx=-4.445197797085489E-5 evalInputDelta=1.8720078353629463
Fitness changed from -0.3312281938788862 to -2.2032360292418325
Iteration 1 complete. Error: -2.2032360292418325 Total: 10.1431; Orientation: 0.0196; Line Search: 7.4493
<a id="p-3"></a>Iteration 1
<a id="p-2"></a>![Iteration 1](etc/872fe8c9-de60-4d15-925c-a1abcb422ecb.jpg)
Adding measurement 21ec1e56 to history. Total: 1
LBFGS Accumulation History: 2 points
th(0)=-2.2032360292418325;dx=-7.050274396228509E-4
New Minimum: -2.2032360292418325 > -5.04789529885894
END: th(23393.607721408407)=-5.04789529885894; dx=-2.453767244643913E-5 evalInputDelta=2.8446592696171074
Fitness changed from -2.2032360292418325 to -5.04789529885894
Iteration 2 complete. Error: -5.04789529885894 Total: 2.7921; Orientation: 0.0213; Line Search: 1.8503
<a id="p-5"></a>Iteration 2
<a id="p-4"></a>![Iteration 2](etc/e9d7a0d5-7f77-4bc1-8141-8cf861445e61.jpg)
Adding measurement 21349a97 to history. Total: 2
LBFGS Accumulation History: 3 points
th(0)=-5.04789529885894;dx=-0.0014304572054078017
New Minimum: -5.04789529885894 > -8.019865643144032
WOLF (strong): th(50400.00000000001)=-8.019865643144032; dx=1.744409313003956E-5 evalInputDelta=2.9719703442850918
New Minimum: -8.019865643144032 > -8.50022708365093
WOLF (strong): th(25200.000000000004)=-8.50022708365093; dx=2.261577883429329E-5 evalInputDelta=3.4523317847919905
New Minimum: -8.50022708365093 > -9.224096784337013
END: th(8400.000000000002)=-9.224096784337013; dx=-1.5748616226138643E-4 evalInputDelta=4.176201485478073
Fitness changed from -5.04789529885894 to -9.224096784337013
Iteration 3 complete. Error: -9.224096784337013 Total: 4.6440; Orientation: 0.0202; Line Search: 3.7104
<a id="p-7"></a>Iteration 3
<a id="p-6"></a>![Iteration 3](etc/5b76b205-f89f-482b-8105-05b814d2f65b.jpg)
Adding measurement 3ae3e94c to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.193e+03, gradient 4.267e-02, dot -0.218; [4280ddb9-e837-41c9-9ec8-d04b2d86e214 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -9.224096784337013, -5.04789529885894, -2.2032360292418325, -0.3312281938788862
LBFGS Accumulation History: 3 points
Removed measurement 3ae3e94c to history. Total: 3
th(0)=-9.224096784337013;dx=-0.0018197129423771852
New Minimum: -9.224096784337013 > -13.747554492221573
WOLF (strong): th(18097.251396267828)=-13.747554492221573; dx=2.9991171829223E-5 evalInputDelta=4.52345770788456
New Minimum: -13.747554492221573 > -14.21062772391203
END: th(9048.625698133914)=-14.21062772391203; dx=-1.428700023340338E-4 evalInputDelta=4.986530939575017
Fitness changed from -9.224096784337013 to -14.21062772391203
Iteration 4 complete. Error: -14.21062772391203 Total: 4.1446; Orientation: 0.4734; Line Search: 2.7631
<a id="p-9"></a>Iteration 4
<a id="p-8"></a>![Iteration 4](etc/c6449c70-8f6d-47fa-98bc-d0e01efefb0b.jpg)
Adding measurement 1afcaf54 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.813e+03, gradient 5.000e-02, dot -0.211; [4280ddb9-e837-41c9-9ec8-d04b2d86e214 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -14.21062772391203, -5.04789529885894, -2.2032360292418325, -0.3312281938788862
LBFGS Accumulation History: 3 points
Removed measurement 1afcaf54 to history. Total: 3
th(0)=-14.21062772391203;dx=-0.0024998125524200773
New Minimum: -14.21062772391203 > -15.58315000919212
WOLF (strong): th(19494.673101173677)=-15.58315000919212; dx=1.147408620428525E-4 evalInputDelta=1.3725222852800911
New Minimum: -15.58315000919212 > -17.971503695249304
WOLF (strong): th(9747.336550586839)=-17.971503695249304; dx=1.0038663426187442E-4 evalInputDelta=3.760875971337274
New Minimum: -17.971503695249304 > -18.490476889353154
END: th(3249.1121835289464)=-18.490476889353154; dx=-8.238480485026395E-4 evalInputDelta=4.279849165441124
Fitness changed from -14.21062772391203 to -18.490476889353154
Iteration 5 complete. Error: -18.490476889353154 Total: 5.0622; Orientation: 0.4654; Line Search: 3.6873
<a id="p-11"></a>Iteration 5
<a id="p-10"></a>![Iteration 5](etc/0b2fc811-dc1d-49d7-8215-0c291fd7b118.jpg)
Adding measurement 4bd9a8cc to history. Total: 3
Rejected: LBFGS Orientation magnitude: 7.984e+03, gradient 4.585e-02, dot -0.247; [4280ddb9-e837-41c9-9ec8-d04b2d86e214 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -18.490476889353154, -5.04789529885894, -2.2032360292418325, -0.3312281938788862
LBFGS Accumulation History: 3 points
Removed measurement 4bd9a8cc to history. Total: 3
th(0)=-18.490476889353154;dx=-0.0021019614637068002
New Minimum: -18.490476889353154 > -23.88387816562605
END: th(7000.000000000003)=-23.88387816562605; dx=-4.907495281880185E-4 evalInputDelta=5.393401276272897
Fitness changed from -18.490476889353154 to -23.88387816562605
Iteration 6 complete. Error: -23.88387816562605 Total: 3.2217; Orientation: 0.4707; Line Search: 1.8397
Adding measurement 623e590f to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.857e+04, gradient 6.908e-02, dot -0.170; [4280ddb9-e837-41c9-9ec8-d04b2d86e214 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -23.88387816562605, -5.04789529885894, -2.2032360292418325, -0.3312281938788862
LBFGS Accumulation History: 3 points
Removed measurement 623e590f to history. Total: 3
th(0)=-23.88387816562605;dx=-0.004770476479126356
Armijo: th(15081.042830223192)=-22.24901998697604; dx=2.0562569275059026E-4 evalInputDelta=-1.6348581786500098
New Minimum: -23.88387816562605 > -26.395459379955984
WOLF (strong): th(7540.521415111596)=-26.395459379955984; dx=1.3830150463858994E-4 evalInputDelta=2.511581214329933
New Minimum: -26.395459379955984 > -28.427442847289967
END: th(2513.507138370532)=-28.427442847289967; dx=-6.425990247622305E-4 evalInputDelta=4.543564681663916
Fitness changed from -23.88387816562605 to -28.427442847289967
Iteration 7 complete. Error: -28.427442847289967 Total: 6.1004; Orientation: 0.4780; Line Search: 4.7572
Adding measurement 1404677d to history. Total: 3
Rejected: LBFGS Orientation magnitude: 5.155e+04, gradient 5.915e-02, dot -0.189; [4280ddb9-e837-41c9-9ec8-d04b2d86e214 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -28.427442847289967, -5.04789529885894, -2.2032360292418325, -0.3312281938788862
LBFGS Accumulation History: 3 points
Removed measurement 1404677d to history. Total: 3
th(0)=-28.427442847289967;dx=-0.0034983932713794266
New Minimum: -28.427442847289967 > -32.01234770012093
WOLF (strong): th(5415.186972548245)=-32.01234770012093; dx=2.922794656115409E-4 evalInputDelta=3.5849048528309595
New Minimum: -32.01234770012093 > -32.76354979718315
END: th(2707.5934862741224)=-32.76354979718315; dx=-7.9113230974158E-4 evalInputDelta=4.3361069498931855
Fitness changed from -28.427442847289967 to -32.76354979

...skipping 5608 bytes...

5E-6
Armijo: th(8.785193794557548E-10)=-43.630032224536144; dx=-5.269815680194255 evalInputDelta=0.0
Armijo: th(8.240656989109765E-10)=-43.630032224536144; dx=-5.270007382747165 evalInputDelta=0.0
WOLFE (weak): th(7.968388586385875E-10)=-43.63003362346143; dx=-5.269769094059325 evalInputDelta=1.3989252849455625E-6
Armijo: th(8.10452278774782E-10)=-43.630032224536144; dx=-5.268714976085207 evalInputDelta=0.0
Armijo: th(8.036455687066847E-10)=-43.630032224536144; dx=-5.26889610962803 evalInputDelta=0.0
WOLFE (weak): th(8.002422136726361E-10)=-43.63003362346143; dx=-5.268606766163277 evalInputDelta=1.3989252849455625E-6
WOLFE (weak): th(8.019438911896604E-10)=-43.63003362346143; dx=-5.269447500334076 evalInputDelta=1.3989252849455625E-6
WOLFE (weak): th(8.027947299481726E-10)=-43.63003362346143; dx=-5.268762871699277 evalInputDelta=1.3989252849455625E-6
WOLFE (weak): th(8.032201493274286E-10)=-43.63003362346143; dx=-5.233862049840864 evalInputDelta=1.3989252849455625E-6
WOLFE (weak): th(8.034328590170566E-10)=-43.63003362346143; dx=-5.269081453520814 evalInputDelta=1.3989252849455625E-6
WOLFE (weak): th(8.035392138618706E-10)=-43.63003362346143; dx=-5.255827627414143 evalInputDelta=1.3989252849455625E-6
Armijo: th(8.035923912842777E-10)=-43.630032224536144; dx=-5.269254084059168 evalInputDelta=0.0
Armijo: th(8.035658025730742E-10)=-43.630032224536144; dx=-5.269248670414623 evalInputDelta=0.0
Armijo: th(8.035525082174724E-10)=-43.630032224536144; dx=-5.26983607366453 evalInputDelta=0.0
Armijo: th(8.035458610396715E-10)=-43.630032224536144; dx=-5.269579703015427 evalInputDelta=0.0
mu ~= nu (8.035392138618706E-10): th(1.1616785182886012E-10)=-43.63003362346143
Fitness changed from -43.630032224536144 to -43.63003362346143
Iteration 12 complete. Error: -43.63003362346143 Total: 34.7861; Orientation: 0.4609; Line Search: 33.4469
Adding measurement 2508883 to history. Total: 4
Rejected: LBFGS Orientation magnitude: 1.686e+09, gradient 6.320e-02, dot -0.182; [4280ddb9-e837-41c9-9ec8-d04b2d86e214 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -43.63003362346143, -43.630032224536144, -5.04789529885894, -2.2032360292418325, -0.3312281938788862
Rejected: LBFGS Orientation magnitude: 3.021e+09, gradient 6.320e-02, dot -0.251; [4280ddb9-e837-41c9-9ec8-d04b2d86e214 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -43.63003362346143, -43.630032224536144, -5.04789529885894, -2.2032360292418325
LBFGS Accumulation History: 3 points
Removed measurement 2508883 to history. Total: 4
Removed measurement 4e1de9de to history. Total: 3
th(0)=-43.63003362346143;dx=-0.003993620554404508
WOLFE (weak): th(1.7311799176001853E-9)=-43.63003362346143; dx=-0.003993655987290742 evalInputDelta=0.0
WOLFE (weak): th(3.4623598352003707E-9)=-43.63003362346143; dx=-0.003993601741581183 evalInputDelta=0.0
WOLFE (weak): th(1.0387079505601112E-8)=-43.63003362346143; dx=-0.003993623513949966 evalInputDelta=0.0
WOLFE (weak): th(4.154831802240445E-8)=-43.63003362346143; dx=-0.003993609950195283 evalInputDelta=0.0
WOLFE (weak): th(2.0774159011202225E-7)=-43.63003362346143; dx=-0.003993625981050429 evalInputDelta=0.0
Armijo: th(1.2464495406721335E-6)=-43.630032224536144; dx=-0.003993632998011301 evalInputDelta=-1.3989252849455625E-6
WOLFE (weak): th(7.270955653920779E-7)=-43.63003362346143; dx=-0.0039935868669604664 evalInputDelta=0.0
Armijo: th(9.867725530321058E-7)=-43.63002942668544; dx=-0.003993627020636062 evalInputDelta=-4.196775989839807E-6
WOLFE (weak): th(8.569340592120919E-7)=-43.63003362346143; dx=-0.0039936318999728125 evalInputDelta=0.0
Armijo: th(9.218533061220988E-7)=-43.63002942668544; dx=-0.003993594315147803 evalInputDelta=-4.196775989839807E-6
WOLFE (weak): th(8.893936826670953E-7)=-43.63003362346143; dx=-0.003993639346597454 evalInputDelta=0.0
WOLFE (weak): th(9.05623494394597E-7)=-43.63003362346143; dx=-0.0039936167345298035 evalInputDelta=0.0
Armijo: th(9.137384002583479E-7)=-43.63002942668544; dx=-0.003993637322230478 evalInputDelta=-4.196775989839807E-6
WOLFE (weak): th(9.096809473264725E-7)=-43.63003362346143; dx=-0.003993631582894047 evalInputDelta=0.0
Armijo: th(9.117096737924103E-7)=-43.63002942668544; dx=-0.003993618168373715 evalInputDelta=-4.196775989839807E-6
WOLFE (weak): th(9.106953105594414E-7)=-43.63003362346143; dx=-0.003993640522842011 evalInputDelta=0.0
WOLFE (weak): th(9.112024921759258E-7)=-43.63003362346143; dx=-0.003993595139472096 evalInputDelta=0.0
WOLFE (weak): th(9.11456082984168E-7)=-43.63003362346143; dx=-0.003993626997595086 evalInputDelta=0.0
Armijo: th(9.115828783882891E-7)=-43.63002942668544; dx=-0.0039936279721405985 evalInputDelta=-4.196775989839807E-6
Armijo: th(9.115194806862286E-7)=-43.63002942668544; dx=-0.003993660584636853 evalInputDelta=-4.196775989839807E-6
Armijo: th(9.114877818351983E-7)=-43.63002942668544; dx=-0.003993659232281123 evalInputDelta=-4.196775989839807E-6
WOLFE (weak): th(9.114719324096832E-7)=-43.63003362346143; dx=-0.003993633011590629 evalInputDelta=0.0
WOLFE (weak): th(9.114798571224407E-7)=-43.63003362346143; dx=-0.0039936099121353034 evalInputDelta=0.0
mu ~= nu (9.114798571224407E-7): th(0.0)=-43.63003362346143
Fitness changed from -43.63003362346143 to -43.63003362346143
Static Iteration Total: 26.1234; Orientation: 2.0700; Line Search: 23.1646
Iteration 13 failed. Error: -43.63003362346143
Previous Error: 0.0 -> -43.63003362346143
Retrying iteration 13
Reset training subject: 2552488679499
Adding measurement 3e585a26 to history. Total: 0
LBFGS Accumulation History: 1 points
th(0)=-43.63003362346143;dx=-0.003993623761532573
Armijo: th(1.963732360087928E-6)=-43.630032224536144; dx=-0.003993650774209179 evalInputDelta=-1.3989252849455625E-6
Armijo: th(9.81866180043964E-7)=-43.63002942668544; dx=-0.0039935898563617026 evalInputDelta=-4.196775989839807E-6
WOLFE (weak): th(3.272887266813213E-7)=-43.63003362346143; dx=-0.003993600591992077 evalInputDelta=0.0
WOLFE (weak): th(6.545774533626427E-7)=-43.63003362346143; dx=-0.003993591936921433 evalInputDelta=0.0
WOLFE (weak): th(8.182218167033033E-7)=-43.63003362346143; dx=-0.003993623905657044 evalInputDelta=0.0
WOLFE (weak): th(9.000439983736336E-7)=-43.63003362346143; dx=-0.003993636999266796 evalInputDelta=0.0
Armijo: th(9.409550892087988E-7)=-43.63002942668544; dx=-0.003993621616029138 evalInputDelta=-4.196775989839807E-6
Armijo: th(9.204995437912163E-7)=-43.63002942668544; dx=-0.00399362427803363 evalInputDelta=-4.196775989839807E-6
WOLFE (weak): th(9.10271771082425E-7)=-43.63003362346143; dx=-0.0039936284035517675 evalInputDelta=0.0
Armijo: th(9.153856574368206E-7)=-43.63002942668544; dx=-0.003993640799933827 evalInputDelta=-4.196775989839807E-6
Armijo: th(9.128287142596227E-7)=-43.63002942668544; dx=-0.003993601795289306 evalInputDelta=-4.196775989839807E-6
Armijo: th(9.115502426710239E-7)=-43.63002942668544; dx=-0.003993640725272408 evalInputDelta=-4.196775989839807E-6
WOLFE (weak): th(9.109110068767244E-7)=-43.63003362346143; dx=-0.0039936274321658105 evalInputDelta=0.0
WOLFE (weak): th(9.11230624773874E-7)=-43.63003362346143; dx=-0.003993594739647974 evalInputDelta=0.0
WOLFE (weak): th(9.11390433722449E-7)=-43.63003362346143; dx=-0.003993602334599392 evalInputDelta=0.0
WOLFE (weak): th(9.114703381967364E-7)=-43.63003362346143; dx=-0.00399360367704479 evalInputDelta=0.0
Armijo: th(9.115102904338801E-7)=-43.63002942668544; dx=-0.003993624386745293 evalInputDelta=-4.196775989839807E-6
Armijo: th(9.114903143153082E-7)=-43.63002942668544; dx=-0.003993644709372143 evalInputDelta=-4.196775989839807E-6
WOLFE (weak): th(9.114803262560224E-7)=-43.63003362346143; dx=-0.003993603127233488 evalInputDelta=0.0
Armijo: th(9.114853202856652E-7)=-43.63002942668544; dx=-0.003993622841449122 evalInputDelta=-4.196775989839807E-6
mu ~= nu (9.114803262560224E-7): th(0.0)=-43.63003362346143
Fitness changed from -43.63003362346143 to -43.63003362346143
Static Iteration Total: 22.0287; Orientation: 0.0201; Line Search: 20.2678
Iteration 14 failed. Error: -43.63003362346143
Previous Error: 0.0 -> -43.63003362346143
Optimization terminated 14
Final threshold in iteration 14: -43.63003362346143 (> -Infinity) after 136.682s (< 3600.000s)

Returns

    -43.63003362346143