Iteration 1 Iteration 1

Iteration 2 Iteration 2

Iteration 3 Iteration 3

Iteration 4 Iteration 4

Iteration 5 Iteration 5

Iteration 10 Iteration 10

BasicOptimizer.scala:89 executed in 203.75 seconds (2.276 gc):

    val lineSearchInstance: LineSearchStrategy = lineSearchFactory
    val trainer = new IterativeTrainer(trainable)
    trainer.setOrientation(orientation())
    trainer.setMonitor(new TrainingMonitor() {
      override def clear(): Unit = trainingMonitor.clear()
  
      override def log(msg: String): Unit = {
        trainingMonitor.log(msg)
        BasicOptimizer.this.log(msg)
      }
  
      override def onStepFail(currentPoint: Step): Boolean = {
        BasicOptimizer.this.onStepFail(trainable.addRef().asInstanceOf[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.addRef().asInstanceOf[Trainable], currentPoint)
        trainingMonitor.onStepComplete(currentPoint)
        super.onStepComplete(currentPoint)
      }
    })
    trainer.setTimeout(trainingMinutes, TimeUnit.MINUTES)
    trainer.setMaxIterations(trainingIterations)
    trainer.setLineSearchFactory((_: CharSequence) => lineSearchInstance)
    trainer.setTerminateThreshold(java.lang.Double.NEGATIVE_INFINITY)
    val result = trainer.run.asInstanceOf[lang.Double]
    trainer.freeRef()
    result
Logging
Reset training subject: 14260408402324
Reset training subject: 14264547722695
Adding measurement a341c71 to history. Total: 0
LBFGS Accumulation History: 1 points
Constructing line search parameters: GD+Trust
th(0)=-0.41361893713474274;dx=-6.106848801365917E-7
New Minimum: -0.41361893713474274 > -0.4136192500591278
END: th(2.154434690031884)=-0.4136192500591278; dx=-5.389217194517487E-7 evalInputDelta=3.129243850708008E-7
Fitness changed from -0.41361893713474274 to -0.4136192500591278
Iteration 1 complete. Error: -0.4136192500591278 Total: 21.6898; Orientation: 0.0474; Line Search: 8.7009
<a id="p-3"></a>Iteration 1
<a id="p-2"></a>![Iteration 1](etc/65271a4c-8bd1-4025-8460-34276ed11823.jpg)

    Adding measurement 67813262 to history. Total: 1
    LBFGS Accumulation History: 2 points
    th(0)=-0.4136192500591278;dx=-5.388963357704328E-7
    New Minimum: -0.4136192500591278 > -0.4136206656694412
    WOLFE (weak): th(4.641588833612779)=-0.4136206656694412; dx=-5.388377114211629E-7 evalInputDelta=1.4156103134155273E-6
    New Minimum: -0.4136206656694412 > -0.4136219620704651
    WOLFE (weak): th(9.283177667225559)=-0.4136219620704651; dx=-5.388357024524335E-7 evalInputDelta=2.7120113372802734E-6
    New Minimum: -0.4136219620704651 > -0.4136270433664322
    WOLFE (weak): th(27.849533001676676)=-0.4136270433664322; dx=-5.388180539527598E-7 evalInputDelta=7.793307304382324E-6
    New Minimum: -0.4136270433664322 > -0.41364942491054535
    WOLFE (weak): th(111.3981320067067)=-0.41364942491054535; dx=-5.387945142225405E-7 evalInputDelta=3.0174851417541504E-5
    New Minimum: -0.41364942491054535 > -0.41376960277557373
    WOLFE (weak): th(556.9906600335335)=-0.41376960277557373; dx=-5.387150291137021E-7 evalInputDelta=1.5035271644592285E-4
    New Minimum: -0.41376960277557373 > -0.414519339799881
    WOLFE (weak): th(3341.9439602012008)=-0.414519339799881; dx=-5.38205386121473E-7 evalInputDelta=9.000897407531738E-4
    New Minimum: -0.414519339799881 > -0.4198986291885376
    WOLFE (weak): th(23393.607721408407)=-0.4198986291885376; dx=-5.350265542002583E-7 evalInputDelta=0.00627937912940979
    New Minimum: -0.4198986291885376 > -0.4624783992767334
    WOLFE (weak): th(187148.86177126726)=-0.4624783992767334; dx=-5.05006600338295E-7 evalInputDelta=0.04885914921760559
    New Minimum: -0.4624783992767334 > -0.7409621477127075
    END: th(1684339.7559414054)=-0.7409621477127075; dx=-2.567274216416807E-7 evalInputDelta=0.3273428976535797
    Fitness changed from -0.4136192500591278 to -0.7409621477127075
    Iteration 2 complete. Error: -0.7409621477127075 Total: 48.1403; Orientation: 0.0448; Line Search: 43.9454
    <a id="p-5"></a>Iteration 2
    <a id="p-4"></a>![Iteration 2](etc/82cea59d-df23-4fc6-b78a-7fb4cd713746.jpg)

    Adding measurement 6422c80 to history. Total: 2
    LBFGS Accumulation History: 3 points
    th(0)=-0.7409621477127075;dx=-2.5271604137800665E-7
    New Minimum: -0.7409621477127075 > -1.0412461757659912
    END: th(3628800.0000000005)=-1.0412461757659912; dx=-1.049404148439021E-7 evalInputDelta=0.3002840280532837
    Fitness changed from -0.7409621477127075 to -1.0412461757659912
    Iteration 3 complete. Error: -1.0412461757659912 Total: 13.6400; Orientation: 0.0475; Line Search: 9.0301
    <a id="p-7"></a>Iteration 3
    <a id="p-6"></a>![Iteration 3](etc/dedf4ae1-09b0-4b4c-8981-4f8321fb7740.jpg)

    Adding measurement 291070d7 to history. Total: 3
    Rejected: LBFGS Orientation magnitude: 1.778e+03, gradient 3.745e-04, dot -0.599; [44dc4b19-0cc0-49de-a77d-40bc0d7a9f1b = 1.000/1.000e+00]
    Orientation rejected. Popping history element from -1.0412461757659912, -0.7409621477127075, -0.4136192500591278, -0.41361893713474274
    LBFGS Accumulation History: 3 points
    Removed measurement 291070d7 to history. Total: 3
    th(0)=-1.0412461757659912;dx=-1.4022663911374987E-7
    New Minimum: -1.0412461757659912 > -1.30913645029068
    END: th(7818012.603187701)=-1.30913645029068; dx=-2.812749694235471E-8 evalInputDelta=0.2678902745246887
    Fitness changed from -1.0412461757659912 to -1.30913645029068
    Iteration 4 complete. Error: -1.30913645029068 Total: 13.8405; Orientation: 1.0518; Line Search: 8.4733
    <a id="p-9"></a>Iteration 4
    <a id="p-8"></a>![Iteration 4](etc/8736815b-91eb-4294-adff-67078e5ad808.jpg)

    Adding measurement 6265f4ee to history. Total: 3
    Rejected: LBFGS Orientation magnitude: 1.529e+03, gradient 3.423e-04, dot -0.375; [44dc4b19-0cc0-49de-a77d-40bc0d7a9f1b = 1.000/1.000e+00]
    Orientation rejected. Popping history element from -1.30913645029068, -0.7409621477127075, -0.4136192500591278, -0.41361893713474274
    LBFGS Accumulation History: 3 points
    Removed measurement 6265f4ee to history. Total: 3
    th(0)=-1.30913645029068;dx=-1.1718498646499965E-7
    New Minimum: -1.30913645029068 > -1.4330646246671677
    WOLF (strong): th(1.6843397559414055E7)=-1.4330646246671677; dx=1.7098070843576958E-8 evalInputDelta=0.12392817437648773
    New Minimum: -1.4330646246671677 > -1.4898216426372528
    WOLF (strong): th(8421698.779707028)=-1.4898216426372528; dx=3.884433188099438E-9 evalInputDelta=0.18068519234657288
    END: th(2807232.926569009)=-1.4295051842927933; dx=-5.655112697727446E-8 evalInputDelta=0.12036873400211334
    Fitness changed from -1.30913645029068 to -1.4898216426372528
    Iteration 5 complete. Error: -1.4898216426372528 Total: 22.6620; Orientation: 0.9968; Line Search: 17.0586
    <a id="p-11"></a>Iteration 5
    <a id="p-10"></a>![Iteration 5](etc/5c0d5a83-94b8-418e-8572-ad2a3fc20476.jpg)

    Adding measurement 6b040b5 to history. Total: 3
    Rejected: LBFGS Orientation magnitude: 1.815e+03, gradient 3.046e-04, dot -0.321; [44dc4b19-0cc0-49de-a77d-40bc0d7a9f1b = 1.000/1.000e+00]
    Orientation rejected. Popping history element from -1.4898216426372528, -0.7409621477127075, -0.4136192500591278, -0.41361893713474274
    LBFGS Accumulation History: 3 points
    Removed measurement 6b040b5 to history. Total: 3
    th(0)=-1.4898216426372528;dx=-9.276348025138014E-8
    New Minimum: -1.4898216426372528 > -1.6374501436948776
    END: th(6048000.000000001)=-1.6374501436948776; dx=-1.6003863668430182E-8 evalInputDelta=0.14762850105762482
    Fitness changed from -1.4898216426372528 to -1.6374501436948776
    Iteration 6 complete. Error: -1.6374501436948776 Total: 14.0241; Orientation: 1.0068; Line Search: 8.7324
    Adding measurement 42daa362 to history. Total: 3
    Rejected: LBFGS Orientation magnitude: 2.319e+03, gradient 2.037e-04, dot -0.526; [44dc4b19-0cc0-49de-a77d-40bc0d7a9f1b = 1.000/1.000e+00]
    Orientation rejected. Popping history element from -1.6374501436948776, -0.7409621477127075, -0.4136192500591278, -0.41361893713474274
    LBFGS Accumulation History: 3 points
    Removed measurement 42daa362 to history. Total: 3
    th(0)=-1.6374501436948776;dx=-4.1501684578492456E-8
    New Minimum: -1.6374501436948776 > -1.7608712166547775
    END: th(1.3030021005312836E7)=-1.7608712166547775; dx=-1.2091673624249349E-9 evalInputDelta=0.1234210729598999
    Fitness changed from -1.6374501436948776 to -1.7608712166547775
    Iteration 7 complete. Error: -1.7608712166547775 Total: 14.2749; Orientation: 1.0220; Line Search: 8.7201
    Adding measurement 78c7327f to history. Total: 3
    Rejected: LBFGS Orientation magnitude: 2.145e+03, gradient 2.406e-04, dot -0.314; [44dc4b19-0cc0-49de-a77d-40bc0d7a9f1b = 1.000/1.000e+00]
    Orientation rejected. Popping history element from -1.7608712166547775, -0.7409621477127075, -0.4136192500591278, -0.41361893713474274
    LBFGS Accumulation History: 3 points
    Removed measurement 78c7327f to history. Total: 3
    th(0)=-1.7608712166547775;dx=-5.7911018579483146E-8
    Armijo: th(2.8072329265690096E7)=-1.6664573699235916; dx=2.2339591676160507E-8 evalInputDelta=-0.09441384673118591
    New Minimum: -1.7608712166547775 > -1.8122893273830414
    WOLF (strong): th(1.4036164632845048E7)=-1.8122893273830414; dx=1.8129182076280076E-8 evalInputDelta=0.051418110728263855
    New Minimum: -1.8122893273830414 > -1.8413720726966858
    END: th(4678721.544281683)=-1.8413720726966858; dx=-1.4564197694855124E-8 evalInputDelta=0.08050085604190826
    Fitness changed from -1.7608712166547775 to -1.8413720726966858
    Iteration 8 complete. Error: -1.8413720726966858 Total: 22.4403; Orientation: 1.0089; Line Search: 16.9431
    Adding measurement 131a2772 to history. Total: 3
    Rejected: LBFGS Orientation magnitude: 2.526e+03, gradient 1.508e-04, dot -0.549; [44dc4b19-0cc0-49de-a77d-40bc0d7a9f1b = 1.000/1.000e+00]
    Orientation rejected. Popping history element from -1.8413720726966858, -0.7409621477127075, -0.4136192500591278, -0.41361893713474274
    LBFGS Accumulation History: 3 points
    Removed measurement 131a2772 to history. Total: 3
    th(0)=-1.8413720726966858;dx=-2.275035506106126E-8
    New Minimum: -1.8413720726966858 > -1.9152762591838837
    END: th(1.0080000000000004E7)=-1.9152762591838837; dx=-7.550329752556215E-9 evalInputDelta=0.07390418648719788
    Fitness changed from -1.8413720726966858 to -1.9152762591838837
    Iteration 9 complete. Error: -1.9152762591838837 Total: 13.7982; Orientation: 1.0192; Line Search: 8.7626
    Adding measurement 52696c57 to history. Total: 3
    Rejected: LBFGS Orientation magnitude: 2.559e+03, gradient 1.585e-04, dot -0.462; [44dc4b19-0cc0-49de-a77d-40bc0d7a9f1b = 1.000/1.000e+00]
    Orientation rejected. Popping history element from -1.9152762591838837, -0.7409621477127075, -0.4136192500591278, -0.41361893713474274
    LBFGS Accumulation History: 3 points
    Removed measurement 52696c57 to history. Total: 3
    th(0)=-1.9152762591838837;dx=-2.5130660195706174E-8
    New Minimum: -1.9152762591838837 > -1.9526845514774323
    WOLF (strong): th(2.1716701675521396E7)=-1.9526845514774323; dx=4.572519472716496E-9 evalInputDelta=0.037408292293548584
    New Minimum: -1.9526845514774323 > -1.9667254388332367
    END: th(1.0858350837760698E7)=-1.9667254388332367; dx=-2.3140875805258997E-10 evalInputDelta=0.05144917964935303
    Fitness changed from -1.9152762591838837 to -1.9667254388332367
    Iteration 10 complete. Error: -1.9667254388332367 Total: 19.1710; Orientation: 1.0294; Line Search: 13.7729
    <a id="p-13"></a>Iteration 10
    <a id="p-12"></a>![Iteration 10](etc/c7b1e535-f1bc-47a6-ad42-81034b3f747f.jpg)

    Final threshold in iteration 11: -1.9667254388332367 (> -Infinity) after 203.754s (< 5400.000s)

Returns

    -1.9667254388332367