Code from BasicOptimizer.scala:75 executed in 604.55 seconds (7.600 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: 6591097765799
Reset training subject: 6594333316670
Adding measurement 16f45ea to history. Total: 0
LBFGS Accumulation History: 1 points
Constructing line search parameters: GD+Trust
th(0)=0.9825756734485561;dx=-4.311684426364113E-8
New Minimum: 0.9825756734485561 > 0.9825756002699718
WOLFE (weak): th(2.154434690031884)=0.9825756002699718; dx=-4.311573696051644E-8 evalInputDelta=7.317858430333501E-8
New Minimum: 0.9825756002699718 > 0.9825755270928556
WOLFE (weak): th(4.308869380063768)=0.9825755270928556; dx=-4.31159330365437E-8 evalInputDelta=1.4635570055876457E-7
New Minimum: 0.9825755270928556 > 0.982575234387411
WOLFE (weak): th(12.926608140191302)=0.982575234387411; dx=-4.311997194397956E-8 evalInputDelta=4.39061145107722E-7
New Minimum: 0.982575234387411 > 0.9825739174670097
WOLFE (weak): th(51.70643256076521)=0.9825739174670097; dx=-4.311613844444451E-8 evalInputDelta=1.7559815463918937E-6
New Minimum: 0.9825739174670097 > 0.982566894722748
WOLFE (weak): th(258.53216280382605)=0.982566894722748; dx=-4.308438030957381E-8 evalInputDelta=8.778725808067378E-6
New Minimum: 0.982566894722748 > 0.9825233010429736
WOLFE (weak): th(1551.1929768229563)=0.9825233010429736; dx=-4.279643091438844E-8 evalInputDelta=5.2372405582534753E-5
New Minimum: 0.9825233010429736 > 0.9822211357823746
WOLFE (weak): th(10858.350837760694)=0.9822211357823746; dx=-3.994893688785875E-8 evalInputDelta=3.545376661815425E-4
New Minimum: 0.9822211357823746 > 0.9803974263368525
END: th(86866.80670208555)=0.9803974263368525; dx=-2.696116520056681E-8 evalInputDelta=0.0021782471117036684
Fitness changed from 0.9825756734485561 to 0.9803974263368525
Iteration 1 complete. Error: 0.9803974263368525 Total: 31.4799; Orientation: 0.0764; Line Search: 23.2483
<a id="p-3"></a>Iteration 1
<a id="p-2"></a>![Iteration 1](etc/e786c62a-0977-4e29-a0fc-ef86bf40859e.jpg)
Adding measurement 5bd3fab9 to history. Total: 1
LBFGS Accumulation History: 2 points
th(0)=0.9803974263368525;dx=-2.753443337189208E-8
New Minimum: 0.980397426336852
...skipping 42924 bytes...
al: 9.2343; Orientation: 1.6113; Line Search: 5.1823
Adding measurement 5b4ad8a9 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.551e+02, gradient 6.114e-04, dot -0.587; [0ab1d1b1-5bcf-4f4a-b45c-a3666c753b15 = 1.000/1.000e+00]
Orientation rejected. Popping history element from 0.7562467622262716, 0.7499737987848709, 0.7456196234230551, 0.7405147735730182
LBFGS Accumulation History: 3 points
Removed measurement 58bd5df9 to history. Total: 4
th(0)=0.7405147735730182;dx=-3.7375123180251177E-7
Armijo: th(338287.862900268)=0.7707367448331074; dx=8.838271168990884E-8 evalInputDelta=-0.030221971260089187
Armijo: th(169143.931450134)=0.7436190258686115; dx=5.8233018928343685E-8 evalInputDelta=-0.0031042522955933016
New Minimum: 0.7405147735730182 > 0.7330981612294248
END: th(56381.310483378)=0.7330981612294248; dx=-1.270872586564139E-7 evalInputDelta=0.007416612343593365
Fitness changed from 0.7405147735730182 to 0.7330981612294248
Iteration 49 complete. Error: 0.7330981612294248 Total: 14.3677; Orientation: 1.6052; Line Search: 10.3266
Adding measurement 65507e03 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 7.495e+01, gradient 4.360e-04, dot -0.797; [0ab1d1b1-5bcf-4f4a-b45c-a3666c753b15 = 1.000/1.000e+00]
Orientation rejected. Popping history element from 0.7499737987848709, 0.7456196234230551, 0.7405147735730182, 0.7330981612294248
LBFGS Accumulation History: 3 points
Removed measurement 46585a5a to history. Total: 4
th(0)=0.7330981612294248;dx=-1.9010134383430934E-7
New Minimum: 0.7330981612294248 > 0.7286992102414748
END: th(121469.85117484789)=0.7286992102414748; dx=-7.98566661701596E-8 evalInputDelta=0.004398950987950068
Fitness changed from 0.7330981612294248 to 0.7286992102414748
Iteration 50 complete. Error: 0.7286992102414748 Total: 9.2206; Orientation: 1.6031; Line Search: 5.1800
<a id="p-29"></a>Iteration 50
<a id="p-28"></a>![Iteration 50](etc/6a652643-724b-4c84-997b-19a9b4378227.jpg)
Final threshold in iteration 51: 0.7286992102414748 (> -Infinity) after 604.548s (< 3600.000s)
0.7286992102414748