public void Learn(BackgroundWorker learnProcess, int trials, decimal learn, decimal discount, decimal explore) { try { startTime = DateTime.Now; currentProcess = new QProcess(learnProcess); WriteOutput("Learning now...", true); Learn(trials, learn, discount, explore); if (master != null) { master.UpdateGuiMetrics(true); } if (isRunning) { WriteOutput("I am done learning.", true); } else { WriteOutput("Learning aborted.", true); } WriteOutput("Runtime: " + (DateTime.Now - startTime), true); } catch (Exception e) { WriteOutput("Error: " + e, true); } }
public void Learn(BackgroundWorker learnProcess, int trials, decimal learn, decimal discount, decimal explore) { try { startTime = DateTime.Now; currentProcess = new QProcess(learnProcess); WriteOutput("Learning now...", true); Learn(trials, learn, discount, explore); if (master != null) master.UpdateGuiMetrics(true); if (isRunning) WriteOutput("I am done learning.", true); else WriteOutput("Learning aborted.", true); WriteOutput("Runtime: " + (DateTime.Now - startTime), true); } catch (Exception e) { WriteOutput("Error: " + e, true); } }