Iteration 1 Iteration 1

Iteration 2 Iteration 2

Iteration 3 Iteration 3

Iteration 4 Iteration 4

Iteration 5 Iteration 5

BasicOptimizer.scala:89 executed in 65.88 seconds (1.100 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: 3265881444846
Reset training subject: 3266376122199
Adding measurement 37f0464a to history. Total: 0
LBFGS Accumulation History: 1 points
Constructing line search parameters: GD+Trust
th(0)=-2.9312357562599525;dx=-9.66153516284686E-4
New Minimum: -2.9312357562599525 > -2.9312808167356637
WOLFE (weak): th(2.154434690031884)=-2.9312808167356637; dx=-9.665101814196472E-4 evalInputDelta=4.506047571117833E-5
New Minimum: -2.9312808167356637 > -2.9313372633578507
WOLFE (weak): th(4.308869380063768)=-2.9313372633578507; dx=-9.667691936466281E-4 evalInputDelta=1.0150709789824575E-4
New Minimum: -2.9313372633578507 > -2.9315357125943917
WOLFE (weak): th(12.926608140191302)=-2.9315357125943917; dx=-9.663416316151817E-4 evalInputDelta=2.999563344392442E-4
New Minimum: -2.9315357125943917 > -2.932477187436244
WOLFE (weak): th(51.70643256076521)=-2.932477187436244; dx=-9.625036494504552E-4 evalInputDelta=0.0012414311762913854
New Minimum: -2.932477187436244 > -2.937602426894023
WOLFE (weak): th(258.53216280382605)=-2.937602426894023; dx=-9.560146605817074E-4 evalInputDelta=0.0063666706340703705
New Minimum: -2.937602426894023 > -2.964106411525682
WOLFE (weak): th(1551.1929768229563)=-2.964106411525682; dx=-9.182813631754192E-4 evalInputDelta=0.03287065526572963
New Minimum: -2.964106411525682 > -3.242375894611167
END: th(10858.350837760694)=-3.242375894611167; dx=-6.660911378246011E-4 evalInputDelta=0.31114013835121446
Fitness changed from -2.9312357562599525 to -3.242375894611167
Iteration 1 complete. Error: -3.242375894611167 Total: 5.5961; Orientation: 0.0161; Line Search: 4.1759
<a id="p-3"></a>Iteration 1
<a id="p-2"></a>![Iteration 1](etc/c42b708a-8301-4570-b60a-b9b02292490e.jpg)
Adding measurement 31a04636 to history. Total: 1
LBFGS Accumulation History: 2 points
th(0)=-3.242375894611167;dx=-9.41262844758454E-4
New Minimum: -3.242375894611167 > -3.655656554486533
END: th(23393.607721408407)=-3.655656554486533; dx=-4.623496095863462E-4 evalInputDelta=0.4132806598753662
Fitness changed from -3.242375894611167 to -3.655656554486533
Iteration 2 complete. Error: -3.655656554486533 Total: 1.5729; Orientation: 0.0160; Line Search: 1.0250
<a id="p-5"></a>Iteration 2
<a id="p-4"></a>![Iteration 2](etc/e27ad299-db90-4993-903c-b2857274b8ab.jpg)
Adding measurement 2981d1de to history. Total: 2
LBFGS Accumulation History: 3 points
th(0)=-3.655656554486533;dx=-9.655043211642565E-4
New Minimum: -3.655656554486533 > -4.045756888854165
END: th(50400.00000000001)=-4.045756888854165; dx=-2.459967588758949E-4 evalInputDelta=0.39010033436763214
Fitness changed from -3.655656554486533 to -4.045756888854165
Iteration 3 complete. Error: -4.045756888854165 Total: 1.5239; Orientation: 0.0157; Line Search: 1.0265
<a id="p-7"></a>Iteration 3
<a id="p-6"></a>![Iteration 3](etc/23a80dd3-3706-4d4f-b006-6f6dcbb0030c.jpg)
Adding measurement 35a96915 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 5.923e+03, gradient 3.109e-02, dot -0.270; [a3210a06-b49f-48f6-939f-aa3bc15b4d08 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -4.045756888854165, -3.655656554486533, -3.242375894611167, -2.9312357562599525
LBFGS Accumulation History: 3 points
Removed measurement 35a96915 to history. Total: 3
th(0)=-4.045756888854165;dx=-9.650623784891668E-4
New Minimum: -4.045756888854165 > -5.783748932049556
END: th(108583.50837760697)=-5.783748932049556; dx=-8.976072928546379E-5 evalInputDelta=1.7379920431953906
Fitness changed from -4.045756888854165 to -5.783748932049556
Iteration 4 complete. Error: -5.783748932049556 Total: 1.9478; Orientation: 0.4240; Line Search: 1.0377
<a id="p-9"></a>Iteration 4
<a id="p-8"></a>![Iteration 4](etc/2f35c54f-7e6b-4985-a2a2-09fccc32e841.jpg)
Adding measurement 3392dd57 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.229e+03, gradient 3.360e-02, dot -0.150; [a3210a06-b49f-48f6-939f-aa3bc15b4d08 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -5.783748932049556, -3.655656554486533, -3.242375894611167, -2.9312357562599525
LBFGS Accumulation History: 3 points
Removed measurement 3392dd57 to history. Total: 3
th(0)=-5.783748932049556;dx=-0.0011278909913830367
New Minimum: -5.783748932049556 > -7.2750406270678845
END: th(233936.07721408413)=-7.2750406270678845; dx=-2.4277025376783755E-5 evalInputDelta=1.4912916950183286
Fitness changed from -5.783748932049556 to -7.2750406270678845
Iteration 5 complete. Error: -7.2750406270678845 Total: 1.9453; Orientation: 0.4213; Line Search: 1.0256
<a id="p-11"></a>Iteration 5
<a id="p-10"></a>![Iteration 5](etc/b8578cc6-a8fe-4bb7-943e-13bc8c6efba0.jpg)
Adding measurement 51645465 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.268e+03, gradient 2.774e-02, dot -0.114; [a3210a06-b49f-48f6-939f-aa3bc15b4d08 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -7.2750406270678845, -3.655656554486533, -3.242375894611167, -2.9312357562599525
LBFGS Accumulation History: 3 points
Removed measurement 51645465 to history. Total: 3
th(0)=-7.2750406270678845;dx=-7.655490344293579E-4
New Minimum: -7.2750406270678845 > -11.02577484245279
END: th(504000.0000000002)=-11.02577484245279; dx=-1.0505150382492254E-5 evalInputDelta=3.750734215384906
Fitness changed from -7.2750406270678845 to -11.02577484245279
Iteration 6 complete. Error: -11.02577484245279 Total: 1.9623; Orientation: 0.4160; Line Search: 1.0455
Adding measurement 7104d585 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.276e+03, gradient 2.844e-02, dot -0.089; [a3210a06-b49f-48f6-939f-aa3bc15b4d08 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -11.02577484245279, -3.655656554486533, -3.242375894611167, -2.9312357562599525
LBFGS Accumulation History: 3 points
Removed measurement 7104d585 to history. Total: 3
th(0)=-11.02577484245279;dx=-8.075273599014257E-4
Armijo: th(1085835.0837760698)=-10.127781238742482; dx=-5.338125594195339E-6 evalInputDelta=-0.897993603710308
Armijo: th(542917.5418880349)=-10.39772798222683; dx=-1.9283176999061476E-5 evalInputDelta=-0.628046860225961
Armijo: th(180972.5139626783)=-9.669469185967703; dx=-7.308975337123432E-5 evalInputDelta=-1.3563056564850875
New Minimum: -11.02577484245279 > -12.053981797433227
END: th(45243.12849066957)=-12.053981797433227; dx=-3.304812275602535E-4 evalInputDelta=1.028206954980437
Fitness changed from -11.02577484245279 to -12.053981797433227
Iteration 7 complete. Error: -12.053981797433227 Total: 3.4582; Orientation: 0.4174; Line Search: 2.5751
Adding measurement 69d8ba0b to history. Total: 3
Rejected: LBFGS Orientation magnitude: 6.938e+03, gradient 3.087e-02, dot -0.073; [a3210a06-b49f-48f6-939f-aa3bc15b4d08 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -12.053981797433227, -3.655656554486533, -3.242375894611167, -2.9312357562599525
LBFGS Accumulation History: 3 points
Removed measurement 69d8ba0b to history. Total: 3
th(0)=-12.053981797433227;dx=-9.51673081866082E-4
Armijo: th(97473.3655058684)=-10.209036874207369; dx=-1.2948996773401707E-4 evalInputDelta=-1.8449449232258583
Armijo: th(48736.6827529342)=-10.944452659057356; dx=-2.597127586814154E-4 evalInputDelta=-1.109529138375871
New Minimum: -12.053981797433227 > -12.380917762176965
END: th(16245.560917644732)=-12.380917762176965; dx=-5.59500078562449E-4 evalInputDelta=0.326935964743738
Fitness changed from -12.053981797433227 to -12.380917762176965
Iteration 8 complete. Error: -12.380917762176965 Total: 3.5442; Orientation: 0.4178; Line Search: 2.6827
Adding measurement 34c9b3f8 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 8.316e+03, gradient 2.922e-02, dot -0.078; [a3210a06-b49f-48f6-939f-aa3bc15b4d08 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -12.380917762176965, -3.655656554486533, -3.242375894611167, -2.9312357562599525
LBFGS Accumulation History: 3 points
Removed measurement 34c9b3f8 to history. Total: 3
th(0)=-12.380917762176965;dx=-8.525688594755467E-4
Armijo: th(35000.000000000015)=-11.977556857979545; dx=-3.6555226467960934E-4 evalInputDelta=-0.4033609041974202
Armijo: th(17500.000000000007)=-12.25561270294592; dx=-5.262068025870511E

...skipping 1470 bytes...

334210040643E-6
WOLFE (weak): th(3075.459798177085)=-12.380922075730567; dx=-7.764355763741304E-4 evalInputDelta=4.3135536014204945E-6
Armijo: th(3076.52791341146)=-12.380910983732553; dx=-7.774299226886796E-4 evalInputDelta=-6.778444411992268E-6
Armijo: th(3075.9938557942723)=-12.38091468106633; dx=-7.770143777704002E-4 evalInputDelta=-3.0811106359607265E-6
Armijo: th(3075.7268269856786)=-12.38091406484411; dx=-7.695593375184021E-4 evalInputDelta=-3.697332855878699E-6
WOLFE (weak): th(3075.5933125813817)=-12.380922691952389; dx=-7.765173409237888E-4 evalInputDelta=4.929775423434535E-6
Armijo: th(3075.66006978353)=-12.380918994621005; dx=-7.767291470666985E-4 evalInputDelta=1.2324440401556558E-6
WOLFE (weak): th(3075.626691182456)=-12.380921459508716; dx=-7.7650565034967E-4 evalInputDelta=3.6973317509847448E-6
Armijo: th(3075.643380482993)=-12.380920227064921; dx=-7.769303796309353E-4 evalInputDelta=2.464887955966333E-6
mu ~= nu (3075.626691182456): th(1458.333333333334)=-12.385210853109307
Fitness changed from -12.380917762176965 to -12.385210853109307
Iteration 9 complete. Error: -12.385210853109307 Total: 13.2936; Orientation: 0.4253; Line Search: 12.4113
Adding measurement 5e20befe to history. Total: 3
Rejected: LBFGS Orientation magnitude: 8.552e+03, gradient 2.864e-02, dot -0.079; [a3210a06-b49f-48f6-939f-aa3bc15b4d08 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -12.385210853109307, -3.655656554486533, -3.242375894611167, -2.9312357562599525
LBFGS Accumulation History: 3 points
Removed measurement 5e20befe to history. Total: 3
th(0)=-12.385210853109307;dx=-8.189689870574922E-4
Armijo: th(6626.254815075477)=-12.32524138982206; dx=-7.03125695862007E-4 evalInputDelta=-0.05996946328724739
Armijo: th(3313.1274075377387)=-12.365789511557304; dx=-7.628139944245024E-4 evalInputDelta=-0.019421341552002147
Armijo: th(1104.3758025125796)=-12.38071440723024; dx=-7.796265146643622E-4 evalInputDelta=-0.004496445879066613
Armijo: th(276.0939506281449)=-12.384281261473403; dx=-8.022132204467366E-4 evalInputDelta=-9.295916359040035E-4
Armijo: th(55.218790125628985)=-12.384939806425749; dx=-8.014508411837138E-4 evalInputDelta=-2.710466835580405E-4
Armijo: th(9.20313168760483)=-12.385172660526566; dx=-8.045714753342442E-4 evalInputDelta=-3.8192582740848025E-5
Armijo: th(1.3147330982292615)=-12.385204077014512; dx=-7.968705186714881E-4 evalInputDelta=-6.776094794602727E-6
Armijo: th(0.1643416372786577)=-12.385210237100843; dx=-8.053968068736564E-4 evalInputDelta=-6.160084637940599E-7
Armijo: th(0.018260181919850856)=-12.385209005083821; dx=-8.056384593091773E-4 evalInputDelta=-1.8480254855290923E-6
Armijo: th(0.0018260181919850856)=-12.385209005083821; dx=-8.054421499870134E-4 evalInputDelta=-1.8480254855290923E-6
Armijo: th(1.6600165381682597E-4)=-12.385210853109307; dx=-8.05640577508842E-4 evalInputDelta=0.0
Armijo: th(1.3833471151402163E-5)=-12.385209005083821; dx=-8.057859658766081E-4 evalInputDelta=-1.8480254855290923E-6
Armijo: th(1.0641131654924742E-6)=-12.385209005083821; dx=-8.051438636137761E-4 evalInputDelta=-1.8480254855290923E-6
WOLFE (weak): th(7.600808324946244E-8)=-12.385210853109307; dx=-8.05566542565666E-4 evalInputDelta=0.0
WOLFE (weak): th(5.700606243709683E-7)=-12.385210853109307; dx=-8.056072312610759E-4 evalInputDelta=0.0
Armijo: th(8.170868949317213E-7)=-12.385209005083821; dx=-8.055398691246079E-4 evalInputDelta=-1.8480254855290923E-6
WOLFE (weak): th(6.935737596513448E-7)=-12.385210853109307; dx=-8.052900105297606E-4 evalInputDelta=0.0
WOLFE (weak): th(7.553303272915331E-7)=-12.385210853109307; dx=-8.052597460306379E-4 evalInputDelta=0.0
Armijo: th(7.862086111116272E-7)=-12.385209005083821; dx=-8.060085376140451E-4 evalInputDelta=-1.8480254855290923E-6
WOLFE (weak): th(7.707694692015801E-7)=-12.385210853109307; dx=-8.058312423030214E-4 evalInputDelta=0.0
Armijo: th(7.784890401566036E-7)=-12.385209005083821; dx=-8.056843617170236E-4 evalInputDelta=-1.8480254855290923E-6
Armijo: th(7.746292546790918E-7)=-12.385209005083821; dx=-8.053937479329058E-4 evalInputDelta=-1.8480254855290923E-6
Armijo: th(7.726993619403359E-7)=-12.385209005083821; dx=-8.057153942366737E-4 evalInputDelta=-1.8480254855290923E-6
WOLFE (weak): th(7.71734415570958E-7)=-12.385210853109307; dx=-8.053745688430573E-4 evalInputDelta=0.0
WOLFE (weak): th(7.722168887556469E-7)=-12.385210853109307; dx=-8.056631444003466E-4 evalInputDelta=0.0
Armijo: th(7.724581253479915E-7)=-12.385209005083821; dx=-8.060652410057756E-4 evalInputDelta=-1.8480254855290923E-6
WOLFE (weak): th(7.723375070518191E-7)=-12.385210853109307; dx=-8.05582716715703E-4 evalInputDelta=0.0
WOLFE (weak): th(7.723978161999053E-7)=-12.385210853109307; dx=-8.052678610534135E-4 evalInputDelta=0.0
Armijo: th(7.724279707739484E-7)=-12.385209005083821; dx=-8.054799113141302E-4 evalInputDelta=-1.8480254855290923E-6
Armijo: th(7.724128934869269E-7)=-12.385209005083821; dx=-8.053350155918244E-4 evalInputDelta=-1.8480254855290923E-6
WOLFE (weak): th(7.724053548434161E-7)=-12.385210853109307; dx=-8.051568947818122E-4 evalInputDelta=0.0
mu ~= nu (7.724053548434161E-7): th(0.0)=-12.385210853109307
Fitness changed from -12.385210853109307 to -12.385210853109307
Static Iteration Total: 18.6945; Orientation: 0.4163; Line Search: 17.8155
Iteration 10 failed. Error: -12.385210853109307
Previous Error: 0.0 -> -12.385210853109307
Retrying iteration 10
Reset training subject: 3319420431586
Adding measurement 7ab98e85 to history. Total: 0
LBFGS Accumulation History: 1 points
th(0)=-12.385210853109307;dx=-8.185882951806343E-4
Armijo: th(1.6641050119985902E-6)=-12.385209621092347; dx=-8.056935216162978E-4 evalInputDelta=-1.232016959562543E-6
Armijo: th(8.320525059992951E-7)=-12.385209005083821; dx=-8.059318031441534E-4 evalInputDelta=-1.8480254855290923E-6
WOLFE (weak): th(2.7735083533309834E-7)=-12.385210853109307; dx=-8.049819221024003E-4 evalInputDelta=0.0
WOLFE (weak): th(5.547016706661967E-7)=-12.385210853109307; dx=-8.049827803987554E-4 evalInputDelta=0.0
WOLFE (weak): th(6.933770883327459E-7)=-12.385210853109307; dx=-8.057497082951486E-4 evalInputDelta=0.0
WOLFE (weak): th(7.627147971660205E-7)=-12.385210853109307; dx=-8.058082817852044E-4 evalInputDelta=0.0
Armijo: th(7.973836515826577E-7)=-12.385209005083821; dx=-8.056982930055711E-4 evalInputDelta=-1.8480254855290923E-6
Armijo: th(7.800492243743391E-7)=-12.385209005083821; dx=-8.0574267814239E-4 evalInputDelta=-1.8480254855290923E-6
WOLFE (weak): th(7.713820107701798E-7)=-12.385210853109307; dx=-8.059733286477409E-4 evalInputDelta=0.0
Armijo: th(7.757156175722595E-7)=-12.385209005083821; dx=-8.057779342190135E-4 evalInputDelta=-1.8480254855290923E-6
Armijo: th(7.735488141712197E-7)=-12.385209005083821; dx=-8.053536683623286E-4 evalInputDelta=-1.8480254855290923E-6
Armijo: th(7.724654124706997E-7)=-12.385209005083821; dx=-8.055443894202882E-4 evalInputDelta=-1.8480254855290923E-6
WOLFE (weak): th(7.719237116204398E-7)=-12.385210853109307; dx=-8.058544097006601E-4 evalInputDelta=0.0
WOLFE (weak): th(7.721945620455697E-7)=-12.385210853109307; dx=-8.056681679743952E-4 evalInputDelta=0.0
WOLFE (weak): th(7.723299872581347E-7)=-12.385210853109307; dx=-8.059235878072894E-4 evalInputDelta=0.0
WOLFE (weak): th(7.723976998644173E-7)=-12.385210853109307; dx=-8.058314813166661E-4 evalInputDelta=0.0
Armijo: th(7.724315561675585E-7)=-12.385209005083821; dx=-8.057785670879914E-4 evalInputDelta=-1.8480254855290923E-6
Armijo: th(7.724146280159879E-7)=-12.385209005083821; dx=-8.058142577476918E-4 evalInputDelta=-1.8480254855290923E-6
Armijo: th(7.724061639402026E-7)=-12.385209005083821; dx=-8.055445139063188E-4 evalInputDelta=-1.8480254855290923E-6
WOLFE (weak): th(7.724019319023099E-7)=-12.385210853109307; dx=-8.059628001170728E-4 evalInputDelta=0.0
mu ~= nu (7.724019319023099E-7): th(0.0)=-12.385210853109307
Fitness changed from -12.385210853109307 to -12.385210853109307
Static Iteration Total: 12.3445; Orientation: 0.0168; Line Search: 11.4059
Iteration 11 failed. Error: -12.385210853109307
Previous Error: 0.0 -> -12.385210853109307
Optimization terminated 11
Final threshold in iteration 11: -12.385210853109307 (> -Infinity) after 65.883s (< 3600.000s)

Returns

    -12.385210853109307