Code from BasicOptimizer.scala:75 executed in 39.20 seconds (3.814 gc):

    val lineSearchInstance: LineSearchStrategy = lineSearchFactory
    IterativeTrainer.wrap(trainable)
      .setOrientation(orientation())
      .setMonitor(new TrainingMonitor() {
        override def clear(): Unit = trainingMonitor.clear()
  
        override def log(msg: String): Unit = trainingMonitor.log(msg)
  
        override def onStepFail(currentPoint: Step): Boolean = {
          BasicOptimizer.this.onStepFail(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, currentPoint)
          trainingMonitor.onStepComplete(currentPoint)
          super.onStepComplete(currentPoint)
        }
      })
      .setTimeout(trainingMinutes, TimeUnit.MINUTES)
      .setMaxIterations(trainingIterations)
      .setLineSearchFactory((_: CharSequence) => lineSearchInstance)
      .setTerminateThreshold(java.lang.Double.NEGATIVE_INFINITY)
      .runAndFree
      .asInstanceOf[lang.Double]

Logging:

    Reset training subject: 929163181091
    Reset training subject: 930230717750
    Adding measurement 2c49e475 to history. Total: 0
    LBFGS Accumulation History: 1 points
    Constructing line search parameters: GD+Trust
    th(0)=1.4726151387360045;dx=-8.608395632300426E-10
    Armijo: th(2.154434690031884)=1.4726151387360045; dx=-8.608395597144383E-10 evalInputDelta=0.0
    Armijo: th(1.077217345015942)=1.4726151387360045; dx=-8.608395615105683E-10 evalInputDelta=0.0
    Armijo: th(0.3590724483386473)=1.4726151387360045; dx=-8.608395626401402E-10 evalInputDelta=0.0
    WOLFE (weak): th(0.08976811208466183)=1.4726151387360045; dx=-8.608395630979007E-10 evalInputDelta=0.0
    Armijo: th(0.22442028021165458)=1.4726151387360045; dx=-8.608395628724998E-10 evalInputDelta=0.0
    Armijo: th(0.1570941961481582)=1.4726151387360045; dx=-8.608395629825163E-10 evalInputDelta=0.0
    WOLFE (weak): th(0.12343115411641001)=1.4726151387360045; dx=-8.608395630387107E-10 evalInputDelta=0.0
    Armijo: th(0.1402626751322841)=1.4726151387360045; dx=-8.608395630146525E-10 evalInputDelta=0.0
    Armijo: th(0.13184691462434706)=1.4726151387360045; dx=-8.608395630272758E-10 evalInputDelta=0.0
    WOLFE (weak): th(0.12763903437037855)=1.4726151387360045; dx=-8.608395630317646E-10 evalInputDelta=0.0
    Armijo: th(0.1297429744973628)=1.4726151387360045; dx=-8.608395630279359E-10 evalInputDelta=0.0
    WOLFE (weak): th(0.12869100443387066)=1.4726151387360045; dx=-8.608395630307197E-10 evalInputDelta=0.0
    Armijo: th(0.12921698946561672)=1.4726151387360045; dx=-8.608395630294611E-10 evalInputDelta=0.0
    WOLFE (weak): th(0.1289539969497437)=1.4726151387360045; dx=-8.608395630299728E-10 evalInputDelta=0.0
    Armijo: th(0.1290854932076802)=1.4726151387360045; dx=-8.608395630294611E-10 evalInputDelta=0.0
    Armijo: th(0.12901974507871194)=1.4726151387360045; dx=-8.608395630294611E-10 evalInputDelta=0.0
    Armijo: th(0.12898687101422782)=1.4726151387360045; dx=-8.608395630294611E-10 evalInputDelta=0.0
    Armijo: th(0.12897043398198577)=1.4726151387360045; dx=-8.608395630294611E-10 evalInputDelta=0.0
    WOLFE (weak): th(0.128962

...skipping 1294 bytes...

    4726151387360045; dx=-8.608395618795294E-10 evalInputDelta=0.0
    Armijo: th(0.6946431757956064)=1.4726151387360045; dx=-8.608395621151107E-10 evalInputDelta=0.0
    WOLFE (weak): th(0.6251788582160458)=1.4726151387360045; dx=-8.608395622316682E-10 evalInputDelta=0.0
    Armijo: th(0.6599110170058261)=1.4726151387360045; dx=-8.608395621766147E-10 evalInputDelta=0.0
    WOLFE (weak): th(0.642544937610936)=1.4726151387360045; dx=-8.608395622126989E-10 evalInputDelta=0.0
    Armijo: th(0.6512279773083811)=1.4726151387360045; dx=-8.608395622054343E-10 evalInputDelta=0.0
    Armijo: th(0.6468864574596586)=1.4726151387360045; dx=-8.608395622100157E-10 evalInputDelta=0.0
    WOLFE (weak): th(0.6447156975352972)=1.4726151387360045; dx=-8.608395622137552E-10 evalInputDelta=0.0
    Armijo: th(0.6458010774974778)=1.4726151387360045; dx=-8.608395622121335E-10 evalInputDelta=0.0
    Armijo: th(0.6452583875163875)=1.4726151387360045; dx=-8.608395622131433E-10 evalInputDelta=0.0
    Armijo: th(0.6449870425258424)=1.4726151387360045; dx=-8.608395622131433E-10 evalInputDelta=0.0
    Armijo: th(0.6448513700305698)=1.4726151387360045; dx=-8.608395622137552E-10 evalInputDelta=0.0
    WOLFE (weak): th(0.6447835337829335)=1.4726151387360045; dx=-8.608395622137552E-10 evalInputDelta=0.0
    WOLFE (weak): th(0.6448174519067517)=1.4726151387360045; dx=-8.608395622137552E-10 evalInputDelta=0.0
    WOLFE (weak): th(0.6448344109686608)=1.4726151387360045; dx=-8.608395622137552E-10 evalInputDelta=0.0
    WOLFE (weak): th(0.6448428904996153)=1.4726151387360045; dx=-8.608395622137552E-10 evalInputDelta=0.0
    WOLFE (weak): th(0.6448471302650925)=1.4726151387360045; dx=-8.608395622137552E-10 evalInputDelta=0.0
    mu ~= nu (0.6448471302650925): th(0.0)=1.4726151387360045
    Fitness changed from 1.4726151387360045 to 1.4726151387360045
    Static Iteration Total: 18.1226; Orientation: 0.0675; Line Search: 17.0013
    Iteration 2 failed. Error: 1.4726151387360045
    Previous Error: 0.0 -> 1.4726151387360045
    Optimization terminated 2
    Final threshold in iteration 2: 1.4726151387360045 (> -Infinity) after 39.196s (< 3600.000s)
    

Returns:

    1.4726151387360045