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 57.25 seconds (1.099 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: 211836964501200
Reset training subject: 211837828560300
Adding measurement 79cfc008 to history. Total: 0
LBFGS Accumulation History: 1 points
Constructing line search parameters: GD+Trust
th(0)=113.34157572232887;dx=-0.0011893498435129113
New Minimum: 113.34157572232887 > 113.33976232146061
WOLFE (weak): th(2.154434690031884)=113.33976232146061; dx=-0.001189994444190506 evalInputDelta=0.001813400868257986
New Minimum: 113.33976232146061 > 113.33795937558165
WOLFE (weak): th(4.308869380063768)=113.33795937558165; dx=-0.0011906991067811576 evalInputDelta=0.00361634674722211
New Minimum: 113.33795937558165 > 113.33066943307661
WOLFE (weak): th(12.926608140191302)=113.33066943307661; dx=-0.001195663779258455 evalInputDelta=0.010906289252261558
New Minimum: 113.33066943307661 > 113.29795035697687
WOLFE (weak): th(51.70643256076521)=113.29795035697687; dx=-0.0011921570187794091 evalInputDelta=0.04362536535199979
New Minimum: 113.29795035697687 > 113.11672079572426
WOLFE (weak): th(258.53216280382605)=113.11672079572426; dx=-0.0012507478276226724 evalInputDelta=0.22485492660460693
New Minimum: 113.11672079572426 > 111.90209566854973
WOLFE (weak): th(1551.1929768229563)=111.90209566854973; dx=-0.0012715439682748346 evalInputDelta=1.4394800537791355
New Minimum: 111.90209566854973 > 105.80924191305508
END: th(10858.350837760694)=105.80924191305508; dx=-5.808045204669884E-4 evalInputDelta=7.532333809273794
Fitness changed from 113.34157572232887 to 105.80924191305508
Iteration 1 complete. Error: 105.80924191305508 Total: 8.9307; Orientation: 0.0177; Line Search: 6.6213
<a id="p-3"></a>Iteration 1
<a id="p-2"></a>![Iteration 1](etc/0299e3a8-36d0-44ba-8be4-3078748869a2.jpg)
Adding measurement 7900d917 to history. Total: 1
LBFGS Accumulation History: 2 points
th(0)=105.80924191305508;dx=-0.0026880344094733994
New Minimum: 105.80924191305508 > 98.50814984919288
END: th(23393.607721408407)=98.50814984919288; dx=-3.7298270370707276E-4 evalInputDelta=7.3010920638622
Fitness changed from 105.80924191305508 to 98.50814984919288
Iteration 2 complete. Error: 98.50814984919288 Total: 2.5068; Orientation: 0.0206; Line Search: 1.6373
<a id="p-5"></a>Iteration 2
<a id="p-4"></a>![Iteration 2](etc/75dd406a-9ace-4fd0-9f34-05febd81b428.jpg)
Adding measurement 71586f to history. Total: 2
LBFGS Accumulation History: 3 points
th(0)=98.50814984919288;dx=-0.0024287673083440075
New Minimum: 98.50814984919288 > 93.13587676929625
END: th(50400.00000000001)=93.13587676929625; dx=-1.3474063239314328E-4 evalInputDelta=5.37227307989663
Fitness changed from 98.50814984919288 to 93.13587676929625
Iteration 3 complete. Error: 93.13587676929625 Total: 2.4883; Orientation: 0.0174; Line Search: 1.7573
<a id="p-7"></a>Iteration 3
<a id="p-6"></a>![Iteration 3](etc/d87921b6-d9aa-43b5-81ea-ae1d390ad899.jpg)
Adding measurement 156c1c4e to history. Total: 3
Rejected: LBFGS Orientation magnitude: 4.524e+03, gradient 5.320e-02, dot -0.145; [b3529c0b-a1f4-4c87-b060-32f97c9fe1ea = 1.000/1.000e+00]
Orientation rejected. Popping history element from 93.13587676929625, 98.50814984919288, 105.80924191305508, 113.34157572232887
LBFGS Accumulation History: 3 points
Removed measurement 156c1c4e to history. Total: 3
th(0)=93.13587676929625;dx=-0.002828091050963823
Armijo: th(108583.50837760697)=93.96536709243831; dx=6.805386123896371E-5 evalInputDelta=-0.8294903231420676
New Minimum: 93.13587676929625 > 80.91770549818496
END: th(54291.75418880348)=80.91770549818496; dx=-1.466134669743456E-4 evalInputDelta=12.218171271111288
Fitness changed from 93.13587676929625 to 80.91770549818496
Iteration 4 complete. Error: 80.91770549818496 Total: 3.5804; Orientation: 0.3184; Line Search: 2.5397
<a id="p-9"></a>Iteration 4
<a id="p-8"></a>![Iteration 4](etc/d3abaa1d-3ba0-4be0-a4ee-e0ca96279318.jpg)
Adding measurement 5fc4af25 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.554e+03, gradient 4.788e-02, dot -0.127; [b3529c0b-a1f4-4c87-b060-32f97c9fe1ea = 1.000/1.000e+00]
Orientation rejected. Popping history element from 80.91770549818496, 98.50814984919288, 105.80924191305508, 113.34157572232887
LBFGS Accumulation History: 3 points
Removed measurement 5fc4af25 to history. Total: 3
th(0)=80.91770549818496;dx=-0.00229169925043903
Armijo: th(116968.03860704206)=83.73524845614443; dx=-2.2247796719218315E-5 evalInputDelta=-2.817542957959475
New Minimum: 80.91770549818496 > 67.60060488621318
END: th(58484.01930352103)=67.60060488621318; dx=-2.1492911038938076E-4 evalInputDelta=13.317100611971782
Fitness changed from 80.91770549818496 to 67.60060488621318
Iteration 5 complete. Error: 67.60060488621318 Total: 4.0452; Orientation: 0.3246; Line Search: 2.9049
<a id="p-11"></a>Iteration 5
<a id="p-10"></a>![Iteration 5](etc/8a0b9968-4c2d-4c23-99b9-5dd299a0abbe.jpg)
Adding measurement 2d95c3ef to history. Total: 3
Rejected: LBFGS Orientation magnitude: 4.901e+03, gradient 4.865e-02, dot -0.139; [b3529c0b-a1f4-4c87-b060-32f97c9fe1ea = 1.000/1.000e+00]
Orientation rejected. Popping history element from 67.60060488621318, 98.50814984919288, 105.80924191305508, 113.34157572232887
LBFGS Accumulation History: 3 points
Removed measurement 2d95c3ef to history. Total: 3
th(0)=67.60060488621318;dx=-0.0023625385719111946
Armijo: th(126000.00000000004)=75.88361302952254; dx=5.4644233884889016E-5 evalInputDelta=-8.28300814330936
New Minimum: 67.60060488621318 > 45.11283035524797
END: th(63000.00000000002)=45.11283035524797; dx=-3.0554305586737423E-4 evalInputDelta=22.487774530965204
Fitness changed from 67.60060488621318 to 45.11283035524797
Iteration 6 complete. Error: 45.11283035524797 Total: 3.2941; Orientation: 0.3002; Line Search: 2.2742
Adding measurement 1a5d0d94 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 6.351e+03, gradient 5.118e-02, dot -0.137; [b3529c0b-a1f4-4c87-b060-32f97c9fe1ea = 1.000/1.000e+00]
Orientation rejected. Popping history element from 45.11283035524797, 98.50814984919288, 105.80924191305508, 113.34157572232887
LBFGS Accumulation History: 3 points
Removed measurement 1a5d0d94 to history. Total: 3
th(0)=45.11283035524797;dx=-0.0026135685917661787
Armijo: th(135729.38547200873)=73.32405546303883; dx=1.704998603142241E-4 evalInputDelta=-28.21122510779086
New Minimum: 45.11283035524797 > 27.444307853176525
END: th(67864.69273600436)=27.444307853176525; dx=-2.095079052839521E-4 evalInputDelta=17.668522502071447
Fitness changed from 45.11283035524797 to 27.444307853176525
Iteration 7 complete. Error: 27.444307853176525 Total: 3.4162; Orientation: 0.3119; Line Search: 2.3056
Adding measurement e68c09d to history. Total: 3
Rejected: LBFGS Orientation magnitude: 7.763e+03, gradient 5.522e-02, dot -0.128; [b3529c0b-a1f4-4c87-b060-32f97c9fe1ea = 1.000/1.000e+00]
Orientation rejected. Popping history element from 27.444307853176525, 98.50814984919288, 105.80924191305508, 113.34157572232887
LBFGS Accumulation History: 3 points
Removed measurement e68c09d to history. Total: 3
th(0)=27.444307853176525;dx=-0.003047475086711013
Armijo: th(146210.0482588026)=70.93766824081365; dx=1.630017168015465E-4 evalInputDelta=-43.493360387637125
New Minimum: 27.444307853176525 > 12.510126192427393
END: th(73105.0241294013)=12.510126192427393; dx=-2.535396940263348E-4 evalInputDelta=14.934181660749132
Fitness changed from 27.444307853176525 to 12.510126192427393
Iteration 8 complete. Error: 12.510126192427393 Total: 3.9227; Orientation: 0.2935; Line Search: 2.4185
Adding measurement 56584f06 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 9.180e+03, gradient 5.912e-02, dot -0.112; [b3529c0b-a1f4-4c87-b060-32f97c9fe1ea = 1.000/1.000e+00]
Orientation rejected. Popping history element from 12.510126192427393, 98.50814984919288, 105.80924191305508, 113.34157572232887
LBFGS Accumulation History: 3 points
Removed measurement 56584f06 to history. Total: 3
th(0)=12.510126192427393;dx=-0.0034879042003655254
Armijo: th(157500.00000000006)=81.43346309803178; dx=2.7176854417928706E-4 evalInputDelta=-68.92333690560439
New Minimum: 12.510126192427393 > 5.17468510662934
END: th(78750.00000000003)=5.17468510662934; dx=-1.494294970144409E-4 evalInputDelta=7.3354410857980525
Fitness changed from 12.510126192427393 to 5.17468510662934
Iteration 9 complete. Error: 5.17468510662934 Total: 3.3305; Orientation: 0.3242; Line Search: 2.3252
Adding measurement 3f008bb6 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.090e+04, gradient 5.844e-02, dot -0.105; [b3529c0b-a1f4-4c87-b060-32f97c9fe1ea = 1.000/1.000e+00]
Orientation rejected. Popping history element from 5.17468510662934, 98.50814984919288, 105.80924191305508, 113.34157572232887
LBFGS Accumulation History: 3 points
Removed measurement 3f008bb6 to history. Total: 3
th(0)=5.17468510662934;dx=-0.003411405212418686
Armijo: th(169661.7318400109)=71.12310673850024; dx=2.7558137929377825E-4 evalInputDelta=-65.9484216318709
New Minimum: 5.17468510662934 > -13.63899171664562
END: th(84830.86592000545)=-13.63899171664562; dx=-2.8662049977533425E-4 evalInputDelta=18.81367682327496
Fitness changed from 5.17468510662934 to -13.63899171664562
Iteration 10 complete. Error: -13.63899171664562 Total: 3.5856; Orientation: 0.2943; Line Search: 2.3062
<a id="p-13"></a>Iteration 10
<a id="p-12"></a>![Iteration 10](etc/2a2fb37c-098e-437e-9328-9ecaaff6ed97.jpg)
Adding measurement 2f541378 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.609e+04, gradient 6.283e-02, dot -0.097; [b3529c0b-a1f4-4c87-b060-32f97c9fe1ea = 1.000/1.000e+00]
Orientation rejected. Popping history element from -13.63899171664562, 98.50814984919288, 105.80924191305508, 113.34157572232887
LBFGS Accumulation History: 3 points
Removed measurement 2f541378 to history. Total: 3
th(0)=-13.63899171664562;dx=-0.003943049908640621
Armijo: th(182762.56032350325)=80.85301103852055; dx=3.1782558448511806E-4 evalInputDelta=-94.49200275516617
New Minimum: -13.63899171664562 > -16.911516589053065
END: th(91381.28016175162)=-16.911516589053065; dx=-1.1680665792734473E-4 evalInputDelta=3.2725248724074447
Fitness changed from -13.63899171664562 to -16.911516589053065
Iteration 11 complete. Error: -16.911516589053065 Total: 3.2495; Orientation: 0.3175; Line Search: 2.2147
Adding measurement 4bea0314 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.252e+04, gradient 6.508e-02, dot -0.093; [b3529c0b-a1f4-4c87-b060-32f97c9fe1ea = 1.000/1.000e+00]
Orientation rejected. Popping history element from -16.911516589053065, 98.50814984919288, 105.80924191305508, 113.34157572232887
LBFGS Accumulation History: 3 points
Removed measurement 4bea0314 to history. Total: 3
th(0)=-16.911516589053065;dx=-0.004227568092327296
Armijo: th(196875.0000000001)=86.26859221186783; dx=3.9405966285562834E-4 evalInputDelta=-103.18010880092089
New Minimum: -16.911516589053065 > -27.149559944053124
END: th(98437.50000000004)=-27.149559944053124; dx=-6.169100995487452E-5 evalInputDelta=10.238043355000059
Fitness changed from -16.911516589053065 to -27.149559944053124
Iteration 12 complete. Error: -27.149559944053124 Total: 3.6258; Orientation: 0.5524; Line Search: 2.4076
Adding measurement 1f406a62 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.892e+04, gradient 6.473e-02, dot -0.083; [b3529c0b-a1f4-4c87-b060-32f97c9fe1ea = 1.000/1.000e+00]
Orientation rejected. Popping history element from -27.149559944053124, 98.50814984919288, 105.80924191305508, 113.34157572232887
LBFGS Accumulation History: 3 points
Removed measurement 1f406a62 to history. Total: 3
th(0)=-27.149559944053124;dx=-0.0041831966905585966
Armijo: th(212077.16480001365)=90.96551635345257; dx=4.600952359461556E-4 evalInputDelta=-118.1150762975057
New Minimum: -27.149559944053124 > -35.47845576302771
END: th(106038.58240000682)=-35.47845576302771; dx=-4.516003377464797E-5 evalInputDelta=8.328895818974587
Fitness changed from -27.149559944053124 to -35.47845576302771
Iteration 13 complete. Error: -35.47845576302771 Total: 3.4041; Orientation: 0.3110; Line Search: 2.4045
Adding measurement 6ed3fecb to history. Total: 3
Rejected: LBFGS Orientation magnitude: 4.164e+04, gradient 6.459e-02, dot -0.078; [b3529c0b-a1f4-4c87-b060-32f97c9fe1ea = 1.000/1.000e+00]
Orientation rejected. Popping history element from -35.47845576302771, 98.50814984919288, 105.80924191305508, 113.34157572232887
LBFGS Accumulation History: 3 points
Removed measurement 6ed3fecb to history. Total: 3
th(0)=-35.47845576302771;dx=-0.004159675785401088
Armijo: th(228453.20040437908)=97.66791569026185; dx=4.6603708217436495E-4 evalInputDelta=-133.14637145328956
New Minimum: -35.47845576302771 > -46.25877792254184
END: th(114226.60020218954)=-46.25877792254184; dx=-9.026537038485722E-7 evalInputDelta=10.780322159514128
Fitness changed from -35.47845576302771 to -46.25877792254184
Iteration 14 complete. Error: -46.25877792254184 Total: 3.7337; Orientation: 0.3133; Line Search: 2.7303
Adding measurement 75564919 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 5.500e+04, gradient 6.543e-02, dot -0.075; [b3529c0b-a1f4-4c87-b060-32f97c9fe1ea = 1.000/1.000e+00]
Orientation rejected. Popping history element from -46.25877792254184, 98.50814984919288, 105.80924191305508, 113.34157572232887
LBFGS Accumulation History: 3 points
Removed measurement 75564919 to history. Total: 3
th(0)=-46.25877792254184;dx=-0.004277006993336937
Armijo: th(246093.75000000015)=113.83672919508021; dx=4.820192663373205E-4 evalInputDelta=-160.09550711762205
New Minimum: -46.25877792254184 > -48.40919732408926
WOLF (strong): th(123046.87500000007)=-48.40919732408926; dx=6.92340218556667E-5 evalInputDelta=2.150419401547424
New Minimum: -48.40919732408926 > -104.72565438383049
END: th(41015.62500000002)=-104.72565438383049; dx=-0.001948844670303461 evalInputDelta=58.46687646128865
Fitness changed from -46.25877792254184 to -104.72565438383049
Iteration 15 complete. Error: -104.72565438383049 Total: 4.1130; Orientation: 0.3056; Line Search: 3.1354
<a id="p-15"></a>Iteration 15
<a id="p-14"></a>![Iteration 15](etc/15fc7d0d-fc21-4e5b-96bf-063edefc62b4.jpg)
Final threshold in iteration 16: -104.72565438383049 (> -Infinity) after 57.249s (< 5400.000s)

Returns

    -104.72565438383049