Code from BasicOptimizer.scala:75 executed in 382.99 seconds (4.964 gc):
val lineSearchInstance: LineSearchStrategy = lineSearchFactory
IterativeTrainer.wrap(trainable)
.setOrientation(orientation())
.setMonitor(new TrainingMonitor() {
override def clear(): Unit = trainingMonitor.clear()
override def log(msg: String): Unit = trainingMonitor.log(msg)
override def onStepFail(currentPoint: Step): Boolean = {
BasicOptimizer.this.onStepFail(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, currentPoint)
trainingMonitor.onStepComplete(currentPoint)
super.onStepComplete(currentPoint)
}
})
.setTimeout(trainingMinutes, TimeUnit.MINUTES)
.setMaxIterations(trainingIterations)
.setLineSearchFactory((_: CharSequence) => lineSearchInstance)
.setTerminateThreshold(java.lang.Double.NEGATIVE_INFINITY)
.runAndFree
.asInstanceOf[lang.Double]
Reset training subject: 740159984752800
Reset training subject: 740164853956300
Adding measurement 3b332962 to history. Total: 0
LBFGS Accumulation History: 1 points
Constructing line search parameters: GD+Trust
th(0)=10.145475130962398;dx=-3.1222305999743516E-5
New Minimum: 10.145475130962398 > 10.145408234105524
WOLFE (weak): th(2.154434690031884)=10.145408234105524; dx=-3.122188853265012E-5 evalInputDelta=6.689685687355507E-5
New Minimum: 10.145408234105524 > 10.145340845510333
WOLFE (weak): th(4.308869380063768)=10.145340845510333; dx=-3.1221116854050265E-5 evalInputDelta=1.3428545206473075E-4
New Minimum: 10.145340845510333 > 10.145071725688549
WOLFE (weak): th(12.926608140191302)=10.145071725688549; dx=-3.122019927334856E-5 evalInputDelta=4.034052738486338E-4
New Minimum: 10.145071725688549 > 10.143861192611004
WOLFE (weak): th(51.70643256076521)=10.143861192611004; dx=-3.120810373970151E-5 evalInputDelta=0.0016139383513937844
New Minimum: 10.143861192611004 > 10.137410809861382
WOLFE (weak): th(258.53216280382605)=10.137410809861382; dx=-3.11589901655917E-5 evalInputDelta=0.008064321101015182
New Minimum: 10.137410809861382 > 10.097301046889063
WOLFE (weak): th(1551.1929768229563)=10.097301046889063; dx=-3.089126021261793E-5 evalInputDelta=0.048174084073334456
New Minimum: 10.097301046889063 > 9.819631846921977
WOLFE (weak): th(10858.350837760694)=9.819631846921977; dx=-2.876210441969789E-5 evalInputDelta=0.3258432840404204
New Minimum: 9.819631846921977 > 8.158208287437112
END: th(86866.80670208555)=8.158208287437112; dx=-1.621808407771194E-5 evalInputDelta=1.9872668435252852
Fitness changed from 10.145475130962398 to 8.158208287437112
Iteration 1 complete. Error: 8.158208287437112 Total: 54.6864; Orientation: 0.0187; Line Search: 40.4460
<a id="p-3"></a>Iteration 1
<a id="p-2"></a>![Iteration 1](etc/a958374c-25ed-4600-afe2-78ebd6635700.jpg)
Adding measurement 4087c7fc to history. Total: 1
LBFGS Accumulation History: 2 points
th(0)=8.158208287437112;dx=-1.1304505724860625E-5
N
...skipping 15312 bytes...
feb4-98cc-4e92-8d88-e9978177e0c1 = 1.000/1.000e+00]
Orientation rejected. Popping history element from 0.25325373475305546, 0.19037024631079769, 0.13295969488855253, 0.07977362586973724
LBFGS Accumulation History: 3 points
Removed measurement 3249e278 to history. Total: 4
th(0)=0.07977362586973724;dx=-8.801778990133864E-8
Armijo: th(3141883.9229631666)=0.09513579569021857; dx=4.055184943907857E-8 evalInputDelta=-0.01536216982048133
New Minimum: 0.07977362586973724 > 0.03724655645524977
WOLF (strong): th(1570941.9614815833)=0.03724655645524977; dx=2.208771739986714E-8 evalInputDelta=0.04252706941448747
END: th(523647.3204938611)=0.045647585203221874; dx=-4.4441172975758334E-8 evalInputDelta=0.03412604066651537
Fitness changed from 0.07977362586973724 to 0.03724655645524977
Iteration 19 complete. Error: 0.03724655645524977 Total: 23.2371; Orientation: 0.3445; Line Search: 17.5703
Adding measurement 5934ca1e to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.408e+03, gradient 3.660e-04, dot -0.569; [ba07feb4-98cc-4e92-8d88-e9978177e0c1 = 1.000/1.000e+00]
Orientation rejected. Popping history element from 0.19037024631079769, 0.13295969488855253, 0.07977362586973724, 0.03724655645524977
LBFGS Accumulation History: 3 points
Removed measurement 11787b64 to history. Total: 4
th(0)=0.03724655645524977;dx=-1.339560159546135E-7
New Minimum: 0.03724655645524977 > -0.019834535500579342
WOLF (strong): th(1128163.9526142182)=-0.019834535500579342; dx=1.8526107650448724E-8 evalInputDelta=0.05708109195582911
END: th(564081.9763071091)=-0.012787164932568151; dx=-4.6969926099599493E-8 evalInputDelta=0.05003372138781792
Fitness changed from 0.03724655645524977 to -0.019834535500579342
Iteration 20 complete. Error: -0.019834535500579342 Total: 17.7979; Orientation: 0.2358; Line Search: 13.2743
<a id="p-17"></a>Iteration 20
<a id="p-16"></a>![Iteration 20](etc/6836951f-19b6-4845-be10-94b7cde3d5e1.jpg)
Final threshold in iteration 21: -0.019834535500579342 (> -Infinity) after 382.979s (< 3600.000s)
-0.019834535500579342