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 151.15 seconds (3.049 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: 456115144640400
Reset training subject: 456117940988800
Adding measurement 77f437b3 to history. Total: 0
LBFGS Accumulation History: 1 points
Constructing line search parameters: GD+Trust
th(0)=-145.25969611196066;dx=-1.1139486071843958E-5
New Minimum: -145.25969611196066 > -145.25972671378435
WOLFE (weak): th(2.154434690031884)=-145.25972671378435; dx=-1.09457824004132E-5 evalInputDelta=3.0601823681308815E-5
New Minimum: -145.25972671378435 > -145.25974966514784
WOLFE (weak): th(4.308869380063768)=-145.25974966514784; dx=-1.0900116860168298E-5 evalInputDelta=5.3553187171928585E-5
New Minimum: -145.25974966514784 > -145.25984912101453
WOLFE (weak): th(12.926608140191302)=-145.25984912101453; dx=-1.0946071528484412E-5 evalInputDelta=1.5300905386084196E-4
New Minimum: -145.25984912101453 > -145.26030049678437
WOLFE (weak): th(51.70643256076521)=-145.26030049678437; dx=-1.093578322205034E-5 evalInputDelta=6.043848237027305E-4
New Minimum: -145.26030049678437 > -145.262718010933
WOLFE (weak): th(258.53216280382605)=-145.262718010933; dx=-1.0945110848613865E-5 evalInputDelta=0.0030218989723493905
New Minimum: -145.262718010933 > -145.27779596491362
WOLFE (weak): th(1551.1929768229563)=-145.27779596491362; dx=-1.0942798718984772E-5 evalInputDelta=0.018099852952957463
New Minimum: -145.27779596491362 > -145.38629425597276
WOLFE (weak): th(10858.350837760694)=-145.38629425597276; dx=-1.0907953955509593E-5 evalInputDelta=0.12659814401209246
New Minimum: -145.38629425597276 > -146.2657435607679
WOLFE (weak): th(86866.80670208555)=-146.2657435607679; dx=-1.0774166110140602E-5 evalInputDelta=1.0060474488072373
New Minimum: -146.2657435607679 > -153.711497801845
END: th(781801.26031877)=-153.711497801845; dx=-9.311755856840374E-6 evalInputDelta=8.451801689884348
Fitness changed from -145.25969611196066 to -153.711497801845
Iteration 1 complete. Error: -153.711497801845 Total: 37.7074; Orientation: 0.1096; Line Search: 29.1011
<a id="p-3"></a>Iteration 1
<a id="p-2"></a>![Iteration 1](etc/aea4aee6-4e6f-4f77-bcdb-e755a822ca6b.jpg)
Adding measurement 6d9db965 to history. Total: 1
LBFGS Accumulation History: 2 points
th(0)=-153.711497801845;dx=-8.717727299497257E-6
New Minimum: -153.711497801845 > -167.1679966160655
END: th(1684339.7559414052)=-167.1679966160655; dx=-6.370227483303461E-6 evalInputDelta=13.456498814220481
Fitness changed from -153.711497801845 to -167.1679966160655
Iteration 2 complete. Error: -167.1679966160655 Total: 9.1889; Orientation: 0.0943; Line Search: 5.7183
<a id="p-5"></a>Iteration 2
<a id="p-4"></a>![Iteration 2](etc/c165665c-e52a-4d3b-a8ee-f25ec259126e.jpg)
Adding measurement 437be941 to history. Total: 2
LBFGS Accumulation History: 3 points
th(0)=-167.1679966160655;dx=-6.086399313808715E-6
New Minimum: -167.1679966160655 > -185.51869344930083
END: th(3628800.0)=-185.51869344930083; dx=-3.7168663848334296E-6 evalInputDelta=18.350696833235332
Fitness changed from -167.1679966160655 to -185.51869344930083
Iteration 3 complete. Error: -185.51869344930083 Total: 9.3356; Orientation: 0.1081; Line Search: 5.8467
<a id="p-7"></a>Iteration 3
<a id="p-6"></a>![Iteration 3](etc/6c3f138b-73cc-409a-b6a8-a69a8334cda8.jpg)
Adding measurement 650f0d20 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.773e+04, gradient 2.103e-03, dot -0.797; [3e229122-6a95-493f-8b36-c02cab91eb33 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -185.51869344930083, -167.1679966160655, -153.711497801845, -145.25969611196066
LBFGS Accumulation History: 3 points
Removed measurement 650f0d20 to history. Total: 3
th(0)=-185.51869344930083;dx=-4.40144818393575E-6
New Minimum: -185.51869344930083 > -207.6382876473991
END: th(7818012.6031877)=-207.6382876473991; dx=-1.632811493492613E-6 evalInputDelta=22.11959419809827
Fitness changed from -185.51869344930083 to -207.6382876473991
Iteration 4 complete. Error: -207.6382876473991 Total: 11.3824; Orientation: 1.9564; Line Search: 5.9450
<a id="p-9"></a>Iteration 4
<a id="p-8"></a>![Iteration 4](etc/e9f0055e-0adc-4a1f-93f9-236e01f186af.jpg)
Adding measurement 67820ad to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.720e+04, gradient 2.131e-03, dot -0.584; [3e229122-6a95-493f-8b36-c02cab91eb33 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -207.6382876473991, -167.1679966160655, -153.711497801845, -145.25969611196066
LBFGS Accumulation History: 3 points
Removed measurement 67820ad to history. Total: 3
th(0)=-207.6382876473991;dx=-4.52507812413835E-6
New Minimum: -207.6382876473991 > -215.07624824467075
WOLF (strong): th(1.684339755941405E7)=-215.07624824467075; dx=9.293117566026466E-7 evalInputDelta=7.437960597271655
New Minimum: -215.07624824467075 > -221.7659413986163
WOLF (strong): th(8421698.779707026)=-221.7659413986163; dx=6.148875928424398E-8 evalInputDelta=14.127653751217196
END: th(2807232.9265690087)=-217.42171761348501; dx=-2.2261637925699497E-6 evalInputDelta=9.783429966085919
Fitness changed from -207.6382876473991 to -221.7659413986163
Iteration 5 complete. Error: -221.7659413986163 Total: 17.0364; Orientation: 2.0350; Line Search: 11.7025
<a id="p-11"></a>Iteration 5
<a id="p-10"></a>![Iteration 5](etc/7704c7bc-bc37-4cc6-8cf6-6fbba6c97ad7.jpg)
Adding measurement 5801adec to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.607e+04, gradient 2.243e-03, dot -0.458; [3e229122-6a95-493f-8b36-c02cab91eb33 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -221.7659413986163, -167.1679966160655, -153.711497801845, -145.25969611196066
LBFGS Accumulation History: 3 points
Removed measurement 5801adec to history. Total: 3
th(0)=-221.7659413986163;dx=-5.025304399031232E-6
New Minimum: -221.7659413986163 > -236.6424479740146
END: th(6048000.0)=-236.6424479740146; dx=-5.784072499409892E-8 evalInputDelta=14.87650657539831
Fitness changed from -221.7659413986163 to -236.6424479740146
Iteration 6 complete. Error: -236.6424479740146 Total: 11.5113; Orientation: 2.0029; Line Search: 6.0808
Adding measurement 1ec3522a to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.213e+04, gradient 1.739e-03, dot -0.546; [3e229122-6a95-493f-8b36-c02cab91eb33 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -236.6424479740146, -167.1679966160655, -153.711497801845, -145.25969611196066
LBFGS Accumulation History: 3 points
Removed measurement 1ec3522a to history. Total: 3
th(0)=-236.6424479740146;dx=-3.0070732096623786E-6
New Minimum: -236.6424479740146 > -242.15401320626356
WOLF (strong): th(1.3030021005312834E7)=-242.15401320626356; dx=8.676521875757076E-7 evalInputDelta=5.511565232248955
New Minimum: -242.15401320626356 > -246.15014562619558
END: th(6515010.502656417)=-246.15014562619558; dx=-2.0727154085248652E-7 evalInputDelta=9.50769765218098
Fitness changed from -236.6424479740146 to -246.15014562619558
Iteration 7 complete. Error: -246.15014562619558 Total: 13.8011; Orientation: 1.8621; Line Search: 9.1284
Adding measurement 19f0aaba to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.372e+04, gradient 1.639e-03, dot -0.535; [3e229122-6a95-493f-8b36-c02cab91eb33 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -246.15014562619558, -167.1679966160655, -153.711497801845, -145.25969611196066
LBFGS Accumulation History: 3 points
Removed measurement 19f0aaba to history. Total: 3
th(0)=-246.15014562619558;dx=-2.676398982345489E-6
New Minimum: -246.15014562619558 > -248.36888179256323
WOLF (strong): th(1.4036164632845046E7)=-248.36888179256323; dx=9.283345921133722E-7 evalInputDelta=2.2187361663676484
New Minimum: -248.36888179256323 > -253.83684629586818
WOLF (strong): th(7018082.316422523)=-253.83684629586818; dx=8.840404262496319E-8 evalInputDelta=7.686700669672604
END: th(2339360.772140841)=-251.18863700709377; dx=-1.5443956493199017E-6 evalInputDelta=5.0384913808981935
Fitness changed from -246.15014562619558 to -253.83684629586818
Iteration 8 complete. Error: -253.83684629586818 Total: 16.3098; Orientation: 1.8880; Line Search: 11.5940
Adding measurement 30064195 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.442e+04, gradient 1.641e-03, dot -0.489; [3e229122-6a95-493f-8b36-c02cab91eb33 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -253.83684629586818, -167.1679966160655, -153.711497801845, -145.25969611196066
LBFGS Accumulation History: 3 points
Removed measurement 30064195 to history. Total: 3
th(0)=-253.83684629586818;dx=-2.688697054601291E-6
New Minimum: -253.83684629586818 > -261.0809789536803
END: th(5040000.000000001)=-261.0809789536803; dx=-3.0427114041582866E-7 evalInputDelta=7.244132657812116
Fitness changed from -253.83684629586818 to -261.0809789536803
Iteration 9 complete. Error: -261.0809789536803 Total: 10.7762; Orientation: 1.8589; Line Search: 6.0337
Adding measurement 42870288 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.638e+04, gradient 1.296e-03, dot -0.584; [3e229122-6a95-493f-8b36-c02cab91eb33 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -261.0809789536803, -167.1679966160655, -153.711497801845, -145.25969611196066
LBFGS Accumulation History: 3 points
Removed measurement 42870288 to history. Total: 3
th(0)=-261.0809789536803;dx=-1.674286798518582E-6
New Minimum: -261.0809789536803 > -266.3188714292671
WOLF (strong): th(1.0858350837760696E7)=-266.3188714292671; dx=1.441788421235093E-7 evalInputDelta=5.237892475586818
END: th(5429175.418880348)=-266.3157000606053; dx=-4.4398488863466996E-7 evalInputDelta=5.234721106925008
Fitness changed from -261.0809789536803 to -266.3188714292671
Iteration 10 complete. Error: -266.3188714292671 Total: 13.5137; Orientation: 1.9437; Line Search: 8.8903
<a id="p-13"></a>Iteration 10
<a id="p-12"></a>![Iteration 10](etc/e0904fdd-ee6d-4b02-92f7-5119a2fb0b30.jpg)
Final threshold in iteration 11: -266.3188714292671 (> -Infinity) after 151.152s (< 5400.000s)

Returns

    -266.3188714292671