Iteration 1 Iteration 1

Iteration 2 Iteration 2

Iteration 3 Iteration 3

Iteration 4 Iteration 4

Iteration 5 Iteration 5

Iteration 10 Iteration 10

Iteration 15 Iteration 15

Iteration 20 Iteration 20

Iteration 25 Iteration 25

Iteration 30 Iteration 30

Iteration 35 Iteration 35

Iteration 40 Iteration 40

BasicOptimizer.scala:89 executed in 244.06 seconds (2.707 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: 4880201046660
Reset training subject: 4881653956738
Adding measurement f83d121 to history. Total: 0
LBFGS Accumulation History: 1 points
Constructing line search parameters: GD+Trust
th(0)=-35.83769677751639;dx=-0.01027157599802948
New Minimum: -35.83769677751639 > -35.839706628969374
WOLFE (weak): th(2.154434690031884)=-35.839706628969374; dx=-0.01030358193340792 evalInputDelta=0.0020098514529820477
New Minimum: -35.839706628969374 > -35.84174570613565
WOLFE (weak): th(4.308869380063768)=-35.84174570613565; dx=-0.010335002332452034 evalInputDelta=0.004048928619255321
New Minimum: -35.84174570613565 > -35.84990311129769
WOLFE (weak): th(12.926608140191302)=-35.84990311129769; dx=-0.010234020455080805 evalInputDelta=0.012206333781300316
New Minimum: -35.84990311129769 > -35.887647843139895
WOLFE (weak): th(51.70643256076521)=-35.887647843139895; dx=-0.010197035999841422 evalInputDelta=0.049951065623503155
New Minimum: -35.887647843139895 > -36.08445525940563
WOLFE (weak): th(258.53216280382605)=-36.08445525940563; dx=-0.009924408355249426 evalInputDelta=0.24675848188923766
New Minimum: -36.08445525940563 > -37.33831874631765
END: th(1551.1929768229563)=-37.33831874631765; dx=-0.00872966173460175 evalInputDelta=1.500621968801255
Fitness changed from -35.83769677751639 to -37.33831874631765
Iteration 1 complete. Error: -37.33831874631765 Total: 12.3993; Orientation: 0.1281; Line Search: 8.5662
<a id="p-3"></a>Iteration 1
<a id="p-2"></a>![Iteration 1](etc/b60dd098-a91f-41d1-9cce-a10ea8d1d782.jpg)
Adding measurement 53b8a0f7 to history. Total: 1
LBFGS Accumulation History: 2 points
th(0)=-37.33831874631765;dx=-0.011889453479649807
New Minimum: -37.33831874631765 > -41.015951933558206
END: th(3341.943960201201)=-41.015951933558206; dx=-0.007027398366944496 evalInputDelta=3.677633187240559
Fitness changed from -37.33831874631765 to -41.015951933558206
Iteration 2 complete. Error: -41.015951933558206 Total: 3.8778; Orientation: 0.0195; Line Search: 2.3241
<a id="p-5"></a>Iteration 2
<a id="p-4"></a>![Iteration 2](etc/6647eb7a-a806-47c0-bebb-3c487792cf59.jpg)
Adding measurement 152d2a58 to history. Total: 2
LBFGS Accumulation History: 3 points
th(0)=-41.015951933558206;dx=-0.012642583967157669
New Minimum: -41.015951933558206 > -49.22633004374075
END: th(7200.000000000001)=-49.22633004374075; dx=-0.0043827668071352984 evalInputDelta=8.210378110182546
Fitness changed from -41.015951933558206 to -49.22633004374075
Iteration 3 complete. Error: -49.22633004374075 Total: 3.7533; Orientation: 0.0204; Line Search: 2.3262
<a id="p-7"></a>Iteration 3
<a id="p-6"></a>![Iteration 3](etc/521cb653-29aa-4fa0-959d-dda863e433ea.jpg)
Adding measurement 782e0844 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 9.437e+03, gradient 1.106e-01, dot -0.292; [6250c053-49f8-466c-9cc8-5573249bbf73 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -49.22633004374075, -41.015951933558206, -37.33831874631765, -35.83769677751639
LBFGS Accumulation History: 3 points
Removed measurement 782e0844 to history. Total: 3
th(0)=-49.22633004374075;dx=-0.011930339965937545
New Minimum: -49.22633004374075 > -56.45790433763206
END: th(15511.929768229566)=-56.45790433763206; dx=-0.0018381834532946477 evalInputDelta=7.231574293891306
Fitness changed from -49.22633004374075 to -56.45790433763206
Iteration 4 complete. Error: -56.45790433763206 Total: 4.4360; Orientation: 0.5806; Line Search: 2.3325
<a id="p-9"></a>Iteration 4
<a id="p-8"></a>![Iteration 4](etc/31046abf-094b-4931-b57c-b37e279f53d5.jpg)
Adding measurement 3e4ead73 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 4.464e+03, gradient 1.025e-01, dot -0.132; [6250c053-49f8-466c-9cc8-5573249bbf73 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -56.45790433763206, -41.015951933558206, -37.33831874631765, -35.83769677751639
LBFGS Accumulation History: 3 points
Removed measurement 3e4ead73 to history. Total: 3
th(0)=-56.45790433763206;dx=-0.010353743466702803
New Minimum: -56.45790433763206 > -62.593447795556514
END: th(33419.43960201202)=-62.593447795556514; dx=-6.630070733422008E-4 evalInputDelta=6.135543457924456
Fitness changed from -56.45790433763206 to -62.593447795556514
Iteration 5 complete. Error: -62.593447795556514 Total: 4.3749; Orientation: 0.5623; Line Search: 2.4069
<a id="p-11"></a>Iteration 5
<a id="p-10"></a>![Iteration 5](etc/2e2e5a91-ba4b-4864-9118-c8cba932cc3d.jpg)
Adding measurement 7833407 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.526e+03, gradient 8.166e-02, dot -0.089; [6250c053-49f8-466c-9cc8-5573249bbf73 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -62.593447795556514, -41.015951933558206, -37.33831874631765, -35.83769677751639
LBFGS Accumulation History: 3 points
Removed measurement 7833407 to history. Total: 3
th(0)=-62.593447795556514;dx=-0.006476597844305867
Armijo: th(72000.00000000003)=-55.7512547019408; dx=-2.0191703821370634E-4 evalInputDelta=-6.8421930936157125
New Minimum: -62.593447795556514 > -63.07675708834506
END: th(36000.000000000015)=-63.07675708834506; dx=-8.739116183723158E-4 evalInputDelta=0.4833092927885474
Fitness changed from -62.593447795556514 to -63.07675708834506
Iteration 6 complete. Error: -63.07675708834506 Total: 5.3060; Orientation: 0.4888; Line Search: 3.4528
Adding measurement 6afb240d to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.242e+03, gradient 6.872e-02, dot -0.102; [6250c053-49f8-466c-9cc8-5573249bbf73 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -63.07675708834506, -41.015951933558206, -37.33831874631765, -35.83769677751639
LBFGS Accumulation History: 3 points
Removed measurement 6afb240d to history. Total: 3
th(0)=-63.07675708834506;dx=-0.004534714028855663
New Minimum: -63.07675708834506 > -69.18791799046532
END: th(77559.64884114785)=-69.18791799046532; dx=-2.6176402457485983E-4 evalInputDelta=6.111160902120261
Fitness changed from -63.07675708834506 to -69.18791799046532
Iteration 7 complete. Error: -69.18791799046532 Total: 4.0270; Orientation: 0.4916; Line Search: 2.4347
Adding measurement 687d31a9 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.330e+03, gradient 5.079e-02, dot -0.082; [6250c053-49f8-466c-9cc8-5573249bbf73 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -69.18791799046532, -41.015951933558206, -37.33831874631765, -35.83769677751639
LBFGS Accumulation History: 3 points
Removed measurement 687d31a9 to history. Total: 3
th(0)=-69.18791799046532;dx=-0.002502191510886292
New Minimum: -69.18791799046532 > -76.15784331160869
END: th(167097.19801006012)=-76.15784331160869; dx=-8.537051533342177E-5 evalInputDelta=6.969925321143364
Fitness changed from -69.18791799046532 to -76.15784331160869
Iteration 8 complete. Error: -76.15784331160869 Total: 3.9610; Orientation: 0.4885; Line Search: 2.3936
Adding measurement 28705150 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.242e+03, gradient 4.013e-02, dot -0.066; [6250c053-49f8-466c-9cc8-5573249bbf73 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -76.15784331160869, -41.015951933558206, -37.33831874631765, -35.83769677751639
LBFGS Accumulation History: 3 points
Removed measurement 28705150 to history. Total: 3
th(0)=-76.15784331160869;dx=-0.0015654624477717512
Armijo: th(360000.0000000002)=-75.29267027310978; dx=-2.4114275894369308E-5 evalInputDelta=-0.8651730384989094
New Minimum: -76.15784331160869 > -83.06666743310868
END: th(180000.0000000001)=-83.06666743310868; dx=-1.6958353526085352E-4 evalInputDelta=6.90882412149999
Fitness changed from -76.15784331160869 to -83.06666743310868
Iteration 9 complete. Error: -83.06666743310868 Total: 6.0706; Orientation: 0.6930; Line Search: 3.9679
Adding measurement 110f66e3 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 4.308e+03, gradient 3.707e-02, dot -0.092; [6250c053-49f8-466c-9cc8-5573249bbf73 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -83.06666743310868, -41.015951933558206, -37.33831874631765, -35.83769677751639
LBFGS Accumulation History: 3 points
Removed measurement 110f66e3 

...skipping 24186 bytes...

lta=-0.2820471555816084
Armijo: th(78491.71328446515)=-119.86854582646828; dx=-1.7656908903810714E-4 evalInputDelta=-0.046509203570252566
New Minimum: -119.91505503003853 > -119.9253399958639
END: th(26163.90442815505)=-119.9253399958639; dx=-1.9011782393027658E-4 evalInputDelta=0.010284965825363201
Fitness changed from -119.91505503003853 to -119.9253399958639
Iteration 36 complete. Error: -119.9253399958639 Total: 6.5753; Orientation: 0.4726; Line Search: 4.7245
Adding measurement 25fc72c6 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.438e+05, gradient 1.653e-02, dot -0.275; [6250c053-49f8-466c-9cc8-5573249bbf73 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -119.9253399958639, -41.015951933558206, -37.33831874631765, -35.83769677751639
LBFGS Accumulation History: 3 points
Removed measurement 25fc72c6 to history. Total: 3
th(0)=-119.9253399958639;dx=-2.6578227349236184E-4
New Minimum: -119.9253399958639 > -119.93738836434258
END: th(56368.42332669606)=-119.93738836434258; dx=-1.8142190977602895E-4 evalInputDelta=0.012048368478687621
Fitness changed from -119.9253399958639 to -119.93738836434258
Iteration 37 complete. Error: -119.93738836434258 Total: 4.0073; Orientation: 0.5720; Line Search: 2.2766
Adding measurement 5a4700ba to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.887e+05, gradient 1.664e-02, dot -0.278; [6250c053-49f8-466c-9cc8-5573249bbf73 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -119.93738836434258, -41.015951933558206, -37.33831874631765, -35.83769677751639
LBFGS Accumulation History: 3 points
Removed measurement 5a4700ba to history. Total: 3
th(0)=-119.93738836434258;dx=-2.73973559112467E-4
Armijo: th(121442.08663743643)=-119.70648352870634; dx=-1.6088570854304633E-4 evalInputDelta=-0.2309048356362382
New Minimum: -119.93738836434258 > -120.00341437808018
END: th(60721.04331871821)=-120.00341437808018; dx=-1.811536206849168E-4 evalInputDelta=0.06602601373759853
Fitness changed from -119.93738836434258 to -120.00341437808018
Iteration 38 complete. Error: -120.00341437808018 Total: 5.0730; Orientation: 0.4740; Line Search: 3.5124
Adding measurement 7b301349 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.110e+05, gradient 1.656e-02, dot -0.280; [6250c053-49f8-466c-9cc8-5573249bbf73 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -120.00341437808018, -41.015951933558206, -37.33831874631765, -35.83769677751639
LBFGS Accumulation History: 3 points
Removed measurement 7b301349 to history. Total: 3
th(0)=-120.00341437808018;dx=-2.6661775274368116E-4
Armijo: th(130819.52214077527)=-119.75136972863464; dx=-1.5701397309826593E-4 evalInputDelta=-0.25204464944553706
Armijo: th(65409.761070387634)=-119.88342835972189; dx=-1.7597122785206523E-4 evalInputDelta=-0.11998601835828993
New Minimum: -120.00341437808018 > -120.0040452822663
END: th(21803.25369012921)=-120.0040452822663; dx=-1.913866437727089E-4 evalInputDelta=6.309041861243259E-4
Fitness changed from -120.00341437808018 to -120.0040452822663
Iteration 39 complete. Error: -120.0040452822663 Total: 6.3073; Orientation: 0.4802; Line Search: 4.7262
Adding measurement 67367175 to history. Total: 3
Rejected: LBFGS Orientation magnitude: 3.072e+05, gradient 1.656e-02, dot -0.279; [6250c053-49f8-466c-9cc8-5573249bbf73 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -120.0040452822663, -41.015951933558206, -37.33831874631765, -35.83769677751639
LBFGS Accumulation History: 3 points
Removed measurement 67367175 to history. Total: 3
th(0)=-120.0040452822663;dx=-2.6817746160353993E-4
Armijo: th(46973.686105580055)=-119.91973355775005; dx=-1.8139476147962516E-4 evalInputDelta=-0.08431172451625457
Armijo: th(23486.843052790027)=-119.94135386351473; dx=-1.8977527178100739E-4 evalInputDelta=-0.06269141875156947
Armijo: th(7828.947684263342)=-119.99004058589645; dx=-1.9729860467272633E-4 evalInputDelta=-0.014004696369852354
Armijo: th(1957.2369210658355)=-120.00274572386923; dx=-1.9702800996724147E-4 evalInputDelta=-0.0012995583970791813
New Minimum: -120.0040452822663 > -120.0040614592531
END: th(391.4473842131671)=-120.0040614592531; dx=-1.9851628907278495E-4 evalInputDelta=1.6176986790128467E-5
Fitness changed from -120.0040452822663 to -120.0040614592531
Iteration 40 complete. Error: -120.0040614592531 Total: 8.6767; Orientation: 0.4780; Line Search: 7.0972
<a id="p-25"></a>Iteration 40
<a id="p-24"></a>![Iteration 40](etc/062977f9-8a9a-4739-a1bd-1839be54d246.jpg)
Adding measurement 108b257f to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.856e+05, gradient 1.662e-02, dot -0.275; [6250c053-49f8-466c-9cc8-5573249bbf73 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -120.0040614592531, -41.015951933558206, -37.33831874631765, -35.83769677751639
LBFGS Accumulation History: 3 points
Removed measurement 108b257f to history. Total: 3
th(0)=-120.0040614592531;dx=-2.6415919464655466E-4
Armijo: th(843.3478238710863)=-120.00252463577019; dx=-1.9501796639246623E-4 evalInputDelta=-0.0015368234829082894
Armijo: th(421.6739119355432)=-120.00339280864766; dx=-1.9916574695088226E-4 evalInputDelta=-6.686506054336405E-4
Armijo: th(140.55797064518106)=-120.00388890461481; dx=-1.9887498955222242E-4 evalInputDelta=-1.7255463828291795E-4
Armijo: th(35.139492661295264)=-120.00402371294719; dx=-1.9960586019494847E-4 evalInputDelta=-3.774630590669403E-5
Armijo: th(7.027898532259053)=-120.0040614592531; dx=-1.9993339364865573E-4 evalInputDelta=0.0
New Minimum: -120.0040614592531 > -120.00406685158156
END: th(1.1713164220431755)=-120.00406685158156; dx=-1.9686872358901618E-4 evalInputDelta=5.392328461084617E-6
Fitness changed from -120.0040614592531 to -120.00406685158156
Iteration 41 complete. Error: -120.00406685158156 Total: 9.9261; Orientation: 0.4767; Line Search: 8.0913
Adding measurement 6b102ccf to history. Total: 3
Rejected: LBFGS Orientation magnitude: 2.796e+05, gradient 1.655e-02, dot -0.276; [6250c053-49f8-466c-9cc8-5573249bbf73 = 1.000/1.000e+00]
Orientation rejected. Popping history element from -120.00406685158156, -41.015951933558206, -37.33831874631765, -35.83769677751639
LBFGS Accumulation History: 3 points
Removed measurement 6b102ccf to history. Total: 3
th(0)=-120.00406685158156;dx=-2.671153427248996E-4
Armijo: th(2.523524732653844)=-120.00405067459548; dx=-1.9752914101862516E-4 evalInputDelta=-1.617698607958573E-5
Armijo: th(1.261762366326922)=-120.00406685158156; dx=-1.9671239135520823E-4 evalInputDelta=0.0
Armijo: th(0.4205874554423073)=-120.0040614592531; dx=-1.9895767592790733E-4 evalInputDelta=-5.392328461084617E-6
Armijo: th(0.10514686386057683)=-120.0040614592531; dx=-1.9804106069649366E-4 evalInputDelta=-5.392328461084617E-6
Armijo: th(0.021029372772115366)=-120.0040614592531; dx=-1.986993160900718E-4 evalInputDelta=-5.392328461084617E-6
Armijo: th(0.0035048954620192276)=-120.0040614592531; dx=-1.9755356467981132E-4 evalInputDelta=-5.392328461084617E-6
Armijo: th(5.006993517170325E-4)=-120.0040614592531; dx=-1.9905159562716776E-4 evalInputDelta=-5.392328461084617E-6
Armijo: th(6.258741896462906E-5)=-120.00406685158156; dx=-1.98208337295993E-4 evalInputDelta=0.0
END: th(6.954157662736563E-6)=-120.00406685158156; dx=-1.9781577955328038E-4 evalInputDelta=0.0
Fitness changed from -120.00406685158156 to -120.00406685158156
Static Iteration Total: 13.2365; Orientation: 0.5094; Line Search: 11.6433
Iteration 42 failed. Error: -120.00406685158156
Previous Error: 0.0 -> -120.00406685158156
Retrying iteration 42
Reset training subject: 5119796708410
Adding measurement 4018dd1e to history. Total: 0
LBFGS Accumulation History: 1 points
th(0)=-120.00406685158156;dx=-2.689322002524865E-4
END: th(1.4982278508550698E-5)=-120.00406685158156; dx=-1.9928594197154875E-4 evalInputDelta=0.0
Fitness changed from -120.00406685158156 to -120.00406685158156
Static Iteration Total: 4.4430; Orientation: 0.0175; Line Search: 2.2887
Iteration 43 failed. Error: -120.00406685158156
Previous Error: 0.0 -> -120.00406685158156
Optimization terminated 43
Final threshold in iteration 43: -120.00406685158156 (> -Infinity) after 244.039s (< 3600.000s)

Returns

    -120.00406685158156