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 301.97 seconds (3.902 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: 574614702356200
Reset training subject: 574620816519700
Adding measurement 1edff8b2 to history. Total: 0
LBFGS Accumulation History: 1 points
Constructing line search parameters: GD+Trust
th(0)=-37.59546815091935;dx=-2.0533366072316993E-6
New Minimum: -37.59546815091935 > -37.595470159864895
END: th(2.154434690031884)=-37.595470159864895; dx=-1.7878498434757383E-6 evalInputDelta=2.0089455432525938E-6
Fitness changed from -37.59546815091935 to -37.595470159864895
Iteration 1 complete. Error: -37.595470159864895 Total: 31.0368; Orientation: 0.1535; Line Search: 12.6062
<a id="p-3"></a>Iteration 1
<a id="p-2"></a>![Iteration 1](etc/d09c7c6f-4474-4315-88a1-a44b642da26b.jpg)
Adding measurement 393bc3cb to history. Total: 1
LBFGS Accumulation History: 2 points
th(0)=-37.595470159864895;dx=-1.786924869279266E-6
New Minimum: -37.595470159864895 > -37.595482213535895
WOLFE (weak): th(4.641588833612779)=-37.595482213535895; dx=-1.7859552759930256E-6 evalInputDelta=1.2053670999989663E-5
New Minimum: -37.595482213535895 > -37.595490249314416
WOLFE (weak): th(9.283177667225559)=-37.595490249314416; dx=-1.7847894019531033E-6 evalInputDelta=2.0089449520810376E-5
New Minimum: -37.595490249314416 > -37.595528419238924
WOLFE (weak): th(27.849533001676676)=-37.595528419238924; dx=-1.7840552435857607E-6 evalInputDelta=5.8259374029034916E-5
New Minimum: -37.595528419238924 > -37.59569114321918
WOLFE (weak): th(111.3981320067067)=-37.59569114321918; dx=-1.7838335253882385E-6 evalInputDelta=2.2098335428211158E-4
New Minimum: -37.59569114321918 > -37.59656100143969
WOLFE (weak): th(556.9906600335335)=-37.59656100143969; dx=-1.783767781793167E-6 evalInputDelta=0.0010908415747934441
New Minimum: -37.59656100143969 > -37.60200067445737
WOLFE (weak): th(3341.9439602012008)=-37.60200067445737; dx=-1.7828628428356363E-6 evalInputDelta=0.006530514592476777
New Minimum: -37.60200067445737 > -37.64113589082422
WOLFE (weak): th(23393.607721408407)=-37.64113589082422; dx=-1.7807087207056602E-6 evalInputDelta=0.04566573095932824
New Minimum: -37.64113589082422 > -37.95862508168354
WOLFE (weak): th(187148.86177126726)=-37.95862508168354; dx=-1.7588409884593631E-6 evalInputDelta=0.36315492181864784
New Minimum: -37.95862508168354 > -40.64759556410769
END: th(1684339.7559414054)=-40.64759556410769; dx=-1.5135057319191863E-6 evalInputDelta=3.052125404242794
Fitness changed from -37.595470159864895 to -40.64759556410769
Iteration 2 complete. Error: -40.64759556410769 Total: 69.0738; Orientation: 0.1455; Line Search: 61.8330
<a id="p-5"></a>Iteration 2
<a id="p-4"></a>![Iteration 2](etc/ca3a906c-bd56-4a71-8936-6577f74603c3.jpg)
Adding measurement 7725c88e to history. Total: 2
LBFGS Accumulation History: 3 points
th(0)=-40.64759556410769;dx=-1.4390491339360768E-6
New Minimum: -40.64759556410769 > -45.32816351100161
END: th(3628800.0000000005)=-45.32816351100161; dx=-9.479464627002936E-7 evalInputDelta=4.680567946893923
Fitness changed from -40.64759556410769 to -45.32816351100161
Iteration 3 complete. Error: -45.32816351100161 Total: 19.7209; Orientation: 0.1379; Line Search: 12.2594
<a id="p-7"></a>Iteration 3
<a id="p-6"></a>![Iteration 3](etc/c1aa8292-4eac-4163-8f09-c3a4d69d07de.jpg)
Adding measurement 22b47a8e to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.023e+04, gradient 9.578e-04, dot -0.799; [f678a06b-5cc6-4407-ac4b-8ba0b6e4cae9 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -45.32816351100161, -40.64759556410769, -37.595470159864895, -37.59546815091935
LBFGS Accumulation History: 3 points
Removed measurement 22b47a8e to history. Total: 3
th(0)=-45.32816351100161;dx=-9.170380924030926E-7
New Minimum: -45.32816351100161 > -51.191124577420474
END: th(7818012.603187701)=-51.191124577420474; dx=-4.851509612723367E-7 evalInputDelta=5.862961066418862
Fitness changed from -45.32816351100161 to -51.191124577420474
Iteration 4 complete. Error: -51.191124577420474 Total: 21.8352; Orientation: 2.5667; Line Search: 12.0378
<a id="p-9"></a>Iteration 4
<a id="p-8"></a>![Iteration 4](etc/fc9601f7-328c-4dc7-b1fb-667ea1b6f9b0.jpg)
Adding measurement 5dd1023f to history. Total: 3
Rejected: LBFGS Orientation magnitude: 9.456e+03, gradient 8.424e-04, dot -0.583; [f678a06b-5cc6-4407-ac4b-8ba0b6e4cae9 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -51.191124577420474, -40.64759556410769, -37.595470159864895, -37.59546815091935
LBFGS Accumulation History: 3 points
Removed measurement 5dd1023f to history. Total: 3
th(0)=-51.191124577420474;dx=-7.089845979570473E-7
New Minimum: -51.191124577420474 > -57.07414717935044
END: th(1.6843397559414055E7)=-57.07414717935044; dx=-1.2416775109823573E-7 evalInputDelta=5.883022601929966
Fitness changed from -51.191124577420474 to -57.07414717935044
Iteration 5 complete. Error: -57.07414717935044 Total: 21.7911; Orientation: 2.5187; Line Search: 12.0985
<a id="p-11"></a>Iteration 5
<a id="p-10"></a>![Iteration 5](etc/09b668ef-2c7f-4777-9d82-ae911054f418.jpg)
Adding measurement 52c8f7e7 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.138e+04, gradient 1.023e-03, dot -0.317; [f678a06b-5cc6-4407-ac4b-8ba0b6e4cae9 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -57.07414717935044, -40.64759556410769, -37.595470159864895, -37.59546815091935
LBFGS Accumulation History: 3 points
Removed measurement 52c8f7e7 to history. Total: 3
th(0)=-57.07414717935044;dx=-1.044627725475466E-6
Armijo: th(3.628800000000001E7)=-54.091647567667245; dx=2.50186496333094E-7 evalInputDelta=-2.9824996116831954
New Minimum: -57.07414717935044 > -60.28740560272727
WOLF (strong): th(1.8144000000000004E7)=-60.28740560272727; dx=2.9494348673955676E-7 evalInputDelta=3.2132584233768284
New Minimum: -60.28740560272727 > -61.76881031787151
END: th(6048000.000000001)=-61.76881031787151; dx=-3.4149950755792074E-7 evalInputDelta=4.694663138521072
Fitness changed from -57.07414717935044 to -61.76881031787151
Iteration 6 complete. Error: -61.76881031787151 Total: 34.4251; Orientation: 2.6968; Line Search: 24.7205
Adding measurement 4f18fa1b to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.017e+04, gradient 7.157e-04, dot -0.603; [f678a06b-5cc6-4407-ac4b-8ba0b6e4cae9 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -61.76881031787151, -40.64759556410769, -37.595470159864895, -37.59546815091935
LBFGS Accumulation History: 3 points
Removed measurement 4f18fa1b to history. Total: 3
th(0)=-61.76881031787151;dx=-5.1205545591351E-7
New Minimum: -61.76881031787151 > -65.99294366181367
END: th(1.3030021005312836E7)=-65.99294366181367; dx=-1.4992658080972792E-7 evalInputDelta=4.224133343942157
Fitness changed from -61.76881031787151 to -65.99294366181367
Iteration 7 complete. Error: -65.99294366181367 Total: 21.5949; Orientation: 2.5953; Line Search: 12.9383
Adding measurement 35ae9da7 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.597e+04, gradient 8.279e-04, dot -0.480; [f678a06b-5cc6-4407-ac4b-8ba0b6e4cae9 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -65.99294366181367, -40.64759556410769, -37.595470159864895, -37.59546815091935
LBFGS Accumulation History: 3 points
Removed measurement 35ae9da7 to history. Total: 3
th(0)=-65.99294366181367;dx=-6.846893541399659E-7
New Minimum: -65.99294366181367 > -66.42959254229976
WOLF (strong): th(2.8072329265690096E7)=-66.42959254229976; dx=1.7117903007744168E-7 evalInputDelta=0.4366488804860893
New Minimum: -66.42959254229976 > -69.02061761220273
WOLF (strong): th(1.4036164632845048E7)=-69.02061761220273; dx=9.392118289981953E-8 evalInputDelta=3.027673950389058
END: th(4678721.544281683)=-68.57107379121473; dx=-3.167550013359308E-7 evalInputDelta=2.5781301294010603
Fitness changed from -65.99294366181367 to -69.02061761220273
Iteration 8 complete. Error: -69.02061761220273 Total: 33.5299; Orientation: 2.5263; Line Search: 24.9517
Adding measurement 7ec1d6d0 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.744e+04, gradient 9.508e-04, dot -0.361; [f678a06b-5cc6-4407-ac4b-8ba0b6e4cae9 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -69.02061761220273, -40.64759556410769, -37.595470159864895, -37.59546815091935
LBFGS Accumulation History: 3 points
Removed measurement 7ec1d6d0 to history. Total: 3
th(0)=-69.02061761220273;dx=-9.033973787874545E-7
New Minimum: -69.02061761220273 > -73.92827118179466
WOLF (strong): th(1.0080000000000004E7)=-73.92827118179466; dx=4.2733196670349285E-8 evalInputDelta=4.907653569591929
END: th(5040000.000000002)=-72.8891270273206; dx=-4.6523087680622533E-7 evalInputDelta=3.8685094151178703
Fitness changed from -69.02061761220273 to -73.92827118179466
Iteration 9 complete. Error: -73.92827118179466 Total: 27.5216; Orientation: 2.5136; Line Search: 18.9334
Adding measurement 2dcb44e8 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.965e+04, gradient 7.441e-04, dot -0.513; [f678a06b-5cc6-4407-ac4b-8ba0b6e4cae9 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -73.92827118179466, -40.64759556410769, -37.595470159864895, -37.59546815091935
LBFGS Accumulation History: 3 points
Removed measurement 2dcb44e8 to history. Total: 3
th(0)=-73.92827118179466;dx=-5.52339144098697E-7
New Minimum: -73.92827118179466 > -77.06817786961147
END: th(1.0858350837760698E7)=-77.06817786961147; dx=-2.562049957126052E-8 evalInputDelta=3.1399066878168185
Fitness changed from -73.92827118179466 to -77.06817786961147
Iteration 10 complete. Error: -77.06817786961147 Total: 20.3775; Orientation: 2.5621; Line Search: 12.1124
<a id="p-13"></a>Iteration 10
<a id="p-12"></a>![Iteration 10](etc/da2a4509-3ced-43f6-a701-61ea8fb0b84c.jpg)
Final threshold in iteration 11: -77.06817786961147 (> -Infinity) after 301.966s (< 5400.000s)

Returns

    -77.06817786961147