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

Code from BasicOptimizer.scala:75 executed in 39.55 seconds (1.000 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: 916462140575400
    Reset training subject: 916462765325900
    Adding measurement a16e163 to history. Total: 0
    LBFGS Accumulation History: 1 points
    Constructing line search parameters: GD+Trust
    th(0)=2.5761242657899857;dx=-6.659002503551421E-6
    New Minimum: 2.5761242657899857 > 2.5761141180992126
    WOLFE (weak): th(2.154434690031884)=2.5761141180992126; dx=-6.6590633498041445E-6 evalInputDelta=1.0147690773010254E-5
    New Minimum: 2.5761141180992126 > 2.5761035084724426
    WOLFE (weak): th(4.308869380063768)=2.5761035084724426; dx=-6.659263022988834E-6 evalInputDelta=2.0757317543029785E-5
    New Minimum: 2.5761035084724426 > 2.5760624706745148
    WOLFE (weak): th(12.926608140191302)=2.5760624706745148; dx=-6.660315417034905E-6 evalInputDelta=6.179511547088623E-5
    New Minimum: 2.5760624706745148 > 2.575876146554947
    WOLFE (weak): th(51.70643256076521)=2.575876146554947; dx=-6.659971284207196E-6 evalInputDelta=2.481192350387573E-4
    New Minimum: 2.575876146554947 > 2.5748808681964874
    WOLFE (weak): th(258.53216280382605)=2.5748808681964874; dx=-6.692540402749792E-6 evalInputDelta=0.00124339759349823
    New Minimum: 2.5748808681964874 > 2.568627044558525
    WOLFE (weak): th(1551.1929768229563)=2.568627044558525; dx=-6.678191634453576E-6 evalInputDelta=0.007497221231460571
    New Minimum: 2.568627044558525 > 2.523534342646599
    WOLFE (weak): th(10858.350837760694)=2.523534342646599; dx=-6.243818097010745E-6 evalInputDelta=0.05258992314338684
    New Minimum: 2.523534342646599 > 2.256653815507889
    END: th(86866.80670208555)=2.256653815507889; dx=-2.967528880812849E-6 evalInputDelta=0.31947045028209686
    Fitness changed from 2.5761242657899857 to 2.256653815507889
    Iteration 1 complete. Error: 2.256653815507889 Total: 7.0508; Orientation: 0.0035; Line Search: 5.3667
    <a id="p-3"></a>Iteration 1
    <a id="p-2"></a>![Iteration 1](etc/e59b818b-e632-4070-9ab6-a194fdb6749c.jpg)
    
    Adding measurement 49d5e998 to history. Total: 1
    LBFGS Accumulation History: 2 points
    th(0)=2.256653815507889;dx=-5.945748962538831E-6
    New Minimu

...skipping 10491 bytes...

    BFGS Orientation magnitude: 1.484e+03, gradient 1.717e-04, dot -0.653; [68965d52-3389-4141-bd8b-16b8d7250c0e = 1.000/1.000e+00]
    Orientation rejected. Popping history element from 0.19301655888557434, 0.15906846523284912, 0.12285080552101135, 0.09363415837287903
    LBFGS Accumulation History: 3 points
    Removed measurement 1490a44b to history. Total: 4
    th(0)=0.09363415837287903;dx=-2.9470885035798877E-8
    Armijo: th(6498224.367057895)=0.13947051763534546; dx=1.8192309778701225E-8 evalInputDelta=-0.04583635926246643
    New Minimum: 0.09363415837287903 > 0.08190885186195374
    WOLF (strong): th(3249112.1835289476)=0.08190885186195374; dx=8.339270805825724E-9 evalInputDelta=0.011725306510925293
    New Minimum: 0.08190885186195374 > 0.07676202058792114
    END: th(1083037.3945096491)=0.07676202058792114; dx=-1.2815496329519373E-8 evalInputDelta=0.016872137784957886
    Fitness changed from 0.09363415837287903 to 0.07676202058792114
    Iteration 14 complete. Error: 0.07676202058792114 Total: 2.9336; Orientation: 0.1050; Line Search: 2.2415
    Adding measurement 1342bfef to history. Total: 3
    Rejected: LBFGS Orientation magnitude: 1.347e+03, gradient 1.279e-04, dot -0.822; [68965d52-3389-4141-bd8b-16b8d7250c0e = 1.000/1.000e+00]
    Orientation rejected. Popping history element from 0.15906846523284912, 0.12285080552101135, 0.09363415837287903, 0.07676202058792114
    LBFGS Accumulation History: 3 points
    Removed measurement 5ea0db7d to history. Total: 4
    th(0)=0.07676202058792114;dx=-1.6353773327804235E-8
    New Minimum: 0.07676202058792114 > 0.05639570951461792
    END: th(2333333.333333335)=0.05639570951461792; dx=-1.0387708968592576E-8 evalInputDelta=0.020366311073303223
    Fitness changed from 0.07676202058792114 to 0.05639570951461792
    Iteration 15 complete. Error: 0.05639570951461792 Total: 1.8834; Orientation: 0.1089; Line Search: 1.1915
    <a id="p-15"></a>Iteration 15
    <a id="p-14"></a>![Iteration 15](etc/c18f70c9-3d64-4104-95ae-49af6738758b.jpg)
    
    Final threshold in iteration 16: 0.05639570951461792 (> -Infinity) after 39.549s (< 1800.000s)
    

Returns:

    0.05639570951461792