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 213.98 seconds (3.261 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: 686692344930800
Reset training subject: 686696871104900
Adding measurement 4c00d4bb to history. Total: 0
LBFGS Accumulation History: 1 points
Constructing line search parameters: GD+Trust
th(0)=-951.1684919087679;dx=-0.008058880644741563
New Minimum: -951.1684919087679 > -951.1862330795163
WOLFE (weak): th(2.154434690031884)=-951.1862330795163; dx=-0.007529492277623994 evalInputDelta=0.01774117074842252
New Minimum: -951.1862330795163 > -951.2039410662678
WOLFE (weak): th(4.308869380063768)=-951.2039410662678; dx=-0.007526899424446056 evalInputDelta=0.03544915749989741
New Minimum: -951.2039410662678 > -951.2747697169309
WOLFE (weak): th(12.926608140191302)=-951.2747697169309; dx=-0.0075279121812339015 evalInputDelta=0.10627780816298582
New Minimum: -951.2747697169309 > -951.593564763865
WOLFE (weak): th(51.70643256076521)=-951.593564763865; dx=-0.007525308507296477 evalInputDelta=0.42507285509702797
New Minimum: -951.593564763865 > -953.291731318383
WOLFE (weak): th(258.53216280382605)=-953.291731318383; dx=-0.007507647412689755 evalInputDelta=2.123239409615053
New Minimum: -953.291731318383 > -963.8315464851729
WOLFE (weak): th(1551.1929768229563)=-963.8315464851729; dx=-0.007426645910015808 evalInputDelta=12.663054576404988
New Minimum: -963.8315464851729 > -1035.6351915611983
END: th(10858.350837760694)=-1035.6351915611983; dx=-0.0066522554010300565 evalInputDelta=84.4666996524304
Fitness changed from -951.1684919087679 to -1035.6351915611983
Iteration 1 complete. Error: -1035.6351915611983 Total: 50.0278; Orientation: 0.1018; Line Search: 36.2948
<a id="p-3"></a>Iteration 1
<a id="p-2"></a>![Iteration 1](etc/bd79613a-1d40-4b52-b207-f12e1c855671.jpg)
Adding measurement 364c93da to history. Total: 1
LBFGS Accumulation History: 2 points
th(0)=-1035.6351915611983;dx=-0.006292916472742375
New Minimum: -1035.6351915611983 > -1176.6493742827554
END: th(23393.607721408407)=-1176.6493742827554; dx=-0.004672917979007898 evalInputDelta=141.01418272155706
Fitness changed from -1035.6351915611983 to -1176.6493742827554
Iteration 2 complete. Error: -1176.6493742827554 Total: 14.9030; Orientation: 0.0968; Line Search: 9.1068
<a id="p-5"></a>Iteration 2
<a id="p-4"></a>![Iteration 2](etc/fbf5cb40-b62b-44db-bb65-a2c32b7ac0d0.jpg)
Adding measurement 422ceb0a to history. Total: 2
LBFGS Accumulation History: 3 points
th(0)=-1176.6493742827554;dx=-0.0043524348275304076
New Minimum: -1176.6493742827554 > -1368.684359156632
END: th(50400.00000000001)=-1368.684359156632; dx=-0.0026598227713558525 evalInputDelta=192.0349848738765
Fitness changed from -1176.6493742827554 to -1368.684359156632
Iteration 3 complete. Error: -1368.684359156632 Total: 15.3354; Orientation: 0.1253; Line Search: 9.6294
<a id="p-7"></a>Iteration 3
<a id="p-6"></a>![Iteration 3](etc/c1f2afaf-3166-40cc-aa36-2899cd4a54d1.jpg)
Adding measurement 2b600e53 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.153e+04, gradient 5.318e-02, dot -0.788; [4ed392b2-8687-4a28-8f05-618e20553c58 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -1368.684359156632, -1176.6493742827554, -1035.6351915611983, -951.1684919087679
LBFGS Accumulation History: 3 points
Removed measurement 2b600e53 to history. Total: 3
th(0)=-1368.684359156632;dx=-0.0028226992587958603
New Minimum: -1368.684359156632 > -1603.1423049748266
END: th(108583.50837760697)=-1603.1423049748266; dx=-0.0013471639571110059 evalInputDelta=234.45794581819473
Fitness changed from -1368.684359156632 to -1603.1423049748266
Iteration 4 complete. Error: -1603.1423049748266 Total: 16.3252; Orientation: 1.7328; Line Search: 9.2100
<a id="p-9"></a>Iteration 4
<a id="p-8"></a>![Iteration 4](etc/13665af2-02db-433d-8d29-3e7321c0d8e5.jpg)
Adding measurement 7075c33d to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.265e+04, gradient 5.184e-02, dot -0.588; [4ed392b2-8687-4a28-8f05-618e20553c58 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -1603.1423049748266, -1176.6493742827554, -1035.6351915611983, -951.1684919087679
LBFGS Accumulation History: 3 points
Removed measurement 7075c33d to history. Total: 3
th(0)=-1603.1423049748266;dx=-0.0026785370516067665
New Minimum: -1603.1423049748266 > -1790.9898799267405
END: th(233936.07721408413)=-1790.9898799267405; dx=-1.7615258968560932E-4 evalInputDelta=187.84757495191388
Fitness changed from -1603.1423049748266 to -1790.9898799267405
Iteration 5 complete. Error: -1790.9898799267405 Total: 16.7886; Orientation: 1.7538; Line Search: 9.3996
<a id="p-11"></a>Iteration 5
<a id="p-10"></a>![Iteration 5](etc/ea023a55-0aa9-490f-8b5d-aaefa8354f4b.jpg)
Adding measurement 5ff312e7 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 9.729e+03, gradient 6.141e-02, dot -0.317; [4ed392b2-8687-4a28-8f05-618e20553c58 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -1790.9898799267405, -1176.6493742827554, -1035.6351915611983, -951.1684919087679
LBFGS Accumulation History: 3 points
Removed measurement 5ff312e7 to history. Total: 3
th(0)=-1790.9898799267405;dx=-0.003763289542018715
Armijo: th(504000.0000000002)=-1719.0838403056437; dx=5.478012434441016E-4 evalInputDelta=-71.90603962109685
New Minimum: -1790.9898799267405 > -1918.379654812884
WOLF (strong): th(252000.0000000001)=-1918.379654812884; dx=6.959728394810813E-4 evalInputDelta=127.38977488614341
New Minimum: -1918.379654812884 > -1984.3008844426795
END: th(84000.00000000003)=-1984.3008844426795; dx=-6.894546897319282E-4 evalInputDelta=193.31100451593898
Fitness changed from -1790.9898799267405 to -1984.3008844426795
Iteration 6 complete. Error: -1984.3008844426795 Total: 25.2619; Orientation: 1.7158; Line Search: 18.0756
Adding measurement 3a1b0805 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.549e+04, gradient 4.848e-02, dot -0.419; [4ed392b2-8687-4a28-8f05-618e20553c58 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -1984.3008844426795, -1176.6493742827554, -1035.6351915611983, -951.1684919087679
LBFGS Accumulation History: 3 points
Removed measurement 3a1b0805 to history. Total: 3
th(0)=-1984.3008844426795;dx=-0.002346628651687786
New Minimum: -1984.3008844426795 > -2126.1639165407732
WOLF (strong): th(180972.5139626783)=-2126.1639165407732; dx=1.3145013278304923E-4 evalInputDelta=141.86303209809375
END: th(90486.25698133915)=-2115.724816699941; dx=-5.741387212489104E-4 evalInputDelta=131.42393225726164
Fitness changed from -1984.3008844426795 to -2126.1639165407732
Iteration 7 complete. Error: -2126.1639165407732 Total: 20.1733; Orientation: 1.6959; Line Search: 13.8338
Adding measurement c56591 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.923e+04, gradient 6.159e-02, dot -0.324; [4ed392b2-8687-4a28-8f05-618e20553c58 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -2126.1639165407732, -1176.6493742827554, -1035.6351915611983, -951.1684919087679
LBFGS Accumulation History: 3 points
Removed measurement c56591 to history. Total: 3
th(0)=-2126.1639165407732;dx=-0.0037870871536052984
New Minimum: -2126.1639165407732 > -2198.634917397611
WOLF (strong): th(194946.7310117368)=-2198.634917397611; dx=0.0010799672943361662 evalInputDelta=72.47100085683769
New Minimum: -2198.634917397611 > -2291.663696967773
WOLF (strong): th(97473.3655058684)=-2291.663696967773; dx=1.8358737048096224E-4 evalInputDelta=165.49978042699968
END: th(32491.121835289465)=-2233.004366319063; dx=-0.002226236639976166 evalInputDelta=106.8404497782899
Fitness changed from -2126.1639165407732 to -2291.663696967773
Iteration 8 complete. Error: -2291.663696967773 Total: 24.0586; Orientation: 1.5858; Line Search: 18.0603
Adding measurement 9a5d8b9 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.447e+04, gradient 4.908e-02, dot -0.407; [4ed392b2-8687-4a28-8f05-618e20553c58 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -2291.663696967773, -1176.6493742827554, -1035.6351915611983, -951.1684919087679
LBFGS Accumulation History: 3 points
Removed measurement 9a5d8b9 to history. Total: 3
th(0)=-2291.663696967773;dx=-0.0024067407836791477
New Minimum: -2291.663696967773 > -2396.5548189015
END: th(70000.00000000003)=-2396.5548189015; dx=-5.479762680128459E-4 evalInputDelta=104.89112193372694
Fitness changed from -2291.663696967773 to -2396.5548189015
Iteration 9 complete. Error: -2396.5548189015 Total: 15.1620; Orientation: 1.5809; Line Search: 9.1590
Adding measurement 242d2281 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.195e+04, gradient 3.982e-02, dot -0.531; [4ed392b2-8687-4a28-8f05-618e20553c58 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -2396.5548189015, -1176.6493742827554, -1035.6351915611983, -951.1684919087679
LBFGS Accumulation History: 3 points
Removed measurement 242d2281 to history. Total: 3
th(0)=-2396.5548189015;dx=-0.0015834548238458875
New Minimum: -2396.5548189015 > -2495.5989261097225
END: th(150810.42830223194)=-2495.5989261097225; dx=-1.123951770242285E-4 evalInputDelta=99.04410720822261
Fitness changed from -2396.5548189015 to -2495.5989261097225
Iteration 10 complete. Error: -2495.5989261097225 Total: 15.0798; Orientation: 1.6192; Line Search: 8.9818
<a id="p-13"></a>Iteration 10
<a id="p-12"></a>![Iteration 10](etc/884ee62a-700d-45e2-9b42-e3b253eb7513.jpg)
Final threshold in iteration 11: -2495.5989261097225 (> -Infinity) after 213.976s (< 5400.000s)

Returns

    -2495.5989261097225