Log inRegister an accountBrowse CSDbHelp & documentationFacts & StatisticsThe forumsAvailable RSS-feeds on CSDbSupport CSDb Commodore 64 Scene Database
You are not logged in - nap
CSDb User Forums


Forums > C64 Coding > AI on C64
2009-09-29 18:25
Hermit

Registered: May 2008
Posts: 208
AI on C64

Were there any Artifical Intelligence experiments on C64?

-A neuron is not really more than a body which sums more weighted inputs into an output..(in real life sigma-sum)
-A neural network appears when these are connected to each other, in most cases by careful arrangement.
-The neurons can learn by modifying their (originally randomized) input-weights to reach the wished (reference) value at their output.
-The learning process takes some iterations depending on the strength (multiplier) of the feedback of actual error delta (wished reference for actual inputs -minus- the actual output). The optimal multiplier seems between 0.2..0.3 from my experiments.

A neuron's pins, datas (weights) and connections can be modelled in assembly easily. A byte can be a value of input-weight, and the weighted inputs can be added (and divided) together to a byte, which will represent the output of the neuron when the neuron was simulated once in a step. Then a connection list can route this output to other neuron's input.

See my example on my homepage (neuron-DAC2.xls).

http://hermitsoft.uw.hu/pcprog/pcprog.html

It's an Excel file that shows iterations and learning curve of a Neuron. We teach it to be a special Neuron - be it a DAC (Digital-to-Analog converter).
After several iterations the error gets smaller-and-smaller, then our Neuron learns to be a DAC, the needed information is 'stored' in its weights.

No concept yet, but C64 may be able to simulate simple neural networks at 1MHz, which could be useful in games, and even in demos, or who knows, even in 'random' composing for music editors..

Maybe you're interested..maybe not.
Have a good exploration.

Hermit Software Hungary
 
... 14 posts hidden. Click here to view all posts....
 
2009-10-01 07:45
Frantic

Registered: Mar 2003
Posts: 1648
I have done some stuff using GP ("Genetic Programming") on the C64. All of it unreleased so far though. One of those productions may actually be finished in a not too distant future (or not).

(A not very important sidenote: Brain activity is not completely reducible to firing patterns, to be precise. You also have, according to some, gamma-waves, and stuff like that.. Anyway, this is not of high relevance for the issue of implementing some sort of AI on the C64 of course... :)
2009-10-01 07:59
enthusi

Registered: May 2004
Posts: 677
Actually I think most (all?) C64 games do well with pseudo AI.
As in a set of rules that interact which each other to create complexity.
Not Even Human - Inhumane Edition
Does that and despite the fact that it had to be rather limited due to rastertime I was quite happy with the result.
A few more extra functions and it would be better than any real, theoretically satisfying AI I think...
2009-10-01 08:21
Hermit

Registered: May 2008
Posts: 208
Hi Mates

I tried Eliza, it seems a cleverly programmed thing.

Though in my opinion, the good approach to AI is the Neuron-based AI.

The difference between the 'pre-programmed' and Neuron-based
AI is the learning power. And the Neurons are working truly paralell not in serial after each other..so with today's serially working computers the Neuron models aren't working as fast as the ones realized on e.g. paralell-working FPGAs..

The researches which try modelling AI with Neurons is to be improved a lot as the laboratories couldn't reach that much number of neurons (on FPGAs, etc) with that much connections as even the simplest brains..they reached the complexity of worms or bugs (do not laugh, please :)

So I'm far from trying to modell AI on brain's level, that programs try (as e.g. Eliza). Instead the well constructed neural networks could solve a lot of problems after learning. The learning is what 'programmed' AI solutions are mainly missing, and I think they'll be less used in the future.

Some good examples can be found on net about what today's neural networks can solve..e.g. speech recognition, finding out the language-type from source code, decide if an applicant is good for a job, etc..

On C64 at 1MHz processor speed only limited numbers of neurons can be modelled, but if there's a good construction in their connection, they can solve problems after learning phase, that none of the 'pre-programmed' AI programs can solve..and this need much less system resources than using predefined values for decisions..

To make my (maybe complicated) explanation clearer, I'll show some links that could point what I'm saying with preferring neural networks.

http://en.wikipedia.org/wiki/Neural_network

http://portal.acm.org/citation.cfm?id=206913.206999

http://cslu.cse.ogi.edu/tutordemos/nnet_recog/recog.html

http://www.neuralnetworks.it/neuralsignature.asp

http://www.advancedsourcecode.com/netassembler.asp

etc,etc, I think the Neural modelling of biology is the future in AI..

Hermit Software Hungary
2009-10-01 09:43
Wile Coyote
Account closed

Registered: Mar 2004
Posts: 646
I have always assumed Chess games have a level of AI, as they take some time to make their moves, at least on 8-bit machines.

The whole AI thing is interesting.
2009-10-01 10:30
enthusi

Registered: May 2004
Posts: 677
"AI" is very ill defined, at least not used very precisely.
Chess games usually dont have AI as it was mentioned here.
Same with practically all games so far.
Not 'learning' the proper way.
Check out connect-4-games. You will never win against a good one, yet it has ONE rule how to play only.
I remember this whole discussion when Command&Conquer came out. I friend of mine wrote part of his thesis about the 'AI' of the Harvester, hehe.
2009-10-01 10:54
Martin Piper

Registered: Nov 2007
Posts: 722
Regarding AI and learning. The robots in Berzerk Redux have a little bit of AI, they try to avoid walking into walls and will look for a direction around a wall if they are blocked.
Simple enough of course.

Regarding learning:
One idea I did have was to note which areas of the screen robots were killed. Then the remaining robots would prefer to avoid those areas. I never did put it in though as there are not that many robots on each screen to make it a worthwhile check.
2009-10-01 12:12
Hermit

Registered: May 2008
Posts: 208
Yeah, here is a good reason to model AI with neurons: If you equip the robots with (simulated) neural networked brain, you don't have to program their behaviour, they'll realize the danger themselves on the dangerous areas after a while if their life is in danger. That is the true learning. We can say the teaching is a 'programming', but more universal and maybe easier than writing a code for every behaviour.

Just imagine: every living entity in the world was born without any knowledge, with a pure brain, with randomized weights in their neurons, clear synaptic connections. Like a formatted winchester...
There are physical circumstances, like energy, food, health, perceptions, that the entity have to keep above a level to stay alive. The nervous system & receptors are designed (maybe into DNS through evolution), but the other informations come during the real life, and not stored in the brain by default.. (excepted instincts, which are maybe also programmed by DNS).
I've read in a medical book that babies even can't see at the time they are born (only just some shades, but not edges, details)..
I also heard that from a scientist, only 3 connected neurons are enough to keep a body in balance, and only 6 neurons were enough in an experiment that were connected to photo-sensors, and they could keep a stick balanced with electromagnetic field...after they were taught for it.

The robots in games could be taught by showing them what output to do for what input (e.g. seeing, noise, etc), which is right or wrong step.. Then their information after teaching them beforehand could be stored into virtual pre-taught brains, and they would be ready to fight when the game is released.

You can make experiments with tools:
http://www.mathworks.com/products/neuralnet/
http://download.cnet.com/Neural-Network-Designer/3000-2069_4-10..
etc..

Some knowledge base..
http://hagan.okstate.edu/nnd.html
http://ai-depot.com/articles/evolutionary-neural-networks-desig..

Hermit Software Hungary
2009-10-01 13:59
Wile Coyote
Account closed

Registered: Mar 2004
Posts: 646
Can you imagine if Chess games had proper AI. It would pose a number of advantages / disadvantages for the player. For every game played, the computer should become better, as being a Chess game, its soul purpose would be to learn and progress. Not having any emotions, it wouldn’t care it if won or lost, just so long as it got better. This could pose issues, from a game play perspective. One solution might be to throw in some pre-generated emotions: (that the player is not made aware of)

Example emotion: You feel ill
Effect: Reduces ability by 10%

Example emotion: You feel on top of the world
Effect: Increases ability by 15%

Example emotion: Your cat has been run over by a car
Effect: 100% - Shuts down, refuses to play ;D


2009-10-01 14:08
Martin Piper

Registered: Nov 2007
Posts: 722
While I agree with you the field of neural networks and learning AI is fascinating here is a story from my dim distant past. :)

I was once coding an entirely different game, 3D on the PSX. It involved aliens, face-huggers and space marines. :)

The design document specced mega intelligent aliens that would work in groups, hide from the player and then attack the player without any warning. The aliens should use AI to make use of walls and ceiling to evade detection. This was to be scary and tension building, just like the Aliens films.

This was implemented but the player feedback was that they couldn't really see the aliens to shoot them. They didn't like how the aliens would sneak up from behind and gore the player to death without any warning. :)

The problem is the aliens were too sneaky and it just wasn't fun to play against.

So all the AI was dropped in favour of scripted events where aliens would use animations to jump out of the door to the left when walking down the dark spooky corridor. Or they use animations to run as a pack along the wall then the ceiling in plain view of the player. Lots of scripted events when the player walked somewhere, or opened a door, or flipped a switch on the wall. Then once the scripted event was finished the aliens would fall onto the floor and run head first at the player.
This unintelligent system using very minimal logic was much better to play because as it turns out most players wanted to blast aliens to tiny bits with the array of weapons they had. :)
2009-10-01 14:22
chatGPZ

Registered: Dec 2001
Posts: 11386
Quote:
Can you imagine if Chess games had proper AI. It would pose a number of advantages / disadvantages for the player. For every game played, the computer should become better, as being a Chess game, its soul purpose would be to learn and progress. Not having any emotions, it wouldn’t care it if won or lost, just so long as it got better. This could pose issues, from a game play perspective.


at some point in history, chess engines used to work like this infact .... but it turned out that simple brute force table lookups work better =P you dont want to wait years until your chess engine is able to play like a 5 year old =D

and what martin said - in reality AI based on neural networks is fascinating indeed - but it isn't very useful for games.

what i would like to see however, would be a converter for pictures which is based on neural networks. there was one for the gameboy color, and it produced really great results. (unfortunately it was closed source commercial software, cant find any example pictures online)
Previous - 1 | 2 | 3 - Next
RefreshSubscribe to this thread:

You need to be logged in to post in the forum.

Search the forum:
Search   for   in  
All times are CET.
Search CSDb
Advanced
Users Online
iceout/Avatar/HF
Acidchild/Padua
Bieno/Commodore Plus
iAN CooG/HVSC
Magic/Nah-Kolor
RetroGL
Soya/Fairlight
New Design/Excess
Guests online: 166
Top Demos
1 Next Level  (9.7)
2 13:37  (9.7)
3 Mojo  (9.7)
4 Coma Light 13  (9.6)
5 Edge of Disgrace  (9.6)
6 What Is The Matrix 2  (9.6)
7 The Demo Coder  (9.6)
8 Uncensored  (9.6)
9 Comaland 100%  (9.6)
10 Wonderland XIV  (9.6)
Top onefile Demos
1 No Listen  (9.6)
2 Layers  (9.6)
3 Cubic Dream  (9.6)
4 Party Elk 2  (9.6)
5 Copper Booze  (9.6)
6 Dawnfall V1.1  (9.5)
7 Rainbow Connection  (9.5)
8 Onscreen 5k  (9.5)
9 Morph  (9.5)
10 Libertongo  (9.5)
Top Groups
1 Performers  (9.3)
2 Booze Design  (9.3)
3 Oxyron  (9.3)
4 Censor Design  (9.3)
5 Triad  (9.3)
Top Diskmag Editors
1 Magic  (9.8)
2 hedning  (9.6)
3 Jazzcat  (9.5)
4 Elwix  (9.1)
5 Remix  (9.1)

Home - Disclaimer
Copyright © No Name 2001-2024
Page generated in: 0.05 sec.