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 110.52 seconds (1.643 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: 46663201875600
Reset training subject: 46665506103500
Adding measurement 44af4b8 to history. Total: 0
LBFGS Accumulation History: 1 points
Constructing line search parameters: GD+Trust
th(0)=-47.77454858228092;dx=-1.6203519588669365E-6
New Minimum: -47.77454858228092 > -47.77455041279392
END: th(2.154434690031884)=-47.77455041279392; dx=-1.2242788026560004E-6 evalInputDelta=1.8305129998452685E-6
Fitness changed from -47.77454858228092 to -47.77455041279392
Iteration 1 complete. Error: -47.77455041279392 Total: 11.5100; Orientation: 0.0610; Line Search: 4.6184
<a id="p-3"></a>Iteration 1
<a id="p-2"></a>![Iteration 1](etc/d2f22627-5154-41cf-971c-6b04f8fd2356.jpg)
Adding measurement 2b8f52f5 to history. Total: 1
LBFGS Accumulation History: 2 points
th(0)=-47.77455041279392;dx=-1.2076940280965391E-6
New Minimum: -47.77455041279392 > -47.774557734845196
WOLFE (weak): th(4.641588833612779)=-47.774557734845196; dx=-1.2048453257037364E-6 evalInputDelta=7.3220512746274835E-6
New Minimum: -47.774557734845196 > -47.774565056895355
WOLFE (weak): th(9.283177667225559)=-47.774565056895355; dx=-1.2033498719953833E-6 evalInputDelta=1.4644101433702872E-5
New Minimum: -47.774565056895355 > -47.77459068406206
WOLFE (weak): th(27.849533001676676)=-47.77459068406206; dx=-1.20249230412508E-6 evalInputDelta=4.027126814065696E-5
New Minimum: -47.77459068406206 > -47.77469868411357
WOLFE (weak): th(111.3981320067067)=-47.77469868411357; dx=-1.2011391038449322E-6 evalInputDelta=1.4827131964523232E-4
New Minimum: -47.77469868411357 > -47.77528078188195
WOLFE (weak): th(556.9906600335335)=-47.77528078188195; dx=-1.2012447930961575E-6 evalInputDelta=7.303690880320346E-4
New Minimum: -47.77528078188195 > -47.77891781708831
WOLFE (weak): th(3341.9439602012008)=-47.77891781708831; dx=-1.2011909279603865E-6 evalInputDelta=0.004367404294391974
New Minimum: -47.77891781708831 > -47.8051028878071
WOLFE (weak): th(23393.607721408407)=-47.8051028878071; dx=-1.1989082521886837E-6 evalInputDelta=0.030552475013180924
New Minimum: -47.8051028878071 > -48.01764460216034
WOLFE (weak): th(187148.86177126726)=-48.01764460216034; dx=-1.185148447999398E-6 evalInputDelta=0.2430941893664169
New Minimum: -48.01764460216034 > -49.839442534458165
END: th(1684339.7559414054)=-49.839442534458165; dx=-1.0551867488390707E-6 evalInputDelta=2.0648921216642435
Fitness changed from -47.77455041279392 to -49.839442534458165
Iteration 2 complete. Error: -49.839442534458165 Total: 25.5569; Orientation: 0.0628; Line Search: 22.9046
<a id="p-5"></a>Iteration 2
<a id="p-4"></a>![Iteration 2](etc/a3eef6a4-6cbb-4c60-8cd9-795aa2220b0b.jpg)
Adding measurement 4eb82b99 to history. Total: 2
LBFGS Accumulation History: 3 points
th(0)=-49.839442534458165;dx=-1.067937585077605E-6
New Minimum: -49.839442534458165 > -53.36476750305437
END: th(3628800.0000000005)=-53.36476750305437; dx=-7.909912562368861E-7 evalInputDelta=3.525324968596202
Fitness changed from -49.839442534458165 to -53.36476750305437
Iteration 3 complete. Error: -53.36476750305437 Total: 7.4948; Orientation: 0.0626; Line Search: 4.6785
<a id="p-7"></a>Iteration 3
<a id="p-6"></a>![Iteration 3](etc/89488c92-f8b6-4da7-9fd7-0432ddd599d8.jpg)
Adding measurement 3063e6e to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.611e+04, gradient 8.669e-04, dot -0.889; [494278b3-a826-499c-bd16-3e696920e9bc = 1.000/1.000e+00]
Orientation rejected. Popping history element from -53.36476750305437, -49.839442534458165, -47.77455041279392, -47.77454858228092
LBFGS Accumulation History: 3 points
Removed measurement 3063e6e to history. Total: 3
th(0)=-53.36476750305437;dx=-7.509117942500397E-7
New Minimum: -53.36476750305437 > -58.62928790930578
END: th(7818012.603187701)=-58.62928790930578; dx=-5.176938900372174E-7 evalInputDelta=5.264520406251414
Fitness changed from -53.36476750305437 to -58.62928790930578
Iteration 4 complete. Error: -58.62928790930578 Total: 8.7477; Orientation: 1.1980; Line Search: 4.8583
<a id="p-9"></a>Iteration 4
<a id="p-8"></a>![Iteration 4](etc/93e1eb45-e3a3-43e3-93a5-d437bf7d83b7.jpg)
Adding measurement 6d97c69f to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.432e+04, gradient 7.313e-04, dot -0.774; [494278b3-a826-499c-bd16-3e696920e9bc = 1.000/1.000e+00]
Orientation rejected. Popping history element from -58.62928790930578, -49.839442534458165, -47.77455041279392, -47.77454858228092
LBFGS Accumulation History: 3 points
Removed measurement 6d97c69f to history. Total: 3
th(0)=-58.62928790930578;dx=-5.339887020307373E-7
New Minimum: -58.62928790930578 > -66.0303445674979
END: th(1.6843397559414055E7)=-66.0303445674979; dx=-3.164588685905631E-7 evalInputDelta=7.401056658192125
Fitness changed from -58.62928790930578 to -66.0303445674979
Iteration 5 complete. Error: -66.0303445674979 Total: 8.5047; Orientation: 1.3720; Line Search: 4.5978
<a id="p-11"></a>Iteration 5
<a id="p-10"></a>![Iteration 5](etc/0a48c59a-035c-4e4f-bf5c-ae28cbb72a43.jpg)
Adding measurement 283dbfdb to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.947e+04, gradient 6.636e-04, dot -0.637; [494278b3-a826-499c-bd16-3e696920e9bc = 1.000/1.000e+00]
Orientation rejected. Popping history element from -66.0303445674979, -49.839442534458165, -47.77455041279392, -47.77454858228092
LBFGS Accumulation History: 3 points
Removed measurement 283dbfdb to history. Total: 3
th(0)=-66.0303445674979;dx=-4.384868796040845E-7
New Minimum: -66.0303445674979 > -74.68397333678598
END: th(3.628800000000001E7)=-74.68397333678598; dx=-1.1216681988082536E-7 evalInputDelta=8.653628769288076
Fitness changed from -66.0303445674979 to -74.68397333678598
Iteration 6 complete. Error: -74.68397333678598 Total: 8.4705; Orientation: 1.0201; Line Search: 4.5902
Adding measurement 61486a61 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.176e+04, gradient 7.864e-04, dot -0.333; [494278b3-a826-499c-bd16-3e696920e9bc = 1.000/1.000e+00]
Orientation rejected. Popping history element from -74.68397333678598, -49.839442534458165, -47.77455041279392, -47.77454858228092
LBFGS Accumulation History: 3 points
Removed measurement 61486a61 to history. Total: 3
th(0)=-74.68397333678598;dx=-6.170563125752154E-7
Armijo: th(7.818012603187701E7)=-71.82596340311034; dx=1.2221367985908926E-7 evalInputDelta=-2.858009933675646
New Minimum: -74.68397333678598 > -78.32399507747397
WOLF (strong): th(3.9090063015938506E7)=-78.32399507747397; dx=1.2946225425551158E-7 evalInputDelta=3.6400217406879847
New Minimum: -78.32399507747397 > -79.95421305112006
END: th(1.3030021005312836E7)=-79.95421305112006; dx=-1.6204913966161413E-7 evalInputDelta=5.270239714334082
Fitness changed from -74.68397333678598 to -79.95421305112006
Iteration 7 complete. Error: -79.95421305112006 Total: 12.1151; Orientation: 1.0204; Line Search: 8.9031
Adding measurement 12859a92 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.457e+04, gradient 5.751e-04, dot -0.555; [494278b3-a826-499c-bd16-3e696920e9bc = 1.000/1.000e+00]
Orientation rejected. Popping history element from -79.95421305112006, -49.839442534458165, -47.77455041279392, -47.77454858228092
LBFGS Accumulation History: 3 points
Removed measurement 12859a92 to history. Total: 3
th(0)=-79.95421305112006;dx=-3.301752119404857E-7
New Minimum: -79.95421305112006 > -84.92473516459167
END: th(2.8072329265690096E7)=-84.92473516459167; dx=-6.737433689055237E-8 evalInputDelta=4.970522113471603
Fitness changed from -79.95421305112006 to -84.92473516459167
Iteration 8 complete. Error: -84.92473516459167 Total: 7.6704; Orientation: 0.9954; Line Search: 4.4298
Adding measurement 526f711f to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.791e+04, gradient 6.883e-04, dot -0.401; [494278b3-a826-499c-bd16-3e696920e9bc = 1.000/1.000e+00]
Orientation rejected. Popping history element from -84.92473516459167, -49.839442534458165, -47.77455041279392, -47.77454858228092
LBFGS Accumulation History: 3 points
Removed measurement 526f711f to history. Total: 3
th(0)=-84.92473516459167;dx=-4.7280098830046994E-7
Armijo: th(6.048000000000002E7)=-83.3515677412782; dx=1.2050267261970646E-7 evalInputDelta=-1.573167423313464
New Minimum: -84.92473516459167 > -87.9963999428803
WOLF (strong): th(3.024000000000001E7)=-87.9963999428803; dx=1.0198245125749647E-7 evalInputDelta=3.0716647782886355
New Minimum: -87.9963999428803 > -88.39433309514705
END: th(1.0080000000000004E7)=-88.39433309514705; dx=-1.805053544538722E-7 evalInputDelta=3.4695979305553806
Fitness changed from -84.92473516459167 to -88.39433309514705
Iteration 9 complete. Error: -88.39433309514705 Total: 12.2123; Orientation: 0.9981; Line Search: 9.0094
Adding measurement 602c46ce to history. Total: 3
Rejected: LBFGS Orientation magnitude: 4.783e+04, gradient 4.807e-04, dot -0.625; [494278b3-a826-499c-bd16-3e696920e9bc = 1.000/1.000e+00]
Orientation rejected. Popping history element from -88.39433309514705, -49.839442534458165, -47.77455041279392, -47.77454858228092
LBFGS Accumulation History: 3 points
Removed measurement 602c46ce to history. Total: 3
th(0)=-88.39433309514705;dx=-2.3003787739894438E-7
New Minimum: -88.39433309514705 > -92.13336866974772
END: th(2.1716701675521396E7)=-92.13336866974772; dx=-1.240677171035905E-7 evalInputDelta=3.7390355746006776
Fitness changed from -88.39433309514705 to -92.13336866974772
Iteration 10 complete. Error: -92.13336866974772 Total: 7.7999; Orientation: 1.0408; Line Search: 4.5675
<a id="p-13"></a>Iteration 10
<a id="p-12"></a>![Iteration 10](etc/a0d13488-5515-4b48-85c4-21f205ec34eb.jpg)
Final threshold in iteration 11: -92.13336866974772 (> -Infinity) after 110.518s (< 5400.000s)

Returns

    -92.13336866974772