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

Iteration 20 Iteration 20

Iteration 25 Iteration 25

Code from BasicOptimizer.scala:75 executed in 100.81 seconds (2.651 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]

Logging:

    Reset training subject: 901208614645700
    Reset training subject: 901209534102900
    Adding measurement 4ff19f87 to history. Total: 0
    LBFGS Accumulation History: 1 points
    Constructing line search parameters: GD+Trust
    th(0)=4.168469525873661;dx=-7.178605964869227E-5
    New Minimum: 4.168469525873661 > 4.168336246162653
    WOLFE (weak): th(2.154434690031884)=4.168336246162653; dx=-7.177179541448372E-5 evalInputDelta=1.332797110080719E-4
    New Minimum: 4.168336246162653 > 4.1682024877518415
    WOLFE (weak): th(4.308869380063768)=4.1682024877518415; dx=-7.17705675216166E-5 evalInputDelta=2.6703812181949615E-4
    New Minimum: 4.1682024877518415 > 4.167668418958783
    WOLFE (weak): th(12.926608140191302)=4.167668418958783; dx=-7.168971871338977E-5 evalInputDelta=8.011069148778915E-4
    New Minimum: 4.167668418958783 > 4.165306121110916
    WOLFE (weak): th(51.70643256076521)=4.165306121110916; dx=-6.948795553118648E-5 evalInputDelta=0.0031634047627449036
    New Minimum: 4.165306121110916 > 4.152840195223689
    WOLFE (weak): th(258.53216280382605)=4.152840195223689; dx=-6.985454642263213E-5 evalInputDelta=0.015629330649971962
    New Minimum: 4.152840195223689 > 4.084876835346222
    WOLFE (weak): th(1551.1929768229563)=4.084876835346222; dx=-6.689402526837146E-5 evalInputDelta=0.08359269052743912
    New Minimum: 4.084876835346222 > 3.681548535823822
    END: th(10858.350837760694)=3.681548535823822; dx=-5.267713447437284E-5 evalInputDelta=0.486920990049839
    Fitness changed from 4.168469525873661 to 3.681548535823822
    Iteration 1 complete. Error: 3.681548535823822 Total: 9.5904; Orientation: 0.0140; Line Search: 6.9865
    <a id="p-3"></a>Iteration 1
    <a id="p-2"></a>![Iteration 1](etc/97321205-f3be-4a21-8bdc-26a59004601f.jpg)
    
    Adding measurement 4981dd9 to history. Total: 1
    LBFGS Accumulation History: 2 points
    th(0)=3.681548535823822;dx=-2.566733326772727E-4
    New Minimum: 3.681548535823822 > 3.231771372258663
    END: th(23393.607721408407)=3.231771372258663; dx=-1.5969229614297132E-5 evalInputDelta=0.44977716356515884
    Fitness changed from 3.6815485358

...skipping 19446 bytes...

    al: 3
    Rejected: LBFGS Orientation magnitude: 3.581e+02, gradient 4.251e-04, dot -0.630; [45bb7307-18b6-4027-9ef9-eb4b767845a1 = 1.000/1.000e+00]
    Orientation rejected. Popping history element from 0.5831555426120758, 0.5475651621818542, 0.5218540132045746, 0.4950978010892868
    LBFGS Accumulation History: 3 points
    Removed measurement 732af580 to history. Total: 4
    th(0)=0.4950978010892868;dx=-1.8075182893162675E-7
    Armijo: th(1012731.4814814827)=0.5052830576896667; dx=7.717562290558617E-8 evalInputDelta=-0.010185256600379944
    New Minimum: 0.4950978010892868 > 0.4775574505329132
    WOLF (strong): th(506365.74074074137)=0.4775574505329132; dx=3.4782094196564024E-8 evalInputDelta=0.017540350556373596
    New Minimum: 0.4775574505329132 > 0.47737744450569153
    END: th(168788.5802469138)=0.47737744450569153; dx=-7.074994760314E-8 evalInputDelta=0.017720356583595276
    Fitness changed from 0.4950978010892868 to 0.47737744450569153
    Iteration 24 complete. Error: 0.47737744450569153 Total: 5.0373; Orientation: 0.4245; Line Search: 3.7779
    Adding measurement 714f3e27 to history. Total: 3
    Rejected: LBFGS Orientation magnitude: 4.085e+02, gradient 2.861e-04, dot -0.894; [45bb7307-18b6-4027-9ef9-eb4b767845a1 = 1.000/1.000e+00]
    Orientation rejected. Popping history element from 0.5475651621818542, 0.5218540132045746, 0.4950978010892868, 0.47737744450569153
    LBFGS Accumulation History: 3 points
    Removed measurement 78e469ac to history. Total: 4
    th(0)=0.47737744450569153;dx=-8.187315641925892E-8
    New Minimum: 0.47737744450569153 > 0.45692867040634155
    END: th(363643.9725651815)=0.45692867040634155; dx=-6.024063844468606E-8 evalInputDelta=0.020448774099349976
    Fitness changed from 0.47737744450569153 to 0.45692867040634155
    Iteration 25 complete. Error: 0.45692867040634155 Total: 3.0145; Orientation: 0.4262; Line Search: 1.7576
    <a id="p-19"></a>Iteration 25
    <a id="p-18"></a>![Iteration 25](etc/434ef67e-d7a1-4717-8a21-f2e83f9fc6ea.jpg)
    
    Final threshold in iteration 26: 0.45692867040634155 (> -Infinity) after 100.807s (< 3600.000s)
    

Returns:

    0.45692867040634155