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 111.14 seconds (1.093 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: 41143764085600
Reset training subject: 41145988086900
Adding measurement 26fc0973 to history. Total: 0
LBFGS Accumulation History: 1 points
Constructing line search parameters: GD+Trust
th(0)=-51.2867218615437;dx=-1.7434056092551401E-6
New Minimum: -51.2867218615437 > -51.28672697701567
END: th(2.154434690031884)=-51.28672697701567; dx=-1.3246933835196628E-6 evalInputDelta=5.115471971350871E-6
Fitness changed from -51.2867218615437 to -51.28672697701567
Iteration 1 complete. Error: -51.28672697701567 Total: 11.4027; Orientation: 0.0651; Line Search: 4.5462
<a id="p-3"></a>Iteration 1
<a id="p-2"></a>![Iteration 1](etc/33d8003c-7763-43a9-b8ab-2874f5223396.jpg)
Adding measurement 6b23422 to history. Total: 1
LBFGS Accumulation History: 2 points
th(0)=-51.28672697701567;dx=-1.3097196297199825E-6
New Minimum: -51.28672697701567 > -51.28673379764416
WOLFE (weak): th(4.641588833612779)=-51.28673379764416; dx=-1.3063483166729918E-6 evalInputDelta=6.8206284922212035E-6
New Minimum: -51.28673379764416 > -51.28673891311494
WOLFE (weak): th(9.283177667225559)=-51.28673891311494; dx=-1.3057631259365902E-6 evalInputDelta=1.1936099269860279E-5
New Minimum: -51.28673891311494 > -51.286766195617126
WOLFE (weak): th(27.849533001676676)=-51.286766195617126; dx=-1.3043853621959812E-6 evalInputDelta=3.9218601457946534E-5
New Minimum: -51.286766195617126 > -51.28688385124156
WOLFE (weak): th(111.3981320067067)=-51.28688385124156; dx=-1.3026245601228312E-6 evalInputDelta=1.5687422589394373E-4
New Minimum: -51.28688385124156 > -51.287514753609
WOLFE (weak): th(556.9906600335335)=-51.287514753609; dx=-1.3030363839713058E-6 evalInputDelta=7.877765933343994E-4
New Minimum: -51.287514753609 > -51.29145175008567
WOLFE (weak): th(3341.9439602012008)=-51.29145175008567; dx=-1.3027391669223636E-6 evalInputDelta=0.004724773070002186
New Minimum: -51.29145175008567 > -51.319781029410905
WOLFE (weak): th(23393.607721408407)=-51.319781029410905; dx=-1.301865689663055E-6 evalInputDelta=0.03305405239523651
New Minimum: -51.319781029410905 > -51.54963970424304
WOLFE (weak): th(187148.86177126726)=-51.54963970424304; dx=-1.2849194139636158E-6 evalInputDelta=0.26291272722737347
New Minimum: -51.54963970424304 > -53.51359026691728
END: th(1684339.7559414054)=-53.51359026691728; dx=-1.1394124547562222E-6 evalInputDelta=2.2268632899016083
Fitness changed from -51.28672697701567 to -53.51359026691728
Iteration 2 complete. Error: -53.51359026691728 Total: 26.3633; Orientation: 0.0633; Line Search: 23.5412
<a id="p-5"></a>Iteration 2
<a id="p-4"></a>![Iteration 2](etc/71227c3d-319e-408e-bc55-8680106aa047.jpg)
Adding measurement 530463a0 to history. Total: 2
LBFGS Accumulation History: 3 points
th(0)=-53.51359026691728;dx=-1.1439548474894133E-6
New Minimum: -53.51359026691728 > -57.261152162040325
END: th(3628800.0000000005)=-57.261152162040325; dx=-8.370152169279987E-7 evalInputDelta=3.7475618951230487
Fitness changed from -53.51359026691728 to -57.261152162040325
Iteration 3 complete. Error: -57.261152162040325 Total: 7.3133; Orientation: 0.0608; Line Search: 4.4010
<a id="p-7"></a>Iteration 3
<a id="p-6"></a>![Iteration 3](etc/dc0e8332-b3f5-475d-b1f1-99cb13c5f8ad.jpg)
Adding measurement 3bb9bd69 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.527e+04, gradient 8.909e-04, dot -0.882; [3ea59440-0c00-49b5-b700-e25f8db5778c = 1.000/1.000e+00]
Orientation rejected. Popping history element from -57.261152162040325, -53.51359026691728, -51.28672697701567, -51.2867218615437
LBFGS Accumulation History: 3 points
Removed measurement 3bb9bd69 to history. Total: 3
th(0)=-57.261152162040325;dx=-7.909748783665824E-7
New Minimum: -57.261152162040325 > -62.76010313222154
END: th(7818012.603187701)=-62.76010313222154; dx=-5.374532793580736E-7 evalInputDelta=5.4989509701812125
Fitness changed from -57.261152162040325 to -62.76010313222154
Iteration 4 complete. Error: -62.76010313222154 Total: 8.4774; Orientation: 1.2233; Line Search: 4.5411
<a id="p-9"></a>Iteration 4
<a id="p-8"></a>![Iteration 4](etc/d477709f-6021-4754-9c7f-a78ef6756496.jpg)
Adding measurement 20e078ad to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.366e+04, gradient 7.525e-04, dot -0.758; [3ea59440-0c00-49b5-b700-e25f8db5778c = 1.000/1.000e+00]
Orientation rejected. Popping history element from -62.76010313222154, -53.51359026691728, -51.28672697701567, -51.2867218615437
LBFGS Accumulation History: 3 points
Removed measurement 20e078ad to history. Total: 3
th(0)=-62.76010313222154;dx=-5.650990664731248E-7
New Minimum: -62.76010313222154 > -70.34688477764563
END: th(1.6843397559414055E7)=-70.34688477764563; dx=-3.1478373645168134E-7 evalInputDelta=7.5867816454240895
Fitness changed from -62.76010313222154 to -70.34688477764563
Iteration 5 complete. Error: -70.34688477764563 Total: 8.1820; Orientation: 1.0906; Line Search: 4.4907
<a id="p-11"></a>Iteration 5
<a id="p-10"></a>![Iteration 5](etc/407bdcac-9f3e-4448-960d-9c4eed81a04b.jpg)
Adding measurement 4ba50a4c to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.828e+04, gradient 6.909e-04, dot -0.604; [3ea59440-0c00-49b5-b700-e25f8db5778c = 1.000/1.000e+00]
Orientation rejected. Popping history element from -70.34688477764563, -53.51359026691728, -51.28672697701567, -51.2867218615437
LBFGS Accumulation History: 3 points
Removed measurement 4ba50a4c to history. Total: 3
th(0)=-70.34688477764563;dx=-4.7582777331095047E-7
New Minimum: -70.34688477764563 > -78.09777880122675
END: th(3.628800000000001E7)=-78.09777880122675; dx=-7.268120292007346E-8 evalInputDelta=7.750894023581125
Fitness changed from -70.34688477764563 to -78.09777880122675
Iteration 6 complete. Error: -78.09777880122675 Total: 8.1816; Orientation: 1.0659; Line Search: 4.5236
Adding measurement 59e5b7cf to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.835e+04, gradient 8.743e-04, dot -0.270; [3ea59440-0c00-49b5-b700-e25f8db5778c = 1.000/1.000e+00]
Orientation rejected. Popping history element from -78.09777880122675, -53.51359026691728, -51.28672697701567, -51.2867218615437
LBFGS Accumulation History: 3 points
Removed measurement 59e5b7cf to history. Total: 3
th(0)=-78.09777880122675;dx=-7.638129377838305E-7
Armijo: th(7.818012603187701E7)=-70.76144568608453; dx=1.638574687983822E-7 evalInputDelta=-7.336333115142224
New Minimum: -78.09777880122675 > -80.1208706998538
WOLF (strong): th(3.9090063015938506E7)=-80.1208706998538; dx=2.2242522215171008E-7 evalInputDelta=2.023091898627044
New Minimum: -80.1208706998538 > -84.24026462295522
END: th(1.3030021005312836E7)=-84.24026462295522; dx=-1.4189447946135344E-7 evalInputDelta=6.142485821728471
Fitness changed from -78.09777880122675 to -84.24026462295522
Iteration 7 complete. Error: -84.24026462295522 Total: 12.5190; Orientation: 1.0375; Line Search: 9.0440
Adding measurement 3b3fb202 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.212e+04, gradient 6.138e-04, dot -0.507; [3ea59440-0c00-49b5-b700-e25f8db5778c = 1.000/1.000e+00]
Orientation rejected. Popping history element from -84.24026462295522, -53.51359026691728, -51.28672697701567, -51.2867218615437
LBFGS Accumulation History: 3 points
Removed measurement 3b3fb202 to history. Total: 3
th(0)=-84.24026462295522;dx=-3.7628842036730396E-7
New Minimum: -84.24026462295522 > -88.84622390120221
END: th(2.8072329265690096E7)=-88.84622390120221; dx=-1.2710755538225045E-8 evalInputDelta=4.605959278246985
Fitness changed from -84.24026462295522 to -88.84622390120221
Iteration 8 complete. Error: -88.84622390120221 Total: 8.1246; Orientation: 1.0961; Line Search: 4.5544
Adding measurement 141b5e65 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.358e+04, gradient 7.766e-04, dot -0.333; [3ea59440-0c00-49b5-b700-e25f8db5778c = 1.000/1.000e+00]
Orientation rejected. Popping history element from -88.84622390120221, -53.51359026691728, -51.28672697701567, -51.2867218615437
LBFGS Accumulation History: 3 points
Removed measurement 141b5e65 to history. Total: 3
th(0)=-88.84622390120221;dx=-6.017770452663837E-7
Armijo: th(6.048000000000002E7)=-83.43517172541391; dx=1.7557894835611156E-7 evalInputDelta=-5.411052175788299
New Minimum: -88.84622390120221 > -90.7835454773622
WOLF (strong): th(3.024000000000001E7)=-90.7835454773622; dx=2.0448192102913668E-7 evalInputDelta=1.937321576159988
New Minimum: -90.7835454773622 > -93.03046449057966
END: th(1.0080000000000004E7)=-93.03046449057966; dx=-1.7454667857477774E-7 evalInputDelta=4.184240589377453
Fitness changed from -88.84622390120221 to -93.03046449057966
Iteration 9 complete. Error: -93.03046449057966 Total: 12.3838; Orientation: 1.0698; Line Search: 8.9003
Adding measurement 1788a0ec to history. Total: 3
Rejected: LBFGS Orientation magnitude: 4.559e+04, gradient 4.947e-04, dot -0.599; [3ea59440-0c00-49b5-b700-e25f8db5778c = 1.000/1.000e+00]
Orientation rejected. Popping history element from -93.03046449057966, -53.51359026691728, -51.28672697701567, -51.2867218615437
LBFGS Accumulation History: 3 points
Removed measurement 1788a0ec to history. Total: 3
th(0)=-93.03046449057966;dx=-2.4427563544704727E-7
New Minimum: -93.03046449057966 > -96.72855019182377
END: th(2.1716701675521396E7)=-96.72855019182377; dx=-1.1239882431358671E-7 evalInputDelta=3.6980857012441106
Fitness changed from -93.03046449057966 to -96.72855019182377
Iteration 10 complete. Error: -96.72855019182377 Total: 7.7754; Orientation: 1.0966; Line Search: 4.5736
<a id="p-13"></a>Iteration 10
<a id="p-12"></a>![Iteration 10](etc/625ce65d-989e-47fa-a6ad-c30f968bde74.jpg)
Final threshold in iteration 11: -96.72855019182377 (> -Infinity) after 111.142s (< 5400.000s)

Returns

    -96.72855019182377