Code from BasicOptimizer.scala:75 executed in 104.01 seconds (3.007 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: 901323309300100
Reset training subject: 901324249149000
Adding measurement 1716da4 to history. Total: 0
LBFGS Accumulation History: 1 points
Constructing line search parameters: GD+Trust
th(0)=3.98501112498343;dx=-1.0586877063074965E-4
New Minimum: 3.98501112498343 > 3.984811471775174
WOLFE (weak): th(2.154434690031884)=3.984811471775174; dx=-1.0596809492112143E-4 evalInputDelta=1.9965320825576782E-4
New Minimum: 3.984811471775174 > 3.9846118222922087
WOLFE (weak): th(4.308869380063768)=3.9846118222922087; dx=-1.0603332955587267E-4 evalInputDelta=3.993026912212372E-4
New Minimum: 3.9846118222922087 > 3.983811780810356
WOLFE (weak): th(12.926608140191302)=3.983811780810356; dx=-1.062008326441179E-4 evalInputDelta=0.0011993441730737686
New Minimum: 3.983811780810356 > 3.980187486857176
WOLFE (weak): th(51.70643256076521)=3.980187486857176; dx=-1.0718552727489256E-4 evalInputDelta=0.004823638126254082
New Minimum: 3.980187486857176 > 3.9590208753943443
WOLFE (weak): th(258.53216280382605)=3.9590208753943443; dx=-1.624860757348147E-4 evalInputDelta=0.02599024958908558
New Minimum: 3.9590208753943443 > 3.8507666047662497
END: th(1551.1929768229563)=3.8507666047662497; dx=-8.507532136665548E-5 evalInputDelta=0.13424452021718025
Fitness changed from 3.98501112498343 to 3.8507666047662497
Iteration 1 complete. Error: 3.8507666047662497 Total: 8.8023; Orientation: 0.0143; Line Search: 6.2996
<a id="p-3"></a>Iteration 1
<a id="p-2"></a>![Iteration 1](etc/70dd781d-4042-4702-94c3-72aae285b5ee.jpg)
Adding measurement 6b3decaa to history. Total: 1
LBFGS Accumulation History: 2 points
th(0)=3.8507666047662497;dx=-7.663612247735878E-5
New Minimum: 3.8507666047662497 > 3.6524049136787653
WOLFE (weak): th(3341.943960201201)=3.6524049136787653; dx=-1.0843193580432946E-4 evalInputDelta=0.19836169108748436
New Minimum: 3.6524049136787653 > 3.5259263142943382
END: th(6683.887920402402)=3.5259263142943382; dx=-3.65457148575447E-5 evalInputDelta=0.32484029047191143
Fitness changed fro
...skipping 19495 bytes...
29907 to 0.6734024584293365
Iteration 23 complete. Error: 0.6734024584293365 Total: 5.0481; Orientation: 0.4349; Line Search: 3.6214
Adding measurement 2f6acdcc to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.235e+02, gradient 7.422e-04, dot -0.619; [49e1432b-974c-4ffb-9a30-0a3a1adf4640 = 1.000/1.000e+00]
Orientation rejected. Popping history element from 0.770133838057518, 0.7367033958435059, 0.7051044702529907, 0.6734024584293365
LBFGS Accumulation History: 3 points
Removed measurement 69a245d6 to history. Total: 4
th(0)=0.6734024584293365;dx=-5.508906865134486E-7
New Minimum: 0.6734024584293365 > 0.6456481516361237
WOLF (strong): th(144675.9259259261)=0.6456481516361237; dx=2.7700354404441576E-8 evalInputDelta=0.02775430679321289
END: th(72337.96296296305)=0.6513552665710449; dx=-2.2775198669851423E-7 evalInputDelta=0.022047191858291626
Fitness changed from 0.6734024584293365 to 0.6456481516361237
Iteration 24 complete. Error: 0.6456481516361237 Total: 4.0403; Orientation: 0.4169; Line Search: 2.7628
Adding measurement 494e6dbb to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.682e+02, gradient 5.779e-04, dot -0.725; [49e1432b-974c-4ffb-9a30-0a3a1adf4640 = 1.000/1.000e+00]
Orientation rejected. Popping history element from 0.7367033958435059, 0.7051044702529907, 0.6734024584293365, 0.6456481516361237
LBFGS Accumulation History: 3 points
Removed measurement 49a344c7 to history. Total: 4
th(0)=0.6456481516361237;dx=-3.3396085074542824E-7
New Minimum: 0.6456481516361237 > 0.6211962997913361
END: th(155847.41681364918)=0.6211962997913361; dx=-5.961348792073139E-8 evalInputDelta=0.024451851844787598
Fitness changed from 0.6456481516361237 to 0.6211962997913361
Iteration 25 complete. Error: 0.6211962997913361 Total: 3.4167; Orientation: 0.6323; Line Search: 1.7988
<a id="p-19"></a>Iteration 25
<a id="p-18"></a>![Iteration 25](etc/f7d19ee3-9ce1-4535-9a81-d76690cb89e4.jpg)
Final threshold in iteration 26: 0.6211962997913361 (> -Infinity) after 104.010s (< 3600.000s)
0.6211962997913361