If u have trained a neural network for a task, how do u store the information it has learn e.g. to play a game. Do u store the weights for each state,corresponding to the optimal move for each state?

i can get it to learn but dont know how to store the learnt data ! many thanks!

NomadRock
—
2005-02-16T01:31:04Z —
#2

The weights contain all the learned information, this is all you need to store. For games it depends on what you want to do. Generally training a new neural net for each type of move is not a good thing, because at that point you are basically going to have to "solve" the game and kill the usefullness of a general ai.

For example if you wanted to make a neural net for a game of checkers, you would have the input be the entire state of the board meaning the position of all the checkers (and possible kings) and your output would be which piece to move (and where). You could just play the game with a friend and tell your net that the move you choose is the best one, each time, and have it learn on your moves. Then you can feed your net any gamestate (eventually) and it should make a move that you would have made in that situation.

Obviously the better training data you give it, the better the net is at playing the game.

i use 2 input units to represent each square (1,0 = x)(0,1 = o)(0,0 = -) and use the target values of 0.9 to place the 'o' in that square and 0.1 to not place the 'o' in that square!

however, i have 2091 training data (states) and after 100 iterations (epochs) of the data, the net only correctyl classifies some states! does that mean i should let it learn for long ie. 10,000 epochs or should i increase the number of hidden layers? however there are issues with prolog and stack overflows occur due to memory problems os more neurons would cause problems! just wanna know if increasing the training iterations will finally make the data converge so the net plays the correct move always!

many thanks!

rego
—
2005-02-23T09:31:04Z —
#5

oh btw the game is tic-tac-toe

NomadRock
—
2005-02-27T03:15:11Z —
#6

Definately you should run a great deal of iterations. You might find, however that 3 hidden neurons just isn't enough and you want to increase that to 5 or whatever. This is mostly trial and error AI.