SFML community forums

General => SFML projects => Topic started by: lolz123 on November 02, 2013, 10:02:00 pm

Title: NNBrain SFML Demo
Post by: lolz123 on November 02, 2013, 10:02:00 pm
(http://i1218.photobucket.com/albums/dd401/222464/NNBrainLogo-1.png)

Hello all,

I would like to present to you my new self-learning AI library, NNBrain!
It includes a demo that uses SFML to visualize the cart-pole balancing problem.

Right now, there are 3 agents (AI's), 1 of which is well know while the other two are more original in implementation:


All agents are applicable to both continuous and discrete task domains.

Feel free to use it in a game or other application to hopefully get some awesome self-improving AI!

Download Link: https://sourceforge.net/projects/nnbrain/?source=navbar (https://sourceforge.net/projects/nnbrain/?source=navbar)

(http://i1218.photobucket.com/albums/dd401/222464/PoleBalancingImage.png)
Title: Re: NNBrain SFML Demo
Post by: StormWingDelta on November 03, 2013, 03:13:28 pm
Hmm wonder if I could make this work for my card game I'm working on? Would be funny to have a learning AI in a card game that all I'd have to do is add the new cards to the list and let it figure out how to use them.  :P
Title: Re: NNBrain SFML Demo
Post by: lolz123 on November 03, 2013, 03:46:25 pm
@StormWingDelta: Sounds like a cool idea! I would be very interested to see how well the AI performs in such an application. You could train it against itself at first, and then when it is good enough, it can learn from the players it is playing against.

Also: A manual for how to use the system is coming very soon!
Title: Re: NNBrain SFML Demo
Post by: StormWingDelta on November 03, 2013, 04:06:18 pm
Getting a strange error trying to run your example app for this.   ???


Did you compile in codeblocks or visual studio? Might help me find the reason for the error since I got both VS 2010 and 2012 installed but haven't gotten codeblocks up again.


Yep, you're not the only one wanting to see what'll happen.  Could be funny too. Might translate it into java and/or C# once I get path a writer's block on my field setup for the player fields.  ;D
Title: Re: NNBrain SFML Demo
Post by: lolz123 on November 03, 2013, 04:18:14 pm
@StormWingDelta: You need the Visual Studio 2013 runtime environment, available here: http://www.microsoft.com/en-us/download/details.aspx?id=40784 (http://www.microsoft.com/en-us/download/details.aspx?id=40784) (Get the x64 version)

EDIT: I uploaded a better version of the pole balancing demo where the parameters were tuned to prevent the AI from sticking to the walls.
Title: Re: NNBrain SFML Demo
Post by: StormWingDelta on February 17, 2015, 12:44:05 am
Finally found this again.  Now to test it.  I know that it would be rather interesting to use in a card game that's for sure.  The idea would be to hook up the AI to the same controls the player would use and just sit back and watch the carnage as the players go from whining about it being too stupid to whining about it being too smart.  8)


Meantime I've got several more ideas floating around.  I might try and port this over to some of my other favorite languages and also I got a RTS it might fit perfectly in for the side AI.  Watching the things it might do in that would be fun. :) 


Also this project still being worked on?  ???
Title: Re: NNBrain SFML Demo
Post by: lolz123 on February 17, 2015, 03:52:09 am
This project has been overtaken by AILib (lame name I know): http://en.sfml-dev.org/forums/index.php?topic=16389.0 (http://en.sfml-dev.org/forums/index.php?topic=16389.0)

That project will (hopefully) soon be overtaken by CHTMGPU, my latest AI for very large scale applications (like millions of inputs/outputs). But this will still take some time.

If you just want to get something up and running without much effort and still have a powerful AI, I recommend starting with FERL (Free Energy Reinforcement Learner) https://github.com/222464/AILib/blob/master/Source/deep/FERL.h (https://github.com/222464/AILib/blob/master/Source/deep/FERL.h). Here is an example of it running after about 30 seconds of learning time: https://www.youtube.com/watch?v=TyqSw-RCtFs (https://www.youtube.com/watch?v=TyqSw-RCtFs). It is also the most feature complete, with saving/loading from files, genetic operators, partial observability handling, and continuous inputs/outputs.