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 150.57 seconds (2.623 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: 460088824455500
Reset training subject: 460091715693900
Adding measurement 7d0fec42 to history. Total: 0
LBFGS Accumulation History: 1 points
Constructing line search parameters: GD+Trust
th(0)=-94.66876103932259;dx=-1.5037285474383636E-5
New Minimum: -94.66876103932259 > -94.66879625588611
WOLFE (weak): th(2.154434690031884)=-94.66879625588611; dx=-1.4855471876547757E-5 evalInputDelta=3.5216563517792565E-5
New Minimum: -94.66879625588611 > -94.66882853772448
WOLFE (weak): th(4.308869380063768)=-94.66882853772448; dx=-1.4859041629037605E-5 evalInputDelta=6.749840189002043E-5
New Minimum: -94.66882853772448 > -94.66896646909173
WOLFE (weak): th(12.926608140191302)=-94.66896646909173; dx=-1.4859007834688984E-5 evalInputDelta=2.054297691387319E-4
New Minimum: -94.66896646909173 > -94.66957101696896
WOLFE (weak): th(51.70643256076521)=-94.66957101696896; dx=-1.4817798858822115E-5 evalInputDelta=8.099776463694752E-4
New Minimum: -94.66957101696896 > -94.6727991199011
WOLFE (weak): th(258.53216280382605)=-94.6727991199011; dx=-1.4823675748749299E-5 evalInputDelta=0.004038080578510517
New Minimum: -94.6727991199011 > -94.69297520394541
WOLFE (weak): th(1551.1929768229563)=-94.69297520394541; dx=-1.4856230868694233E-5 evalInputDelta=0.024214164622819112
New Minimum: -94.69297520394541 > -94.83807763116978
WOLFE (weak): th(10858.350837760694)=-94.83807763116978; dx=-1.4797701645330416E-5 evalInputDelta=0.16931659184719194
New Minimum: -94.83807763116978 > -96.01278974905031
WOLFE (weak): th(86866.80670208555)=-96.01278974905031; dx=-1.4592251083293993E-5 evalInputDelta=1.3440287097277235
New Minimum: -96.01278974905031 > -105.79741443181183
END: th(781801.26031877)=-105.79741443181183; dx=-1.2189690138781573E-5 evalInputDelta=11.128653392489241
Fitness changed from -94.66876103932259 to -105.79741443181183
Iteration 1 complete. Error: -105.79741443181183 Total: 36.8165; Orientation: 0.1062; Line Search: 28.5344
<a id="p-3"></a>Iteration 1
<a id="p-2"></a>![Iteration 1](etc/4c423bbd-ecd3-4405-b65c-e728afc42ed0.jpg)
Adding measurement 6673b2a6 to history. Total: 1
LBFGS Accumulation History: 2 points
th(0)=-105.79741443181183;dx=-1.1531591882524338E-5
New Minimum: -105.79741443181183 > -122.53474594610584
END: th(1684339.7559414052)=-122.53474594610584; dx=-7.603091602352108E-6 evalInputDelta=16.737331514294013
Fitness changed from -105.79741443181183 to -122.53474594610584
Iteration 2 complete. Error: -122.53474594610584 Total: 9.3070; Orientation: 0.1054; Line Search: 5.6785
<a id="p-5"></a>Iteration 2
<a id="p-4"></a>![Iteration 2](etc/239e6c4a-6d2e-4383-89ff-a08cdbd8091d.jpg)
Adding measurement 2720c8d8 to history. Total: 2
LBFGS Accumulation History: 3 points
th(0)=-122.53474594610584;dx=-7.757467289198932E-6
New Minimum: -122.53474594610584 > -143.32852226941455
END: th(3628800.0)=-143.32852226941455; dx=-3.769496514865045E-6 evalInputDelta=20.793776323308705
Fitness changed from -122.53474594610584 to -143.32852226941455
Iteration 3 complete. Error: -143.32852226941455 Total: 9.2957; Orientation: 0.1038; Line Search: 5.8724
<a id="p-7"></a>Iteration 3
<a id="p-6"></a>![Iteration 3](etc/35e3bbb2-d3f4-4598-85f2-187ecd5ac61b.jpg)
Adding measurement 62c51124 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.757e+04, gradient 2.445e-03, dot -0.680; [711dcbb4-bdc5-4379-8c63-ba2c004e55cc = 1.000/1.000e+00]
Orientation rejected. Popping history element from -143.32852226941455, -122.53474594610584, -105.79741443181183, -94.66876103932259
LBFGS Accumulation History: 3 points
Removed measurement 62c51124 to history. Total: 3
th(0)=-143.32852226941455;dx=-5.975760469039908E-6
New Minimum: -143.32852226941455 > -163.1295118432496
END: th(7818012.6031877)=-163.1295118432496; dx=-7.374884251633674E-7 evalInputDelta=19.80098957383504
Fitness changed from -143.32852226941455 to -163.1295118432496
Iteration 4 complete. Error: -163.1295118432496 Total: 11.1074; Orientation: 1.9031; Line Search: 5.9049
<a id="p-9"></a>Iteration 4
<a id="p-8"></a>![Iteration 4](etc/41ec7f81-2fd2-4ef5-87b4-873bd1ec89b3.jpg)
Adding measurement 2323db97 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.363e+04, gradient 2.778e-03, dot -0.440; [711dcbb4-bdc5-4379-8c63-ba2c004e55cc = 1.000/1.000e+00]
Orientation rejected. Popping history element from -163.1295118432496, -122.53474594610584, -105.79741443181183, -94.66876103932259
LBFGS Accumulation History: 3 points
Removed measurement 2323db97 to history. Total: 3
th(0)=-163.1295118432496;dx=-7.706641750751199E-6
Armijo: th(1.684339755941405E7)=-153.77323510497516; dx=2.2081956927975433E-6 evalInputDelta=-9.356276738274431
New Minimum: -163.1295118432496 > -175.64011996258935
WOLF (strong): th(8421698.779707026)=-175.64011996258935; dx=1.7991890428910106E-6 evalInputDelta=12.510608119339764
New Minimum: -175.64011996258935 > -178.1888346794296
END: th(2807232.9265690087)=-178.1888346794296; dx=-2.690895782882442E-6 evalInputDelta=15.059322836180002
Fitness changed from -163.1295118432496 to -178.1888346794296
Iteration 5 complete. Error: -178.1888346794296 Total: 16.8369; Orientation: 1.8666; Line Search: 11.4369
<a id="p-11"></a>Iteration 5
<a id="p-10"></a>![Iteration 5](etc/4539ad33-61db-40c2-9edc-d6eab6ba58cd.jpg)
Adding measurement 2ea97334 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.346e+04, gradient 1.908e-03, dot -0.610; [711dcbb4-bdc5-4379-8c63-ba2c004e55cc = 1.000/1.000e+00]
Orientation rejected. Popping history element from -178.1888346794296, -122.53474594610584, -105.79741443181183, -94.66876103932259
LBFGS Accumulation History: 3 points
Removed measurement 2ea97334 to history. Total: 3
th(0)=-178.1888346794296;dx=-3.6398017048334204E-6
New Minimum: -178.1888346794296 > -190.86319036333543
END: th(6048000.0)=-190.86319036333543; dx=-1.0066430363807026E-6 evalInputDelta=12.674355683905844
Fitness changed from -178.1888346794296 to -190.86319036333543
Iteration 6 complete. Error: -190.86319036333543 Total: 11.1616; Orientation: 1.7760; Line Search: 5.7833
Adding measurement 6a8c2738 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.757e+04, gradient 2.054e-03, dot -0.522; [711dcbb4-bdc5-4379-8c63-ba2c004e55cc = 1.000/1.000e+00]
Orientation rejected. Popping history element from -190.86319036333543, -122.53474594610584, -105.79741443181183, -94.66876103932259
LBFGS Accumulation History: 3 points
Removed measurement 6a8c2738 to history. Total: 3
th(0)=-190.86319036333543;dx=-4.214066620048603E-6
New Minimum: -190.86319036333543 > -192.8207354668819
WOLF (strong): th(1.3030021005312834E7)=-192.8207354668819; dx=1.1474093038132463E-6 evalInputDelta=1.9575451035464653
New Minimum: -192.8207354668819 > -199.7791975854709
WOLF (strong): th(6515010.502656417)=-199.7791975854709; dx=3.06327367974586E-7 evalInputDelta=8.916007222135477
END: th(2171670.167552139)=-197.7155856370999; dx=-1.998195700318337E-6 evalInputDelta=6.852395273764472
Fitness changed from -190.86319036333543 to -199.7791975854709
Iteration 7 complete. Error: -199.7791975854709 Total: 15.7589; Orientation: 1.9001; Line Search: 11.2835
Adding measurement 507b8148 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.817e+04, gradient 2.264e-03, dot -0.433; [711dcbb4-bdc5-4379-8c63-ba2c004e55cc = 1.000/1.000e+00]
Orientation rejected. Popping history element from -199.7791975854709, -122.53474594610584, -105.79741443181183, -94.66876103932259
LBFGS Accumulation History: 3 points
Removed measurement 507b8148 to history. Total: 3
th(0)=-199.7791975854709;dx=-5.106878969517474E-6
New Minimum: -199.7791975854709 > -211.40426231765187
WOLF (strong): th(4678721.544281682)=-211.40426231765187; dx=3.171125922209372E-8 evalInputDelta=11.62506473218096
END: th(2339360.772140841)=-208.94799311585982; dx=-2.418874690441103E-6 evalInputDelta=9.168795530388905
Fitness changed from -199.7791975854709 to -211.40426231765187
Iteration 8 complete. Error: -211.40426231765187 Total: 13.2491; Orientation: 1.7014; Line Search: 8.8232
Adding measurement 1e9afbd4 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 4.395e+04, gradient 1.810e-03, dot -0.514; [711dcbb4-bdc5-4379-8c63-ba2c004e55cc = 1.000/1.000e+00]
Orientation rejected. Popping history element from -211.40426231765187, -122.53474594610584, -105.79741443181183, -94.66876103932259
LBFGS Accumulation History: 3 points
Removed measurement 1e9afbd4 to history. Total: 3
th(0)=-211.40426231765187;dx=-3.274556415338314E-6
New Minimum: -211.40426231765187 > -219.13169804771255
END: th(5040000.000000001)=-219.13169804771255; dx=-1.6688382267043496E-7 evalInputDelta=7.727435730060677
Fitness changed from -211.40426231765187 to -219.13169804771255
Iteration 9 complete. Error: -219.13169804771255 Total: 10.4056; Orientation: 1.8270; Line Search: 5.8358
Adding measurement 423abfb6 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 4.677e+04, gradient 1.770e-03, dot -0.503; [711dcbb4-bdc5-4379-8c63-ba2c004e55cc = 1.000/1.000e+00]
Orientation rejected. Popping history element from -219.13169804771255, -122.53474594610584, -105.79741443181183, -94.66876103932259
LBFGS Accumulation History: 3 points
Removed measurement 423abfb6 to history. Total: 3
th(0)=-219.13169804771255;dx=-3.1225875613018818E-6
New Minimum: -219.13169804771255 > -220.79566408341387
WOLF (strong): th(1.0858350837760696E7)=-220.79566408341387; dx=1.1127714795286629E-6 evalInputDelta=1.6639660357013213
New Minimum: -220.79566408341387 > -225.94456116049903
WOLF (strong): th(5429175.418880348)=-225.94456116049903; dx=1.490933926703117E-7 evalInputDelta=6.812863112786488
END: th(1809725.1396267826)=-223.6779824727173; dx=-1.8064377113132466E-6 evalInputDelta=4.546284425004757
Fitness changed from -219.13169804771255 to -225.94456116049903
Iteration 10 complete. Error: -225.94456116049903 Total: 16.0426; Orientation: 1.7763; Line Search: 11.4775
<a id="p-13"></a>Iteration 10
<a id="p-12"></a>![Iteration 10](etc/ae87cc29-fd7e-4bea-8c6d-f3bb54307eda.jpg)
Final threshold in iteration 11: -225.94456116049903 (> -Infinity) after 150.572s (< 5400.000s)

Returns

    -225.94456116049903