private void btnLoad_Click(object sender, EventArgs e) { this.SuspendLayout(); lavirint.ucitajLavirint(); this.inicijalizacijaPretrage(); qTable = new QTable(LEARNING_RATE, GAMMA, EPSILON); this.ResumeLayout(false); displayPanel1.Refresh(); }
public void runEpisode(QTable qTable) { Node observation = Main.pocetniNode; while (true) { Action action = qTable.chooseAction(observation); Node nextObservation = observation.getPossibleActions()[action]; paint(nextObservation); double reward = nextObservation.getReward(); qTable.learn(observation, action, reward, nextObservation); if (nextObservation.isTerminalNode()) { break; } observation = nextObservation; } }
public Main() { InitializeComponent(); inicijalizacijaPretrage(); qTable = new QTable(LEARNING_RATE, GAMMA, EPSILON); }