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 298.41 seconds (6.124 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: 586342701538200
Reset training subject: 586348663004100
Adding measurement 21d8ee4a to history. Total: 0
LBFGS Accumulation History: 1 points
Constructing line search parameters: GD+Trust
th(0)=-38.5552336155375;dx=-2.073003965137333E-6
New Minimum: -38.5552336155375 > -38.55523557447384
END: th(2.154434690031884)=-38.55523557447384; dx=-1.8055469064966544E-6 evalInputDelta=1.958936337587147E-6
Fitness changed from -38.5552336155375 to -38.55523557447384
Iteration 1 complete. Error: -38.55523557447384 Total: 29.5939; Orientation: 0.1440; Line Search: 11.6836
<a id="p-3"></a>Iteration 1
<a id="p-2"></a>![Iteration 1](etc/15545365-08a6-4944-9864-854cb91338ec.jpg)
Adding measurement 1cdcbcaf to history. Total: 1
LBFGS Accumulation History: 2 points
th(0)=-38.55523557447384;dx=-1.8034741015507069E-6
New Minimum: -38.55523557447384 > -38.55524536915405
WOLFE (weak): th(4.641588833612779)=-38.55524536915405; dx=-1.802117545883746E-6 evalInputDelta=9.794680210006845E-6
New Minimum: -38.55524536915405 > -38.555255163831774
WOLFE (weak): th(9.283177667225559)=-38.555255163831774; dx=-1.801012251189848E-6 evalInputDelta=1.9589357933114115E-5
New Minimum: -38.555255163831774 > -38.55529238358442
WOLFE (weak): th(27.849533001676676)=-38.55529238358442; dx=-1.7997770674483422E-6 evalInputDelta=5.6809110581923505E-5
New Minimum: -38.55529238358442 > -38.555456933639256
WOLFE (weak): th(111.3981320067067)=-38.555456933639256; dx=-1.799257495952549E-6 evalInputDelta=2.2135916541543565E-4
New Minimum: -38.555456933639256 > -38.55633648095166
WOLFE (weak): th(556.9906600335335)=-38.55633648095166; dx=-1.7995418282035916E-6 evalInputDelta=0.0011009064778164657
New Minimum: -38.55633648095166 > -38.56183074888709
WOLFE (weak): th(3341.9439602012008)=-38.56183074888709; dx=-1.7987234195059848E-6 evalInputDelta=0.006595174413249083
New Minimum: -38.56183074888709 > -38.601358566463084
WOLFE (weak): th(23393.607721408407)=-38.601358566463084; dx=-1.7967669266921767E-6 evalInputDelta=0.04612299198924319
New Minimum: -38.601358566463084 > -38.921975103209824
WOLFE (weak): th(187148.86177126726)=-38.921975103209824; dx=-1.7736395280828907E-6 evalInputDelta=0.3667395287359838
New Minimum: -38.921975103209824 > -41.633599227320985
END: th(1684339.7559414054)=-41.633599227320985; dx=-1.5224123498768877E-6 evalInputDelta=3.0783636528471447
Fitness changed from -38.55523557447384 to -41.633599227320985
Iteration 2 complete. Error: -41.633599227320985 Total: 68.7350; Orientation: 0.1356; Line Search: 61.2175
<a id="p-5"></a>Iteration 2
<a id="p-4"></a>![Iteration 2](etc/630a2619-3e7b-48be-8290-c2a39774d2c1.jpg)
Adding measurement 461f32ec to history. Total: 2
LBFGS Accumulation History: 3 points
th(0)=-41.633599227320985;dx=-1.4499713397020408E-6
New Minimum: -41.633599227320985 > -46.345539643052255
END: th(3628800.0000000005)=-46.345539643052255; dx=-9.550399164512476E-7 evalInputDelta=4.71194041573127
Fitness changed from -41.633599227320985 to -46.345539643052255
Iteration 3 complete. Error: -46.345539643052255 Total: 19.0860; Orientation: 0.1220; Line Search: 11.8403
<a id="p-7"></a>Iteration 3
<a id="p-6"></a>![Iteration 3](etc/6a4b3392-0c0b-4bd1-9c4d-7e177121743c.jpg)
Adding measurement 11005d9e to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.013e+04, gradient 9.636e-04, dot -0.798; [3e319437-dbc4-415f-897a-098fa61f3842 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -46.345539643052255, -41.633599227320985, -38.55523557447384, -38.5552336155375
LBFGS Accumulation History: 3 points
Removed measurement 11005d9e to history. Total: 3
th(0)=-46.345539643052255;dx=-9.264010662786133E-7
New Minimum: -46.345539643052255 > -52.27393933016904
END: th(7818012.603187701)=-52.27393933016904; dx=-4.907967062809841E-7 evalInputDelta=5.928399687116787
Fitness changed from -46.345539643052255 to -52.27393933016904
Iteration 4 complete. Error: -52.27393933016904 Total: 22.0950; Orientation: 2.5717; Line Search: 12.2660
<a id="p-9"></a>Iteration 4
<a id="p-8"></a>![Iteration 4](etc/f7c3440e-80b6-4fe4-b7be-71b87be0ad77.jpg)
Adding measurement 7688c258 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 9.353e+03, gradient 8.437e-04, dot -0.586; [3e319437-dbc4-415f-897a-098fa61f3842 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -52.27393933016904, -41.633599227320985, -38.55523557447384, -38.5552336155375
LBFGS Accumulation History: 3 points
Removed measurement 7688c258 to history. Total: 3
th(0)=-52.27393933016904;dx=-7.116102902261992E-7
New Minimum: -52.27393933016904 > -58.188104522016005
END: th(1.6843397559414055E7)=-58.188104522016005; dx=-1.2526903568710778E-7 evalInputDelta=5.914165191846962
Fitness changed from -52.27393933016904 to -58.188104522016005
Iteration 5 complete. Error: -58.188104522016005 Total: 22.0030; Orientation: 2.5112; Line Search: 12.2487
<a id="p-11"></a>Iteration 5
<a id="p-10"></a>![Iteration 5](etc/5fbbe3f1-6f46-4c2e-a99a-0b268aa7f474.jpg)
Adding measurement 4d7eea6c to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.112e+04, gradient 1.021e-03, dot -0.317; [3e319437-dbc4-415f-897a-098fa61f3842 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -58.188104522016005, -41.633599227320985, -38.55523557447384, -38.5552336155375
LBFGS Accumulation History: 3 points
Removed measurement 4d7eea6c to history. Total: 3
th(0)=-58.188104522016005;dx=-1.041164733779752E-6
Armijo: th(3.628800000000001E7)=-55.08802913505481; dx=2.4806969522108955E-7 evalInputDelta=-3.100075386961194
New Minimum: -58.188104522016005 > -61.29565595778077
WOLF (strong): th(1.8144000000000004E7)=-61.29565595778077; dx=2.9467489513776673E-7 evalInputDelta=3.107551435764762
New Minimum: -61.29565595778077 > -62.846801890712044
END: th(6048000.000000001)=-62.846801890712044; dx=-3.354423116629717E-7 evalInputDelta=4.658697368696039
Fitness changed from -58.188104522016005 to -62.846801890712044
Iteration 6 complete. Error: -62.846801890712044 Total: 34.9701; Orientation: 2.4843; Line Search: 25.2774
Adding measurement 1b42c1fc to history. Total: 3
Rejected: LBFGS Orientation magnitude: 1.966e+04, gradient 7.142e-04, dot -0.601; [3e319437-dbc4-415f-897a-098fa61f3842 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -62.846801890712044, -41.633599227320985, -38.55523557447384, -38.5552336155375
LBFGS Accumulation History: 3 points
Removed measurement 1b42c1fc to history. Total: 3
th(0)=-62.846801890712044;dx=-5.088732773751353E-7
New Minimum: -62.846801890712044 > -67.01118971127127
END: th(1.3030021005312836E7)=-67.01118971127127; dx=-1.4348305686099063E-7 evalInputDelta=4.164387820559227
Fitness changed from -62.846801890712044 to -67.01118971127127
Iteration 7 complete. Error: -67.01118971127127 Total: 20.8452; Orientation: 2.4196; Line Search: 12.3743
Adding measurement 7737f811 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.495e+04, gradient 8.333e-04, dot -0.474; [3e319437-dbc4-415f-897a-098fa61f3842 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -67.01118971127127, -41.633599227320985, -38.55523557447384, -38.5552336155375
LBFGS Accumulation History: 3 points
Removed measurement 7737f811 to history. Total: 3
th(0)=-67.01118971127127;dx=-6.927632713981826E-7
New Minimum: -67.01118971127127 > -67.14482332122252
WOLF (strong): th(2.8072329265690096E7)=-67.14482332122252; dx=1.7964964754620656E-7 evalInputDelta=0.1336336099512465
New Minimum: -67.14482332122252 > -69.93117694756475
WOLF (strong): th(1.4036164632845048E7)=-69.93117694756475; dx=1.0652809454274275E-7 evalInputDelta=2.91998723629348
END: th(4678721.544281683)=-69.60381839163846; dx=-3.1303057889334095E-7 evalInputDelta=2.5926286803671843
Fitness changed from -67.01118971127127 to -69.93117694756475
Iteration 8 complete. Error: -69.93117694756475 Total: 32.7328; Orientation: 2.4185; Line Search: 24.5739
Adding measurement 50e15b04 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.647e+04, gradient 9.586e-04, dot -0.355; [3e319437-dbc4-415f-897a-098fa61f3842 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -69.93117694756475, -41.633599227320985, -38.55523557447384, -38.5552336155375
LBFGS Accumulation History: 3 points
Removed measurement 50e15b04 to history. Total: 3
th(0)=-69.93117694756475;dx=-9.188376334344258E-7
New Minimum: -69.93117694756475 > -74.90172676443335
WOLF (strong): th(1.0080000000000004E7)=-74.90172676443335; dx=5.1868749180728266E-8 evalInputDelta=4.970549816868598
END: th(5040000.000000002)=-73.86739790928605; dx=-4.7244298368560465E-7 evalInputDelta=3.936220961721304
Fitness changed from -69.93117694756475 to -74.90172676443335
Iteration 9 complete. Error: -74.90172676443335 Total: 26.7875; Orientation: 2.4284; Line Search: 18.4150
Adding measurement 4dba3a66 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.823e+04, gradient 7.494e-04, dot -0.507; [3e319437-dbc4-415f-897a-098fa61f3842 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -74.90172676443335, -41.633599227320985, -38.55523557447384, -38.5552336155375
LBFGS Accumulation History: 3 points
Removed measurement 4dba3a66 to history. Total: 3
th(0)=-74.90172676443335;dx=-5.594450078530562E-7
New Minimum: -74.90172676443335 > -78.00049419061553
END: th(1.0858350837760698E7)=-78.00049419061553; dx=-1.518091775372747E-8 evalInputDelta=3.098767426182178
Fitness changed from -74.90172676443335 to -78.00049419061553
Iteration 10 complete. Error: -78.00049419061553 Total: 20.3917; Orientation: 2.4065; Line Search: 12.0650
<a id="p-13"></a>Iteration 10
<a id="p-12"></a>![Iteration 10](etc/fa095150-247b-436d-816a-7f8120fbfcc1.jpg)
Final threshold in iteration 11: -78.00049419061553 (> -Infinity) after 298.412s (< 5400.000s)

Returns

    -78.00049419061553