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 205.33 seconds (1.990 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: 11178859556549
Reset training subject: 11183217606879
Adding measurement 4e13bfd1 to history. Total: 0
LBFGS Accumulation History: 1 points
Constructing line search parameters: GD+Trust
th(0)=0.28536221385002136;dx=-8.103445717252546E-7
New Minimum: 0.28536221385002136 > 0.28536146879196167
WOLFE (weak): th(2.154434690031884)=0.28536146879196167; dx=-7.611624532245271E-7 evalInputDelta=7.450580596923828E-7
New Minimum: 0.28536146879196167 > 0.28536054491996765
WOLFE (weak): th(4.308869380063768)=0.28536054491996765; dx=-7.611607102333964E-7 evalInputDelta=1.6689300537109375E-6
New Minimum: 0.28536054491996765 > 0.285357266664505
WOLFE (weak): th(12.926608140191302)=0.285357266664505; dx=-7.611557094265605E-7 evalInputDelta=4.947185516357422E-6
New Minimum: 0.285357266664505 > 0.28534257411956787
WOLFE (weak): th(51.70643256076521)=0.28534257411956787; dx=-7.611459620634072E-7 evalInputDelta=1.963973045349121E-5
New Minimum: 0.28534257411956787 > 0.2852638065814972
WOLFE (weak): th(258.53216280382605)=0.2852638065814972; dx=-7.611103855484222E-7 evalInputDelta=9.840726852416992E-5
New Minimum: 0.2852638065814972 > 0.28477197885513306
WOLFE (weak): th(1551.1929768229563)=0.28477197885513306; dx=-7.608482555578104E-7 evalInputDelta=5.902349948883057E-4
New Minimum: 0.28477197885513306 > 0.2812356948852539
WOLFE (weak): th(10858.350837760694)=0.2812356948852539; dx=-7.58943314322613E-7 evalInputDelta=0.004126518964767456
New Minimum: 0.2812356948852539 > 0.25269001722335815
WOLFE (weak): th(86866.80670208555)=0.25269001722335815; dx=-7.429041812261369E-7 evalInputDelta=0.03267219662666321
New Minimum: 0.25269001722335815 > 0.02177491784095764
END: th(781801.26031877)=0.02177491784095764; dx=-5.847034997528832E-7 evalInputDelta=0.2635872960090637
Fitness changed from 0.28536221385002136 to 0.02177491784095764
Iteration 1 complete. Error: 0.02177491784095764 Total: 56.0056; Orientation: 0.0451; Line Search: 42.5990
<a id="p-3"></a>Iteration 1
<a id="p-2"></a>![Iteration 1](etc/c660805d-7c4b-4b03-b58e-7ab088228fdd.jpg)

    Adding measurement 2f9e5465 to history. Total: 1
    LBFGS Accumulation History: 2 points
    th(0)=0.02177491784095764;dx=-5.170624634247502E-7
    New Minimum: 0.02177491784095764 > -0.3338746130466461
    END: th(1684339.7559414052)=-0.3338746130466461; dx=-3.3409779820444354E-7 evalInputDelta=0.35564953088760376
    Fitness changed from 0.02177491784095764 to -0.3338746130466461
    Iteration 2 complete. Error: -0.3338746130466461 Total: 12.7731; Orientation: 0.0534; Line Search: 8.3400
    <a id="p-5"></a>Iteration 2
    <a id="p-4"></a>![Iteration 2](etc/dfb96c33-727b-4bff-a20d-2c521ede7bef.jpg)

    Adding measurement 4b52a29 to history. Total: 2
    LBFGS Accumulation History: 3 points
    th(0)=-0.3338746130466461;dx=-2.948863337923089E-7
    New Minimum: -0.3338746130466461 > -0.7367250919342041
    END: th(3628800.0)=-0.7367250919342041; dx=-1.5914409030401518E-7 evalInputDelta=0.402850478887558
    Fitness changed from -0.3338746130466461 to -0.7367250919342041
    Iteration 3 complete. Error: -0.7367250919342041 Total: 12.7987; Orientation: 0.0461; Line Search: 8.4536
    <a id="p-7"></a>Iteration 3
    <a id="p-6"></a>![Iteration 3](etc/c192b7d0-3859-4384-9793-9785d3cb7c36.jpg)

    Adding measurement 213ee0ee to history. Total: 3
    Rejected: LBFGS Orientation magnitude: 3.432e+03, gradient 3.939e-04, dot -0.837; [ba00741a-38ab-4b3b-b0e8-b852063b89a2 = 1.000/1.000e+00]
    Orientation rejected. Popping history element from -0.7367250919342041, -0.3338746130466461, 0.02177491784095764, 0.28536221385002136
    LBFGS Accumulation History: 3 points
    Removed measurement 213ee0ee to history. Total: 3
    th(0)=-0.7367250919342041;dx=-1.5517030130757377E-7
    New Minimum: -0.7367250919342041 > -1.1159447729587555
    END: th(7818012.6031877)=-1.1159447729587555; dx=-5.5289887727950274E-8 evalInputDelta=0.3792196810245514
    Fitness changed from -0.7367250919342041 to -1.1159447729587555
    Iteration 4 complete. Error: -1.1159447729587555 Total: 14.4635; Orientation: 1.0137; Line Search: 8.8831
    <a id="p-9"></a>Iteration 4
    <a id="p-8"></a>![Iteration 4](etc/b14bd0cd-9312-4b79-b820-485663c6a458.jpg)

    Adding measurement 7842c7ae to history. Total: 3
    Rejected: LBFGS Orientation magnitude: 2.558e+03, gradient 3.069e-04, dot -0.634; [ba00741a-38ab-4b3b-b0e8-b852063b89a2 = 1.000/1.000e+00]
    Orientation rejected. Popping history element from -1.1159447729587555, -0.3338746130466461, 0.02177491784095764, 0.28536221385002136
    LBFGS Accumulation History: 3 points
    Removed measurement 7842c7ae to history. Total: 3
    th(0)=-1.1159447729587555;dx=-9.415944477255371E-8
    New Minimum: -1.1159447729587555 > -1.3522091209888458
    WOLF (strong): th(1.684339755941405E7)=-1.3522091209888458; dx=1.880532055646684E-9 evalInputDelta=0.23626434803009033
    END: th(8421698.779707026)=-1.3232621252536774; dx=-1.91846308502967E-8 evalInputDelta=0.20731735229492188
    Fitness changed from -1.1159447729587555 to -1.3522091209888458
    Iteration 5 complete. Error: -1.3522091209888458 Total: 18.1008; Orientation: 1.0103; Line Search: 12.9610
    <a id="p-11"></a>Iteration 5
    <a id="p-10"></a>![Iteration 5](etc/f3e03f41-b2fb-40aa-97cf-6362aa87c1a0.jpg)

    Adding measurement 44aa82da to history. Total: 3
    Rejected: LBFGS Orientation magnitude: 1.678e+03, gradient 3.383e-04, dot -0.401; [ba00741a-38ab-4b3b-b0e8-b852063b89a2 = 1.000/1.000e+00]
    Orientation rejected. Popping history element from -1.3522091209888458, -0.3338746130466461, 0.02177491784095764, 0.28536221385002136
    LBFGS Accumulation History: 3 points
    Removed measurement 44aa82da to history. Total: 3
    th(0)=-1.3522091209888458;dx=-1.1442459887689694E-7
    New Minimum: -1.3522091209888458 > -1.4478293061256409
    WOLF (strong): th(1.8144E7)=-1.4478293061256409; dx=3.574347269309586E-8 evalInputDelta=0.09562018513679504
    New Minimum: -1.4478293061256409 > -1.5508109331130981
    WOLF (strong): th(9072000.0)=-1.5508109331130981; dx=1.6194947141996397E-9 evalInputDelta=0.19860181212425232
    END: th(3024000.0)=-1.4800772964954376; dx=-5.64004537922325E-8 evalInputDelta=0.1278681755065918
    Fitness changed from -1.3522091209888458 to -1.5508109331130981
    Iteration 6 complete. Error: -1.5508109331130981 Total: 23.3086; Orientation: 1.0461; Line Search: 17.2089
    Adding measurement 707195b to history. Total: 3
    Rejected: LBFGS Orientation magnitude: 1.985e+03, gradient 2.327e-04, dot -0.421; [ba00741a-38ab-4b3b-b0e8-b852063b89a2 = 1.000/1.000e+00]
    Orientation rejected. Popping history element from -1.5508109331130981, -0.3338746130466461, 0.02177491784095764, 0.28536221385002136
    LBFGS Accumulation History: 3 points
    Removed measurement 707195b to history. Total: 3
    th(0)=-1.5508109331130981;dx=-5.413859250724886E-8
    New Minimum: -1.5508109331130981 > -1.6638194471597672
    END: th(6515010.502656417)=-1.6638194471597672; dx=-1.8988209789946525E-8 evalInputDelta=0.113008514046669
    Fitness changed from -1.5508109331130981 to -1.6638194471597672
    Iteration 7 complete. Error: -1.6638194471597672 Total: 13.4765; Orientation: 0.9974; Line Search: 8.6670
    Adding measurement 63500184 to history. Total: 3
    Rejected: LBFGS Orientation magnitude: 2.444e+03, gradient 1.646e-04, dot -0.539; [ba00741a-38ab-4b3b-b0e8-b852063b89a2 = 1.000/1.000e+00]
    Orientation rejected. Popping history element from -1.6638194471597672, -0.3338746130466461, 0.02177491784095764, 0.28536221385002136
    LBFGS Accumulation History: 3 points
    Removed measurement 63500184 to history. Total: 3
    th(0)=-1.6638194471597672;dx=-2.709720856685845E-8
    New Minimum: -1.6638194471597672 > -1.7767260372638702
    END: th(1.4036164632845046E7)=-1.7767260372638702; dx=-6.392896667509322E-9 evalInputDelta=0.11290659010410309
    Fitness changed from -1.6638194471597672 to -1.7767260372638702
    Iteration 8 complete. Error: -1.7767260372638702 Total: 14.3036; Orientation: 1.0499; Line Search: 8.5436
    Adding measurement 6e069fb3 to history. Total: 3
    Rejected: LBFGS Orientation magnitude: 2.490e+03, gradient 1.859e-04, dot -0.430; [ba00741a-38ab-4b3b-b0e8-b852063b89a2 = 1.000/1.000e+00]
    Orientation rejected. Popping history element from -1.7767260372638702, -0.3338746130466461, 0.02177491784095764, 0.28536221385002136
    LBFGS Accumulation History: 3 points
    Removed measurement 6e069fb3 to history. Total: 3
    th(0)=-1.7767260372638702;dx=-3.4567011930208805E-8
    Armijo: th(3.0240000000000007E7)=-1.7639563530683517; dx=1.2797175970304483E-8 evalInputDelta=-0.012769684195518494
    New Minimum: -1.7767260372638702 > -1.8356132805347443
    WOLF (strong): th(1.5120000000000004E7)=-1.8356132805347443; dx=5.08730686452069E-9 evalInputDelta=0.05888724327087402
    END: th(5040000.000000001)=-1.8314339965581894; dx=-1.0857804186637401E-8 evalInputDelta=0.05470795929431915
    Fitness changed from -1.7767260372638702 to -1.8356132805347443
    Iteration 9 complete. Error: -1.8356132805347443 Total: 22.3268; Orientation: 1.0040; Line Search: 17.1330
    Adding measurement 10df2174 to history. Total: 3
    Rejected: LBFGS Orientation magnitude: 2.272e+03, gradient 1.975e-04, dot -0.364; [ba00741a-38ab-4b3b-b0e8-b852063b89a2 = 1.000/1.000e+00]
    Orientation rejected. Popping history element from -1.8356132805347443, -0.3338746130466461, 0.02177491784095764, 0.28536221385002136
    LBFGS Accumulation History: 3 points
    Removed measurement 10df2174 to history. Total: 3
    th(0)=-1.8356132805347443;dx=-3.9013564741101685E-8
    New Minimum: -1.8356132805347443 > -1.9268763363361359
    WOLF (strong): th(1.0858350837760696E7)=-1.9268763363361359; dx=3.2989314180900735E-9 evalInputDelta=0.0912630558013916
    END: th(5429175.418880348)=-1.9102925807237625; dx=-1.6167361017760277E-8 evalInputDelta=0.07467930018901825
    Fitness changed from -1.8356132805347443 to -1.9268763363361359
    Iteration 10 complete. Error: -1.9268763363361359 Total: 17.6979; Orientation: 1.0186; Line Search: 12.4275
    <a id="p-13"></a>Iteration 10
    <a id="p-12"></a>![Iteration 10](etc/cc92ef48-cc36-4cd9-99a2-23cdd8e8f0e7.jpg)

    Final threshold in iteration 11: -1.9268763363361359 (> -Infinity) after 205.325s (< 5400.000s)

Returns

    -1.9268763363361359