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

BasicOptimizer.scala:89 executed in 58.63 seconds (1.457 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: 211912938023600
Reset training subject: 211913809885700
Adding measurement 422179c7 to history. Total: 0
LBFGS Accumulation History: 1 points
Constructing line search parameters: GD+Trust
th(0)=107.30377978338824;dx=-0.009021188424782724
New Minimum: 107.30377978338824 > 107.28929666729579
WOLFE (weak): th(2.154434690031884)=107.28929666729579; dx=-0.009057063208840255 evalInputDelta=0.014483116092449677
New Minimum: 107.28929666729579 > 107.27478921511835
WOLFE (weak): th(4.308869380063768)=107.27478921511835; dx=-0.009131174943353984 evalInputDelta=0.028990568269890105
New Minimum: 107.27478921511835 > 107.2165791613034
WOLFE (weak): th(12.926608140191302)=107.2165791613034; dx=-0.008938171101000519 evalInputDelta=0.08720062208483625
New Minimum: 107.2165791613034 > 106.95060156711747
WOLFE (weak): th(51.70643256076521)=106.95060156711747; dx=-0.00903653116129084 evalInputDelta=0.35317821627076285
New Minimum: 106.95060156711747 > 105.39455607876357
WOLFE (weak): th(258.53216280382605)=105.39455607876357; dx=-0.010142413579940932 evalInputDelta=1.9092237046246652
New Minimum: 105.39455607876357 > 94.62159929719932
WOLFE (weak): th(1551.1929768229563)=94.62159929719932; dx=-0.009608701328908105 evalInputDelta=12.682180486188912
New Minimum: 94.62159929719932 > 55.27460680293882
END: th(10858.350837760694)=55.27460680293882; dx=-0.00251445627154176 evalInputDelta=52.02917298044942
Fitness changed from 107.30377978338824 to 55.27460680293882
Iteration 1 complete. Error: 55.27460680293882 Total: 9.3219; Orientation: 0.0175; Line Search: 6.8503
<a id="p-3"></a>Iteration 1
<a id="p-2"></a>![Iteration 1](etc/27253d6d-e3f6-448b-97a2-9b9c89e6ca9d.jpg)
Adding measurement 29e0fdd8 to history. Total: 1
LBFGS Accumulation History: 2 points
th(0)=55.27460680293882;dx=-0.013751499149872027
New Minimum: 55.27460680293882 > -13.260034103385578
END: th(23393.607721408407)=-13.260034103385578; dx=-0.0015969428612302974 evalInputDelta=68.5346409063244
Fitness changed from 55.27460680293882 to -13.260034103385578
Iteration 2 complete. Error: -13.260034103385578 Total: 2.3696; Orientation: 0.0199; Line Search: 1.5523
<a id="p-5"></a>Iteration 2
<a id="p-4"></a>![Iteration 2](etc/36852198-3c8f-43c6-a1ff-1de274474456.jpg)
Adding measurement 5982f78 to history. Total: 2
LBFGS Accumulation History: 3 points
th(0)=-13.260034103385578;dx=-0.01703545677684156
New Minimum: -13.260034103385578 > -38.92396440605219
WOLF (strong): th(50400.00000000001)=-38.92396440605219; dx=1.3937857125964764E-4 evalInputDelta=25.663930302666614
New Minimum: -38.92396440605219 > -88.44214495638016
END: th(25200.000000000004)=-88.44214495638016; dx=-0.0019052192056573931 evalInputDelta=75.18211085299458
Fitness changed from -13.260034103385578 to -88.44214495638016
Iteration 3 complete. Error: -88.44214495638016 Total: 3.1867; Orientation: 0.0176; Line Search: 2.4315
<a id="p-7"></a>Iteration 3
<a id="p-6"></a>![Iteration 3](etc/69c8e517-f106-406e-81eb-c720b1898747.jpg)
Adding measurement 429b336b to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.238e+03, gradient 1.293e-01, dot -0.238; [fd0d0272-16d3-4f25-8625-c3b4965fd525 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -88.44214495638016, -13.260034103385578, 55.27460680293882, 107.30377978338824
LBFGS Accumulation History: 3 points
Removed measurement 429b336b to history. Total: 3
th(0)=-88.44214495638016;dx=-0.01671500957736387
New Minimum: -88.44214495638016 > -93.30211852523195
WOLF (strong): th(54291.75418880348)=-93.30211852523195; dx=8.103651388414344E-5 evalInputDelta=4.859973568851785
New Minimum: -93.30211852523195 > -167.10335352115055
END: th(27145.87709440174)=-167.10335352115055; dx=-0.002531894885365869 evalInputDelta=78.66120856477039
Fitness changed from -88.44214495638016 to -167.10335352115055
Iteration 4 complete. Error: -167.10335352115055 Total: 3.9190; Orientation: 0.3229; Line Search: 2.5092
<a id="p-9"></a>Iteration 4
<a id="p-8"></a>![Iteration 4](etc/5e670893-1c31-4b4b-a09a-366c0899c4a0.jpg)
Adding measurement 5f36c928 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.564e+03, gradient 1.269e-01, dot -0.227; [fd0d0272-16d3-4f25-8625-c3b4965fd525 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -167.10335352115055, -13.260034103385578, 55.27460680293882, 107.30377978338824
LBFGS Accumulation History: 3 points
Removed measurement 5f36c928 to history. Total: 3
th(0)=-167.10335352115055;dx=-0.016072694487172946
Armijo: th(58484.01930352103)=-129.57817964740224; dx=2.1076491720708E-4 evalInputDelta=-37.525173873748315
New Minimum: -167.10335352115055 > -238.44765781220144
END: th(29242.009651760516)=-238.44765781220144; dx=-0.0026912133845143275 evalInputDelta=71.34430429105089
Fitness changed from -167.10335352115055 to -238.44765781220144
Iteration 5 complete. Error: -238.44765781220144 Total: 3.5708; Orientation: 0.3254; Line Search: 2.4101
<a id="p-11"></a>Iteration 5
<a id="p-10"></a>![Iteration 5](etc/5f52d902-2c78-4939-b70f-f1a670c0256a.jpg)
Adding measurement 24378e1d to history. Total: 3
Rejected: LBFGS Orientation magnitude: 4.455e+03, gradient 1.278e-01, dot -0.205; [fd0d0272-16d3-4f25-8625-c3b4965fd525 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -238.44765781220144, -13.260034103385578, 55.27460680293882, 107.30377978338824
LBFGS Accumulation History: 3 points
Removed measurement 24378e1d to history. Total: 3
th(0)=-238.44765781220144;dx=-0.01629763828943169
Armijo: th(63000.00000000002)=-160.02993296212418; dx=3.449937679124363E-4 evalInputDelta=-78.41772485007726
New Minimum: -238.44765781220144 > -300.2317639777763
END: th(31500.00000000001)=-300.2317639777763; dx=-0.0026593884482734136 evalInputDelta=61.78410616557488
Fitness changed from -238.44765781220144 to -300.2317639777763
Iteration 6 complete. Error: -300.2317639777763 Total: 3.8097; Orientation: 0.3077; Line Search: 2.6789
Adding measurement 52021702 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 5.945e+03, gradient 1.289e-01, dot -0.179; [fd0d0272-16d3-4f25-8625-c3b4965fd525 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -300.2317639777763, -13.260034103385578, 55.27460680293882, 107.30377978338824
LBFGS Accumulation History: 3 points
Removed measurement 52021702 to history. Total: 3
th(0)=-300.2317639777763;dx=-0.016577097028852746
Armijo: th(67864.69273600436)=-198.5953087229612; dx=6.071179986289954E-4 evalInputDelta=-101.63645525481513
New Minimum: -300.2317639777763 > -366.1924153375918
END: th(33932.34636800218)=-366.1924153375918; dx=-0.0025984385250589705 evalInputDelta=65.96065135981547
Fitness changed from -300.2317639777763 to -366.1924153375918
Iteration 7 complete. Error: -366.1924153375918 Total: 3.7106; Orientation: 0.3254; Line Search: 2.7103
Adding measurement 78865ca7 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 8.654e+03, gradient 1.265e-01, dot -0.159; [fd0d0272-16d3-4f25-8625-c3b4965fd525 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -366.1924153375918, -13.260034103385578, 55.27460680293882, 107.30377978338824
LBFGS Accumulation History: 3 points
Removed measurement 78865ca7 to history. Total: 3
th(0)=-366.1924153375918;dx=-0.015985629966060864
Armijo: th(73105.0241294013)=-227.61559702416736; dx=8.131338488040175E-4 evalInputDelta=-138.57681831342444
New Minimum: -366.1924153375918 > -418.637341068777
END: th(36552.51206470065)=-418.637341068777; dx=-0.002508239165946461 evalInputDelta=52.44492573118521
Fitness changed from -366.1924153375918 to -418.637341068777
Iteration 8 complete. Error: -418.637341068777 Total: 4.0510; Orientation: 0.3234; Line Search: 2.9010
Adding measurement 429e4a76 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.315e+04, gradient 1.277e-01, dot -0.146; [fd0d0272-16d3-4f25-8625-c3b4965fd525 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -418.637341068777, -13.260034103385578, 55.27460680293882, 107.30377978338824
LBFGS Accumulation History: 3 points
Removed measurement 429e4a76 to history. Total: 3
th(0)=-418.637341068777;dx=-0.016295510994064344
Armijo: th(78750.00000000003)=-240.23200697265128; dx=0.0010415944705839772 evalInputDelta=-178.40533409612573
New Minimum: -418.637341068777 > -462.757642593844
END: th(39375.000000000015)=-462.757642593844; dx=-0.002219616379619891 evalInputDelta=44.12030152506702
Fitness changed from -418.637341068777 to -462.757642593844
Iteration 9 complete. Error: -462.757642593844 Total: 3.6089; Orientation: 0.2944; Line Search: 2.5329
Adding measurement 4d5d8bdb to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.736e+04, gradient 1.276e-01, dot -0.131; [fd0d0272-16d3-4f25-8625-c3b4965fd525 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -462.757642593844, -13.260034103385578, 55.27460680293882, 107.30377978338824
LBFGS Accumulation History: 3 points
Removed measurement 4d5d8bdb to history. Total: 3
th(0)=-462.757642593844;dx=-0.016244736564860328
Armijo: th(84830.86592000545)=-253.21587855469852; dx=0.0012451375876804886 evalInputDelta=-209.5417640391455
New Minimum: -462.757642593844 > -500.56425673149806
END: th(42415.43296000273)=-500.56425673149806; dx=-0.0019210385615770478 evalInputDelta=37.80661413765404
Fitness changed from -462.757642593844 to -500.56425673149806
Iteration 10 complete. Error: -500.56425673149806 Total: 3.7113; Orientation: 0.3065; Line Search: 2.7305
<a id="p-13"></a>Iteration 10
<a id="p-12"></a>![Iteration 10](etc/56210bdd-7380-41a3-9ade-050bb28d81d6.jpg)
Adding measurement 1db47316 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.380e+04, gradient 1.259e-01, dot -0.120; [fd0d0272-16d3-4f25-8625-c3b4965fd525 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -500.56425673149806, -13.260034103385578, 55.27460680293882, 107.30377978338824
LBFGS Accumulation History: 3 points
Removed measurement 1db47316 to history. Total: 3
th(0)=-500.56425673149806;dx=-0.01580444402206436
Armijo: th(91381.28016175162)=-285.8704641642846; dx=0.0012267610661072952 evalInputDelta=-214.69379256721345
New Minimum: -500.56425673149806 > -548.5193081714274
END: th(45690.64008087581)=-548.5193081714274; dx=-0.001898457781388115 evalInputDelta=47.95505143992932
Fitness changed from -500.56425673149806 to -548.5193081714274
Iteration 11 complete. Error: -548.5193081714274 Total: 3.4983; Orientation: 0.3444; Line Search: 2.4697
Adding measurement 593bda0e to history. Total: 3
Rejected: LBFGS Orientation magnitude: 4.058e+04, gradient 1.225e-01, dot -0.117; [fd0d0272-16d3-4f25-8625-c3b4965fd525 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -548.5193081714274, -13.260034103385578, 55.27460680293882, 107.30377978338824
LBFGS Accumulation History: 3 points
Removed measurement 593bda0e to history. Total: 3
th(0)=-548.5193081714274;dx=-0.014976075107979641
Armijo: th(98437.50000000004)=-274.03100195511945; dx=0.0013376615627956772 evalInputDelta=-274.48830621630793
New Minimum: -548.5193081714274 > -574.8773411881683
END: th(49218.75000000002)=-574.8773411881683; dx=-0.0017292178473217424 evalInputDelta=26.358033016740933
Fitness changed from -548.5193081714274 to -574.8773411881683
Iteration 12 complete. Error: -574.8773411881683 Total: 3.5037; Orientation: 0.4559; Line Search: 2.3460
Adding measurement 23fbc6b2 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 6.379e+04, gradient 1.269e-01, dot -0.107; [fd0d0272-16d3-4f25-8625-c3b4965fd525 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -574.8773411881683, -13.260034103385578, 55.27460680293882, 107.30377978338824
LBFGS Accumulation History: 3 points
Removed measurement 23fbc6b2 to history. Total: 3
th(0)=-574.8773411881683;dx=-0.01606830254234915
Armijo: th(106038.58240000682)=-240.18451318824157; dx=0.001645903345085202 evalInputDelta=-334.69282799992675
New Minimum: -574.8773411881683 > -580.9158568275983
END: th(53019.29120000341)=-580.9158568275983; dx=-0.0012164991515836877 evalInputDelta=6.038515639429988
Fitness changed from -574.8773411881683 to -580.9158568275983
Iteration 13 complete. Error: -580.9158568275983 Total: 3.4015; Orientation: 0.3403; Line Search: 2.3933
Adding measurement 2b97a1fb to history. Total: 3
Rejected: LBFGS Orientation magnitude: 9.103e+04, gradient 1.285e-01, dot -0.096; [fd0d0272-16d3-4f25-8625-c3b4965fd525 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -580.9158568275983, -13.260034103385578, 55.27460680293882, 107.30377978338824
LBFGS Accumulation History: 3 points
Removed measurement 2b97a1fb to history. Total: 3
th(0)=-580.9158568275983;dx=-0.016498626823716278
Armijo: th(114226.60020218954)=-233.82990851295767; dx=0.0016916645329359925 evalInputDelta=-347.08594831464063
New Minimum: -580.9158568275983 > -596.006534866692
END: th(57113.30010109477)=-596.006534866692; dx=-0.001034131749234709 evalInputDelta=15.090678039093746
Fitness changed from -580.9158568275983 to -596.006534866692
Iteration 14 complete. Error: -596.006534866692 Total: 3.5174; Orientation: 0.2912; Line Search: 2.3582
Adding measurement 5f1a2706 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.169e+05, gradient 1.250e-01, dot -0.085; [fd0d0272-16d3-4f25-8625-c3b4965fd525 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -596.006534866692, -13.260034103385578, 55.27460680293882, 107.30377978338824
LBFGS Accumulation History: 3 points
Removed measurement 5f1a2706 to history. Total: 3
th(0)=-596.006534866692;dx=-0.01559948832054394
Armijo: th(123046.87500000007)=-220.66355655019936; dx=0.001944657978142127 evalInputDelta=-375.3429783164927
New Minimum: -596.006534866692 > -611.5992299707509
END: th(61523.43750000004)=-611.5992299707509; dx=-8.87640735463635E-4 evalInputDelta=15.592695104058862
Fitness changed from -596.006534866692 to -611.5992299707509
Iteration 15 complete. Error: -611.5992299707509 Total: 3.4309; Orientation: 0.3607; Line Search: 2.3909
<a id="p-15"></a>Iteration 15
<a id="p-14"></a>![Iteration 15](etc/bc5310d9-20d2-453f-b1f7-5c82394e0ca2.jpg)
Final threshold in iteration 16: -611.5992299707509 (> -Infinity) after 58.634s (< 5400.000s)

Returns

    -611.5992299707509