Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Professional Discussion / Trying to understand Artificial Neural Networks

Author
Message
TheComet
18
Years of Service
User Offline
Joined: 18th Oct 2007
Location: I`m under ur bridge eating ur goatz.
Posted: 21st Nov 2011 13:32 Edited at: 21st Nov 2011 13:32
Hey everyone


I'm trying to understand how ANNs work so I can ultimately use it in my game for smart enemies. So far I've learnt how a network is structured, and I've learnt various output formulas:



What I don't understand is how unsupervised learning works... What exactly do I need to calculate and when?

TheComet

Jaeg
20
Years of Service
User Offline
Joined: 16th Mar 2006
Location: Indiana
Posted: 21st Nov 2011 16:37 Edited at: 21st Nov 2011 16:48
Also look into genetic algorithms. A lot of times this is how they create learning networks. What survives the longest or gets the most kills can be considers "optimal" within that generation. Then creating a new generation based of the previous success with some random mutations and repeat.

Are you using structs for the neuron data?


Edit -
Also if on the local level (In which I mean the entity on which the neural net operates) you can set up an award system so when something is being achieved (like it just killed the player or something smaller like having found the player) reenforced the connections that allowed it to come to that decision or action. This will make it more prone to doing the same action again.

Edit edit -
Nice article
Link

Go ahead. Walk into Mordor.

Ball State University - Computer Science Major
Pincho Paxton
23
Years of Service
User Offline
Joined: 8th Dec 2002
Location:
Posted: 21st Nov 2011 17:16 Edited at: 21st Nov 2011 17:25
Quote: "What I don't understand is how unsupervised learning works... What exactly do I need to calculate and when?

TheComet"


I've worked on 2 neural network programs in DBPro. The unsupervised learning works by storing a score for each progress made. So for example you want something to walk from A to B. The nearer they get to B without falling over the higher the bot scores. You then store the movements used to reach this highest score. Then you randomize one aspect of this best score to see if it scores higher next time around. So you might have a leg made from joints, and you just alter one joint to see if that helps to reach the goal at B. If a score is worse, you just ignore it, and put the joint back to doing what it did best. The main thing is to figure out what you will allow the Neural Network to randomize. My Neural Network was not 100% successful because I didn't allow it to turn to a very acute angle. It is your choices that really allow the AI to achieve its goal.

Here is my video...
http://www.youtube.com/watch?v=zBtt-iVqvFE

RiiDii
21
Years of Service
User Offline
Joined: 20th Jan 2005
Location: Inatincan
Posted: 23rd Nov 2011 09:44 Edited at: 23rd Nov 2011 09:48
I did this a long while ago and haven't touched it for a while, so I am a bit rusty. But take a look at this post and if you have questions, I will try to answer.

http://forum.thegamecreators.com/?m=forum_view&t=110156&b=8

The primary difference in supervised learning versus unsupervised learning is whether someone is involved in guiding the ANN's education. The first learning algorithm was a program to play checkers, in which the programmer played against the computer enough times until the program could beat the programmer. This is an example of supervised learning. Alternatively, if the programmer had set the checkers program against a clone of itself, that would be unsupervised learning.

Supervised Learning
Benefits: The programmer / user can guide the AI to a desired behavior.
Disadvantages: Supervised learning is very slow, and often the results are very narrow (limited). For example, the checkers program may have learned to beat the programer at checkers, it may not have known how to win against anyone else (even a novice).

Unsupervised Learning
Benefits: The AI learns much faster. If unpredictable results are desired, then unsupervised learning can achieve this goal.
Disadvantages: The wide spectrum of possible outcomes of unsupervised learning may result in undesired behaviors, or behaviors that are not widely recognized as "intelligent." Unsupervised learning can also get stuck in a loop or it can go down a dead-end evolutionary path.

Login to post a reply

Server time is: 2026-07-10 09:32:24
Your offset time is: 2026-07-10 09:32:24