Added: 3 years ago
From: badmephisto
Views: 17,324
Sort by time | Sort by thread (beta)

Link to this comment:

Share to:
see all

All Comments (115)

Sign In or Sign Up now to post a comment!
  • is it possible to see the source code? I'm new at AI and would really like a little peek inside this

  • This is still cool after a year of discovering this vid lmao

  • Awesome!

  • ICH VILLE

  • awesom song

  • Random awesomeness of the day!! I would love to take a look at source code for this if you would like to share. I found a Tetris AI written in Pascal on sourceforge, but I'm more familiar with python so i would love to learn from this if possible. thanks for distracting me from the tedium at work!

  • Is this speed up or in real-time?

  • @PeopleR2sensitive its fo' real

  • Wish I could play like that. Coach was right, it's not my circumstances, I just suck ;-;

  • does this operate off of a simple possible placement evaluation scale?

    Where placements are weighed, and then the highest value place is chosen.

    The weight would likely be based on height, and snugness.

  • @TheReasonWhyGuy yep, from experience I came up with a bunch of metrics for whats good and whats bad about placing anything at any spot. The "learning" here is just finding what weights give best performance. It's not nuclear science indeed :) still works pretty well, but I'm sure it's possible to do much better.

  • cool !!!!!!!!!!!!!

  • wow... this thing plays tetris better than i can o.o

  • wouldn't the optimal be building a thin tower leaving like 6 rows on the top? that way the pieces don't have to fall as far and you can do it faster without speeding the game up.

  • well, it's much better then i am!

  • The joy of giving life to a computer with a Rubik's Cube in one hand... yay!

  • Great. Face this against bastard tetris (a tetris make which calculates the worst piece you can get on your next move). See who the victor is.

  • Has a tetris AI been invented that works perfectly or beats humans? On youtube some people do just as well as this AI.

    The tetris wiki says not much has been done for a tetris AI. I'm talking about if the computer doesn't cheat by looking at the seed in advance.

  • Beats in what sense? If you mean raw score then yes there are Tetris algorithms that can make 100's of MILLIONS of lines - surely far more than any human could make. Though of course as the speed increases humans find it hard to place the pieces accurately - which becomes the limiting factor. Computers don't suffer this problem of course.

    If you are talking multiplayer Tetris then I guess people still have the edge. None of the algorithms so far are very aggressive, they play slow and steady.

  • Yes, I meant by raw score :(

    Pretty soon they'll start beating us in RTS's fairly...

    I just wasn't sure if a computer could beat a human because its algorithm wasn't smart enough. Speed was never the issue.

  • Well the thing is that the algorithm might not be as smart as playing but still win out as Tetris is more of an endurance and reflexes game at the higher levels. So the algorithms will always have the edge.

    As for RTS games - I don't think we will see a RTS bot that can match pro level humans for quite some time. Current RTS algorithms rely on lots of 'build scripts' and do very little high level planning (in the AI sense). I can't see this changing soon as such an AI won't be fun to play!

  • Cool!

    Looks like the program looks for the correct 'terrain' on the surface of the blocks to find the correct position for the next block. That's why there was a huge stack at 1:06. That's usually how I play the game anyway.

    It would be really cool if someone made a program for an RTS game that would play an almost perfect game. Something to do, I guess, when I get more into programming.

    5/5

  • RTS AI is far, far more complex than AI for pretty much any other game. Mathematically, there aren't any algorithms that can iterate through every possibility (much like in chess or Go); there are just too many possibilities. We can't even come up with perfect algorithms for some simple scheduling problems. This is the reason that approximation algorithms are so prevalent.

    Possibilities in RTS games are like chess to the power of 20.

  • True, it would be extremely difficult, but it is definitely possible. They already have AI for some RTS games, but they tend to be inefficient.

    My goal would be to make the AI incredibly efficient with resources and units and scout out enemy weaknesses to make the most of the units at hand.

  • There are a bunch of really hard problems that need to be overcome. How do you decide what units/buildings the AI will build? Take a game like Supreme Commander: there are so many possibilities that it's hard to imagine a computer succeeding without having a general "strategy".

    Indeed, I think the best way to go about AI for RTS games is to have the AI analyze the situation and develop a rough 'plan'. You then work towards efficiency of resources and unit orders (etc. etc.). Just an idea.

  • I think the Starcraft 2 AI is supposed to counter by scouting. There are some rather 'intelligent' starcraft 1 AI's made by fans already.

    But right now ~ no AI can beat a human fairly in an rts like Starcraft or SupCom without the use of reaction speed abuse.

  • AI is an awesome area for computing. I wish I can go AI when I finish my bachelor.

  • does it have look ahead (does it know the pieces in advance) or does it just go on the fly?

    i noticed situations where it could have gotten 4 rows if the look ahead was better

  • im pretty sure the pieces were set to a random veriable

  • yes but some tetris programs set the order of pieces 10 pieces in advance so there isn't slowdown. if the AI took advantage of knowing the queue order, it would be way more successful

  • really nice

  • does it learn a it goes.

  • Woah, that's asking a lot!

    Just program in evolution.

    It isn't impossible (as various videos will show you) but I would imagine that it wouldn't be the worlds easiest programming feat.

  • Dude, watch the Terminator.

  • how can i put this on my computer?

  • i like the techno tetris music

  • thats awsom wot AI did u use??

  • one he made

  • haha yeh i ment wot method like neural net, swarw etc

  • he programmed the AI, that's the whole point of the video

  • yeh mate i get that, i study AI as part of my course at uni and i woz wondering wot category of AI it is (like any programming theres loads)

  • oh, sorry, : P

  • haha np man :)

  • Cool program , I love that song too.

  • So how was this done exactly, or in less than 500 words :) I'm writing a neuroevolving strategy for a checkers game in python as well. I have to say though that i'm rewriting most of it in c now, because all the bottlenecks where simply due to the inefficiencies of python. Now that I see that you got really great results also using an evolution strategy, its making me reconsider that decision ...

  • i'm faster than this ai lol

    but thats on a version where you can do spins and slides etc

  • Very nice work on the AI tetris... I hope you make more programming videos and Rubik's Cube vids too...

  • LOL at the 2x2s on the left side around 1:06

  • lol that made me laugh too

  • i thought it was funny too :) but I do believe it to be the optimal thing to do in that case, to just stack them up out of the way. So i was happy that the AI thought so as well

  • Yet i always thought that neural networks learn from more likely situations and being offered the same block over and over again is exceptional in tetris. So maybe it's not the best way, or maybe it should stop stacking at an ideal moment? Just makes me think lol.

  • It was pretty cool XD

  • that AI beasting it up

  • COOL TRACK

  • Nice... That AI is better than I am at Tetris...

    It also has better look-ahead than I don on my cube X3

  • that's BECAUSE it's an AI; a good AI will always beat human opponents

  • ai will beat human? in the immediate but non for long, we're both self learning machines

  • awesome remix music!

  • Why does it put all the 2*2 blocks on top of eachother? (I don't think this is a bad tactic, but aren't there situations in which it can be placed somewhere better (assuming I didn't miss it due to the speed of this video))

  • you should try posting some python tutorials - id be interested to learn it, they should have something like this at the end showing an example of something that can be achieved with it :)

  • omg i agree this guy turned me into a python addict exept i cant do crap with it!!!!

  • Hey Badmephisto, I was wondering if you would lend me some advice.. Ive been wanting to get into programing for some time now and I dont know where to start or how to start? Ive searched the web but haven't had any good luck. Maybe you can help me? I would appreciate it..

    Thnx 4 your time

  • Try doing it using neural networks. I have a working example that does 7000 lines on average, and can reach up to 45 000.

  • I don't understand -- what do you use as training data?

  • you work recursively. The idea is, that you generate a descend policy by guessing the weights, then you use that policy and play 2000-3000 games. You use those games as your sampling data, to generate a new policy, and so forth. Try googling "tetris constraint sampling"

  • it sounds like the approach i'm taking here. guess good weights, but then i have a genetic algorithm that does the seeking. When it comes down to it, aren't they equivalent? What do you think would be the pro's of using the NN approach?

  • well, if you are using a set of basis functions and weights, to evaluate your actions, then you are practically dong neuro dynamic programming. The difference is how you derive the weights. I did the constraint sampling approach, which gave me a policy that does 7000 on average, but there is also the Cross Entropy method, that can give results of 100 000 lines on average (assuming you are willing to train it for a month).

  • holy shit i didnt understand a word of tht...will one of you guys make a python tutorial but not too basic...make it like "how to make a simple game" and find links to a good functions database pleeeeease i love u

  • I need an AI for a First Person shooter, anyone mind giving me tips on how to start? The FPS is Return to Castle Wolfenstien.

  • you don't understand this.

  • What would be the point? There's nearly no logic in a FPS. Things like this consist of 2 things: Logic and probability. But the 2nd is actually a part of the first, to be exact...

  • And FPS " IAs " already exists... they are called bots ^^

  • "Unfortunately I don't possess enough computing resources to have it learn more and fine tune the parameters as much as I'd like"

    Start a distributed network of Tetris AIs!

  • very cool!

  • Is there any chance you will upload this for download? I'd like to have a glance at it, maybe get it to almost invincible (I have a mad machine here ;))

  • machene spec wont affect AI preformance as the effect of a crap machene on the game and the ai are preportional

  • Well, the description says he doesnt have enough computing power, and I think I do, so thats why I asked

  • computing resoruces, not preformance. he means time to do it in, a faster computer will not affect the intelligence, of an AI system

  • aaaah, k, although I would still like to have it ^^

  • well fair enough me too :)

  • Yeah, it's sort of a Turing thing. You'll always evolve a better AI, but a faster computer could evolve it sooner.

  • Sweet!

    Artificial Intelligence is awesome!

  • I wish you somehow get all the computing resources to improve this up to invincible.

  • how did you make it?

  • great work, i tried getting into python but seem to just do better with noob scripting languages like actionscript 1/2/3 JS and such.

    Good music choices by the way, I would love to see you "techno" playlist.

  • How come AS3/2/1 are noob scripting languages? I havent found myself doing flash code in C++.

  • Well I find C++ and Python a little more complex then scripting. Now I have done some crazy things with actionscript (made a full RPG actually that was some huge file) but I think those are more easily understood and learned.

  • Hey wahts this song? what other techno do you have badMephisto? Your speedcubing is awesome BTW.

  • You didnt read the description did you..?

  • WHAT THE FU

    dge?

    I never got subscriber notification of your previous 2 videos (this and PLLs Rec.)

    Eh, well, get ready to see a viewer count increase, and probably more of my obsessive comments.

  • yay

  • Very cool :-)

  • It was @omfgmouse

  • soooo cool

  • Why don't you make it always go for 4 lines at once?

  • because thats not a good strategy if you want to survive longest

  • A "Tetris"?

  • Can't wait to see it go really fast :D

  • it goes really really fast... i just made it go slow so that you can see whats happening.

  • Does this 'simply' work out the best place for each piece when it 'appears' or plan for future pieces as well? Also, what does it learn from a single move?

  • it does plan ahead for the next piece. It doesnt learn anything from a single move. It learns something from how many lines it made before it died. Then it adjusts its strategy and tries to play differently, and sees how that goes.

  • How does a AI "evolve". I am just getting into programming and I think that is brilliant! Thnx for the cubing vids too...My averages would be at a minute still with the LBL...now they are nearing sub 20

  • that no ai it just a program!

  • Impressive

  • I enjoy watching this as much your cubing video's. It's always nice to see AI capable of beating the human mind at something. Nicely done!

  • Ohh...what is this song called? It is very familiar, but I can´t remember the name. Please someone: Tell me!

  • Tetris by...

    Either Zam, 2am, 2pm, or something of the like (three letters long, but i've only glanced at the author so it is wrong on my iPod.)

  • @joeman1986

    korobeiniki

  • pretty awsome...on tetris for teh DS i got 803 lines once...

  • I always stacked up and hoped for a 4piece bar so I could get a lot of points, worked pretty good.

  • how did it eventually end?

  • I love the song!

  • Impressive indeed.

  • Very impressive.

  • Are these Tetrix Mixes actually downloadable songs? and if they are where can i find them?

  • yea they are , you could probably find them on limewire easily ^-^

  • Nice bot o.o

    The actual pro players are pretty close to that speed though damn lol.

    They just can't move the pieces to the right and left as fast.

  • Good solve!

  • It probably didn't take him long...

    Quick question: How exactly did you write this in Python? You must've had something like Pygame as the interpreter to do this.

  • So you basically made a bot?

  • wow!

    thats awesome!

    how long did it take you do write?

  • Cool vid!

Loading...
0 / 00Unsaved Playlist Return to active list
    1. Your queue is empty. Add videos to your queue using this button:
      or sign in to load a different list.
    Loading...Loading...Saving...
    • Clear all videos from this list
    • Learn more