Iteration 1 Iteration 1

Iteration 2 Iteration 2

Iteration 3 Iteration 3

Iteration 4 Iteration 4

Iteration 5 Iteration 5

Iteration 10 Iteration 10

Iteration 15 Iteration 15

Iteration 20 Iteration 20

Iteration 25 Iteration 25

BasicOptimizer.scala:89 executed in 369.91 seconds (4.503 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: 11747450948161
Reset training subject: 11748693527012
Adding measurement 649712f3 to history. Total: 0
LBFGS Accumulation History: 1 points
Constructing line search parameters: GD+Trust
th(0)=-0.16145305259785783;dx=-0.0013616713823447844
New Minimum: -0.16145305259785783 > -0.16413646069756502
WOLFE (weak): th(2.154434690031884)=-0.16413646069756502; dx=-0.0013800558630177083 evalInputDelta=0.002683408099707185
New Minimum: -0.16413646069756502 > -0.16685578372561496
WOLFE (weak): th(4.308869380063768)=-0.16685578372561496; dx=-0.0013990925763703844 evalInputDelta=0.005402731127757132
New Minimum: -0.16685578372561496 > -0.177863969844668
WOLFE (weak): th(12.926608140191302)=-0.177863969844668; dx=-0.0014239831477775421 evalInputDelta=0.01641091724681018
New Minimum: -0.177863969844668 > -0.22747860812149007
WOLFE (weak): th(51.70643256076521)=-0.22747860812149007; dx=-0.0014624060861827878 evalInputDelta=0.06602555552363223
New Minimum: -0.22747860812149007 > -0.5175450693373187
WOLFE (weak): th(258.53216280382605)=-0.5175450693373187; dx=-0.0017402875419357693 evalInputDelta=0.3560920167394609
New Minimum: -0.5175450693373187 > -2.296697369598004
END: th(1551.1929768229563)=-2.296697369598004; dx=-0.0010294247260513416 evalInputDelta=2.1352443170001463
Fitness changed from -0.16145305259785783 to -2.296697369598004
Iteration 1 complete. Error: -2.296697369598004 Total: 11.9926; Orientation: 0.0168; Line Search: 8.4126
<a id="p-3"></a>Iteration 1
<a id="p-2"></a>![Iteration 1](etc/d54fc816-ee67-460f-bf28-18b37335b879.jpg)
Adding measurement 7a9068cf to history. Total: 1
LBFGS Accumulation History: 2 points
th(0)=-2.296697369598004;dx=-0.002884292100830515
New Minimum: -2.296697369598004 > -7.458472616977256
END: th(3341.943960201201)=-7.458472616977256; dx=-7.681852145512025E-4 evalInputDelta=5.161775247379252
Fitness changed from -2.296697369598004 to -7.458472616977256
Iteration 2 complete. Error: -7.458472616977256 Total: 5.1399; Orientation: 0.0196; Line Search: 2.4847
<a id="p-5"></a>Iteration 2
<a id="p-4"></a>![Iteration 2](etc/09c6ddc2-ea8e-46b5-ba48-a0c7f3c8be0f.jpg)
Adding measurement 5a01adae to history. Total: 2
LBFGS Accumulation History: 3 points
th(0)=-7.458472616977256;dx=-0.007177825094440607
New Minimum: -7.458472616977256 > -12.686662805893379
END: th(7200.000000000001)=-12.686662805893379; dx=-2.8195381481919155E-4 evalInputDelta=5.228190188916122
Fitness changed from -7.458472616977256 to -12.686662805893379
Iteration 3 complete. Error: -12.686662805893379 Total: 3.7353; Orientation: 0.0184; Line Search: 2.4106
<a id="p-7"></a>Iteration 3
<a id="p-6"></a>![Iteration 3](etc/f4f1f8a9-fa08-48ff-a03a-67119c1d9d80.jpg)
Adding measurement 6c5330e5 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 7.149e+03, gradient 1.055e-01, dot -0.095; [2a1dd7c3-2acd-4436-b3b0-f0ac68d8a489 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -12.686662805893379, -7.458472616977256, -2.296697369598004, -0.16145305259785783
LBFGS Accumulation History: 3 points
Removed measurement 6c5330e5 to history. Total: 3
th(0)=-12.686662805893379;dx=-0.010860945496704019
New Minimum: -12.686662805893379 > -16.316942214751048
END: th(15511.929768229566)=-16.316942214751048; dx=-6.56062056297188E-5 evalInputDelta=3.6302794088576693
Fitness changed from -12.686662805893379 to -16.316942214751048
Iteration 4 complete. Error: -16.316942214751048 Total: 4.1809; Orientation: 0.4694; Line Search: 2.4080
<a id="p-9"></a>Iteration 4
<a id="p-8"></a>![Iteration 4](etc/005cecfe-4491-4635-9ca6-450c95408646.jpg)
Adding measurement 5bce9c4d to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.379e+03, gradient 9.653e-02, dot -0.042; [2a1dd7c3-2acd-4436-b3b0-f0ac68d8a489 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -16.316942214751048, -7.458472616977256, -2.296697369598004, -0.16145305259785783
LBFGS Accumulation History: 3 points
Removed measurement 5bce9c4d to history. Total: 3
th(0)=-16.316942214751048;dx=-0.009196985641994164
New Minimum: -16.316942214751048 > -23.13966050046232
WOLF (strong): th(33419.43960201202)=-23.13966050046232; dx=2.096210879269672E-4 evalInputDelta=6.822718285711272
New Minimum: -23.13966050046232 > -33.55359143917905
WOLF (strong): th(16709.71980100601)=-33.55359143917905; dx=7.599911969233587E-5 evalInputDelta=17.236649224428003
New Minimum: -33.55359143917905 > -36.1795256227765
END: th(5569.906600335336)=-36.1795256227765; dx=-0.0016149965220585512 evalInputDelta=19.862583408025454
Fitness changed from -16.316942214751048 to -36.1795256227765
Iteration 5 complete. Error: -36.1795256227765 Total: 6.7256; Orientation: 0.5159; Line Search: 4.8993
<a id="p-11"></a>Iteration 5
<a id="p-10"></a>![Iteration 5](etc/3b536869-fc6d-4b9c-b726-87715a060a96.jpg)
Adding measurement 536af646 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 7.169e+03, gradient 1.089e-01, dot -0.075; [2a1dd7c3-2acd-4436-b3b0-f0ac68d8a489 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -36.1795256227765, -7.458472616977256, -2.296697369598004, -0.16145305259785783
LBFGS Accumulation History: 3 points
Removed measurement 536af646 to history. Total: 3
th(0)=-36.1795256227765;dx=-0.01178133273757842
New Minimum: -36.1795256227765 > -43.92928058677203
WOLF (strong): th(12000.000000000004)=-43.92928058677203; dx=5.917945878320802E-4 evalInputDelta=7.749754963995528
New Minimum: -43.92928058677203 > -53.03375305546435
END: th(6000.000000000002)=-53.03375305546435; dx=-8.453624911569243E-4 evalInputDelta=16.85422743268785
Fitness changed from -36.1795256227765 to -53.03375305546435
Iteration 6 complete. Error: -53.03375305546435 Total: 5.4734; Orientation: 0.4957; Line Search: 3.6520
Adding measurement 6b6d6064 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 4.675e+03, gradient 1.048e-01, dot -0.046; [2a1dd7c3-2acd-4436-b3b0-f0ac68d8a489 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -53.03375305546435, -7.458472616977256, -2.296697369598004, -0.16145305259785783
LBFGS Accumulation History: 3 points
Removed measurement 6b6d6064 to history. Total: 3
th(0)=-53.03375305546435;dx=-0.010893488072594763
New Minimum: -53.03375305546435 > -55.52049543355296
WOLF (strong): th(12926.608140191307)=-55.52049543355296; dx=7.009644496858499E-4 evalInputDelta=2.486742378088607
New Minimum: -55.52049543355296 > -68.91560869692869
WOLF (strong): th(6463.3040700956535)=-68.91560869692869; dx=4.371702821667619E-4 evalInputDelta=15.881855641464334
END: th(2154.4346900318847)=-68.32243937810085; dx=-0.005044673046788175 evalInputDelta=15.2886863226365
Fitness changed from -53.03375305546435 to -68.91560869692869
Iteration 7 complete. Error: -68.91560869692869 Total: 6.5405; Orientation: 0.4657; Line Search: 4.9082
Adding measurement 56845908 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.027e+04, gradient 1.270e-01, dot -0.061; [2a1dd7c3-2acd-4436-b3b0-f0ac68d8a489 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -68.91560869692869, -7.458472616977256, -2.296697369598004, -0.16145305259785783
LBFGS Accumulation History: 3 points
Removed measurement 56845908 to history. Total: 3
th(0)=-68.91560869692869;dx=-0.015974601369840725
New Minimum: -68.91560869692869 > -88.52788411083066
END: th(4641.588833612781)=-88.52788411083066; dx=-7.025396978099828E-7 evalInputDelta=19.61227541390197
Fitness changed from -68.91560869692869 to -88.52788411083066
Iteration 8 complete. Error: -88.52788411083066 Total: 4.5580; Orientation: 0.4752; Line Search: 2.8661
Adding measurement 7333bb92 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.234e+04, gradient 1.095e-01, dot -0.095; [2a1dd7c3-2acd-4436-b3b0-f0ac68d8a489 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -88.52788411083066, -7.458472616977256, -2.296697369598004, -0.16145305259785783
LBFGS Accumulation History: 3 points
Removed measurement 7333bb92 to history. Total: 3
th(0)=-88.52788411083066;dx=-0.01184543483222776
Armijo: th(10000.000000000005)=-84.43199161731367; dx=0.0018823793131174634 evalInputDelta=-4.095892493516985
New Min

...skipping 31160 bytes...

Delta=-0.0034579373177621164
Armijo: th(5.287919233440358E-5)=-175.61326154880555; dx=-18.854233869885924 evalInputDelta=-6.320909832311372E-4
Armijo: th(8.813198722400596E-6)=-175.61380334121617; dx=-18.80292943260973 evalInputDelta=-9.029857261566576E-5
Armijo: th(1.2590283889143708E-6)=-175.6138883281093; dx=-19.34244166977348 evalInputDelta=-5.311679473152253E-6
New Minimum: -175.61389363978878 > -175.61389895146806
END: th(1.5737854861429635E-7)=-175.61389895146806; dx=-18.596204959792168 evalInputDelta=5.311679274200287E-6
Fitness changed from -175.61389363978878 to -175.61389895146806
Iteration 27 complete. Error: -175.61389895146806 Total: 12.9652; Orientation: 0.8060; Line Search: 10.9898
Adding measurement 7995c63c to history. Total: 7
Accepted: LBFGS Orientation magnitude: 1.053e+04, gradient 9.891e-02, dot 0.019; [2a1dd7c3-2acd-4436-b3b0-f0ac68d8a489 = 1.000/1.000e+00]
th(0)=-175.61389895146806;dx=-18.778264077011208
Armijo: th(3.3906180460150933E-7)=-175.61389363978878; dx=-17.893630429020977 evalInputDelta=-5.311679274200287E-6
Armijo: th(1.6953090230075466E-7)=-175.61389363978878; dx=-17.753485469162584 evalInputDelta=-5.311679274200287E-6
New Minimum: -175.61389895146806 > -175.61390957482618
WOLFE (weak): th(5.651030076691822E-8)=-175.61390957482618; dx=-17.92646347226168 evalInputDelta=1.0623358122074933E-5
Armijo: th(1.1302060153383644E-7)=-175.61389895146806; dx=-17.858402709257497 evalInputDelta=0.0
WOLFE (weak): th(8.476545115037733E-8)=-175.61390957482618; dx=-18.065200452636017 evalInputDelta=1.0623358122074933E-5
Armijo: th(9.889302634210689E-8)=-175.61389363978878; dx=-18.077610057209203 evalInputDelta=-5.311679274200287E-6
Armijo: th(9.182923874624211E-8)=-175.61389363978878; dx=-19.40575913892848 evalInputDelta=-5.311679274200287E-6
Armijo: th(8.829734494830973E-8)=-175.61389895146806; dx=-17.966739154378025 evalInputDelta=0.0
Armijo: th(8.653139804934353E-8)=-175.61389895146806; dx=-17.923250456615015 evalInputDelta=0.0
Armijo: th(8.564842459986042E-8)=-175.61389895146806; dx=-17.87621764863054 evalInputDelta=0.0
Armijo: th(8.520693787511888E-8)=-175.61389363978878; dx=-17.79196726614536 evalInputDelta=-5.311679274200287E-6
Armijo: th(8.49861945127481E-8)=-175.61389895146806; dx=-17.2345750612676 evalInputDelta=0.0
Armijo: th(8.487582283156273E-8)=-175.61389895146806; dx=-17.63477704195479 evalInputDelta=0.0
Armijo: th(8.482063699097003E-8)=-175.61389895146806; dx=-17.897847563200166 evalInputDelta=0.0
Armijo: th(8.479304407067369E-8)=-175.61389363978878; dx=-19.592426115434293 evalInputDelta=-5.311679274200287E-6
Armijo: th(8.477924761052551E-8)=-175.61389895146806; dx=-17.852640996726976 evalInputDelta=0.0
WOLFE (weak): th(8.477234938045142E-8)=-175.61390957482618; dx=-18.543569584136023 evalInputDelta=1.0623358122074933E-5
WOLFE (weak): th(8.477579849548847E-8)=-175.61390957482618; dx=-17.949722998124717 evalInputDelta=1.0623358122074933E-5
WOLFE (weak): th(8.477752305300699E-8)=-175.61390957482618; dx=-17.614790275162466 evalInputDelta=1.0623358122074933E-5
WOLFE (weak): th(8.477838533176625E-8)=-175.61390957482618; dx=-17.42752782601709 evalInputDelta=1.0623358122074933E-5
Armijo: th(8.477881647114588E-8)=-175.61389895146806; dx=-18.661044634324465 evalInputDelta=0.0
mu ~= nu (8.477838533176625E-8): th(5.651030076691822E-8)=-175.61390957482618
Fitness changed from -175.61389895146806 to -175.61390957482618
Iteration 28 complete. Error: -175.61390957482618 Total: 30.5107; Orientation: 0.9158; Line Search: 28.4405
Adding measurement 562bee3 to history. Total: 8
Accepted: LBFGS Orientation magnitude: 1.050e+04, gradient 9.917e-02, dot 0.019; [2a1dd7c3-2acd-4436-b3b0-f0ac68d8a489 = 1.000/1.000e+00]
th(0)=-175.61390957482618;dx=-18.13285241022611
Armijo: th(1.8264995875446526E-7)=-175.61389363978878; dx=-17.38344562480202 evalInputDelta=-1.593503739627522E-5
Armijo: th(9.132497937723263E-8)=-175.61389363978878; dx=-17.27086418657926 evalInputDelta=-1.593503739627522E-5
Armijo: th(3.044165979241088E-8)=-175.61389363978878; dx=-17.249918537869306 evalInputDelta=-1.593503739627522E-5
Armijo: th(7.61041494810272E-9)=-175.61389363978878; dx=-18.324174075892998 evalInputDelta=-1.593503739627522E-5
Armijo: th(1.522082989620544E-9)=-175.61389363978878; dx=-17.00453476287347 evalInputDelta=-1.593503739627522E-5
Armijo: th(2.5368049827009066E-10)=-175.61389363978878; dx=-15.03762137793655 evalInputDelta=-1.593503739627522E-5
MIN ALPHA (3.624007118144152E-11): th(0.0)=-175.61390957482618
Fitness changed from -175.61390957482618 to -175.61390957482618
Static Iteration Total: 12.0091; Orientation: 1.0598; Line Search: 9.7391
Iteration 29 failed. Error: -175.61390957482618
Previous Error: 0.0 -> -175.61390957482618
Retrying iteration 29
Reset training subject: 12080437675104
Adding measurement 2c75fce5 to history. Total: 0
LBFGS Accumulation History: 1 points
th(0)=-175.61390957482618;dx=-0.009556934493452386
WOLFE (weak): th(2.1544346900318838E-10)=-175.61390957482618; dx=-0.009700264888938827 evalInputDelta=0.0
WOLFE (weak): th(4.3088693800637676E-10)=-175.61390957482618; dx=-0.009714975760194356 evalInputDelta=0.0
WOLFE (weak): th(1.2926608140191302E-9)=-175.61390957482618; dx=-0.009659069667841936 evalInputDelta=0.0
WOLFE (weak): th(5.170643256076521E-9)=-175.61390957482618; dx=-0.009701954646072122 evalInputDelta=0.0
WOLFE (weak): th(2.5853216280382606E-8)=-175.61390957482618; dx=-0.009701827031600468 evalInputDelta=0.0
WOLFE (weak): th(1.5511929768229565E-7)=-175.61390957482618; dx=-0.009707639238515958 evalInputDelta=0.0
WOLFE (weak): th(1.0858350837760695E-6)=-175.61390957482618; dx=-0.00968537204378693 evalInputDelta=0.0
Armijo: th(8.686680670208556E-6)=-175.61389363978878; dx=-0.009684396350178821 evalInputDelta=-1.593503739627522E-5
WOLFE (weak): th(4.886257876992313E-6)=-175.61390957482618; dx=-0.00969040797894973 evalInputDelta=0.0
Armijo: th(6.7864692736004345E-6)=-175.61389363978878; dx=-0.009718028180714173 evalInputDelta=-1.593503739627522E-5
Armijo: th(5.836363575296374E-6)=-175.61389363978878; dx=-0.009706601492854636 evalInputDelta=-1.593503739627522E-5
Armijo: th(5.361310726144344E-6)=-175.61389895146806; dx=-0.00971435376002867 evalInputDelta=-1.0623358122074933E-5
Armijo: th(5.123784301568328E-6)=-175.61389895146806; dx=-0.009673915590149929 evalInputDelta=-1.0623358122074933E-5
WOLFE (weak): th(5.0050210892803206E-6)=-175.61390957482618; dx=-0.009695212059554724 evalInputDelta=0.0
Armijo: th(5.064402695424325E-6)=-175.61389895146806; dx=-0.00971527234733379 evalInputDelta=-1.0623358122074933E-5
Armijo: th(5.034711892352323E-6)=-175.61389895146806; dx=-0.009674740821065276 evalInputDelta=-1.0623358122074933E-5
Armijo: th(5.019866490816322E-6)=-175.61389895146806; dx=-0.009712512991671161 evalInputDelta=-1.0623358122074933E-5
WOLFE (weak): th(5.012443790048322E-6)=-175.61390957482618; dx=-0.009711275928295111 evalInputDelta=0.0
WOLFE (weak): th(5.016155140432322E-6)=-175.61390957482618; dx=-0.009617421054236089 evalInputDelta=0.0
Armijo: th(5.018010815624323E-6)=-175.61389895146806; dx=-0.009714230877312376 evalInputDelta=-1.0623358122074933E-5
WOLFE (weak): th(5.017082978028323E-6)=-175.61390957482618; dx=-0.009703286005213472 evalInputDelta=0.0
WOLFE (weak): th(5.017546896826323E-6)=-175.61390957482618; dx=-0.009601503634112576 evalInputDelta=0.0
Armijo: th(5.017778856225323E-6)=-175.61389895146806; dx=-0.009715523843227816 evalInputDelta=-1.0623358122074933E-5
WOLFE (weak): th(5.017662876525823E-6)=-175.61390957482618; dx=-0.009690515939895264 evalInputDelta=0.0
Armijo: th(5.017720866375572E-6)=-175.61389895146806; dx=-0.009616528089246398 evalInputDelta=-1.0623358122074933E-5
Armijo: th(5.017691871450698E-6)=-175.61389895146806; dx=-0.00971705620576244 evalInputDelta=-1.0623358122074933E-5
mu ~= nu (5.017662876525823E-6): th(0.0)=-175.61390957482618
Fitness changed from -175.61390957482618 to -175.61390957482618
Static Iteration Total: 36.9220; Orientation: 0.0173; Line Search: 34.5728
Iteration 30 failed. Error: -175.61390957482618
Previous Error: 0.0 -> -175.61390957482618
Optimization terminated 30
Final threshold in iteration 30: -175.61390957482618 (> -Infinity) after 369.909s (< 3600.000s)

Returns

    -175.61390957482618