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

Iteration 30 Iteration 30

Code from BasicOptimizer.scala:75 executed in 925.63 seconds (6.289 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: 1022735749089100
    Reset training subject: 1022744333040700
    Adding measurement 6cb1da13 to history. Total: 0
    LBFGS Accumulation History: 1 points
    Constructing line search parameters: GD+Trust
    th(0)=11.389972254633904;dx=-3.052976385852236E-5
    New Minimum: 11.389972254633904 > 11.38989719375968
    WOLFE (weak): th(2.154434690031884)=11.38989719375968; dx=-3.052923375744368E-5 evalInputDelta=7.50608742237091E-5
    New Minimum: 11.38989719375968 > 11.389821819961071
    WOLFE (weak): th(4.308869380063768)=11.389821819961071; dx=-3.053270987525937E-5 evalInputDelta=1.5043467283248901E-4
    New Minimum: 11.389821819961071 > 11.389522355049849
    WOLFE (weak): th(12.926608140191302)=11.389522355049849; dx=-3.051869105225798E-5 evalInputDelta=4.498995840549469E-4
    New Minimum: 11.389522355049849 > 11.388171892613173
    WOLFE (weak): th(51.70643256076521)=11.388171892613173; dx=-3.051285014575768E-5 evalInputDelta=0.0018003620207309723
    New Minimum: 11.388171892613173 > 11.380975790321827
    WOLFE (weak): th(258.53216280382605)=11.380975790321827; dx=-3.0485606889946467E-5 evalInputDelta=0.008996464312076569
    New Minimum: 11.380975790321827 > 11.336159221827984
    WOLFE (weak): th(1551.1929768229563)=11.336159221827984; dx=-3.0274478482776206E-5 evalInputDelta=0.05381303280591965
    New Minimum: 11.336159221827984 > 11.022681456059217
    WOLFE (weak): th(10858.350837760694)=11.022681456059217; dx=-2.8576023326641588E-5 evalInputDelta=0.36729079857468605
    New Minimum: 11.022681456059217 > 9.09514033794403
    END: th(86866.80670208555)=9.09514033794403; dx=-1.6263458989397623E-5 evalInputDelta=2.2948319166898727
    Fitness changed from 11.389972254633904 to 9.09514033794403
    Iteration 1 complete. Error: 9.09514033794403 Total: 92.8719; Orientation: 0.0470; Line Search: 69.0851
    <a id="p-3"></a>Iteration 1
    <a id="p-2"></a>![Iteration 1](etc/64487bb0-e99f-4f90-8218-580cf68c8c15.jpg)
    
    Adding measurement 49aa6081 to history. Total: 1
    LBFGS Accumulation History: 2 points
    th(0)=9.09514033794403;dx=-1.188499919651153E-5
    New

...skipping 24278 bytes...

    
    Adding measurement 4bc1a53c to history. Total: 3
    Rejected: LBFGS Orientation magnitude: 3.219e+03, gradient 1.083e-04, dot -0.655; [fc03045b-1f1e-4f5a-ac24-3dcf1fff2d64 = 1.000/1.000e+00]
    Orientation rejected. Popping history element from -2.3238086849451065, -2.358418971300125, -2.382256895303726, -2.4120919182896614
    LBFGS Accumulation History: 3 points
    Removed measurement 109de896 to history. Total: 4
    th(0)=-2.4120919182896614;dx=-1.171384392991316E-8
    Armijo: th(2.0891925048411455E7)=-2.190155364573002; dx=1.4064203865352805E-8 evalInputDelta=-0.22193655371665955
    Armijo: th(1.0445962524205728E7)=-2.383414089679718; dx=7.810478840468454E-9 evalInputDelta=-0.02867782860994339
    New Minimum: -2.4120919182896614 > -2.4327174201607704
    END: th(3481987.508068576)=-2.4327174201607704; dx=-2.8372325977797225E-9 evalInputDelta=0.02062550187110901
    Fitness changed from -2.4120919182896614 to -2.4327174201607704
    Iteration 29 complete. Error: -2.4327174201607704 Total: 38.9299; Orientation: 0.2304; Line Search: 30.8260
    Adding measurement 489b0369 to history. Total: 3
    Rejected: LBFGS Orientation magnitude: 2.492e+03, gradient 8.443e-05, dot -0.729; [fc03045b-1f1e-4f5a-ac24-3dcf1fff2d64 = 1.000/1.000e+00]
    Orientation rejected. Popping history element from -2.358418971300125, -2.382256895303726, -2.4120919182896614, -2.4327174201607704
    LBFGS Accumulation History: 3 points
    Removed measurement 5785b1b7 to history. Total: 4
    th(0)=-2.4327174201607704;dx=-7.120327443108257E-9
    New Minimum: -2.4327174201607704 > -2.4527121633291245
    END: th(7501714.677640614)=-2.4527121633291245; dx=-3.1928276923548263E-9 evalInputDelta=0.019994743168354034
    Fitness changed from -2.4327174201607704 to -2.4527121633291245
    Iteration 30 complete. Error: -2.4527121633291245 Total: 23.6170; Orientation: 0.2379; Line Search: 15.8750
    <a id="p-21"></a>Iteration 30
    <a id="p-20"></a>![Iteration 30](etc/ac349f71-641b-495f-bacc-c0fe1133ad2b.jpg)
    
    Final threshold in iteration 31: -2.4527121633291245 (> -Infinity) after 925.612s (< 3600.000s)
    

Returns:

    -2.4527121633291245