AI Plays HTML5 Game FastWords. Destroys All Competition with OPENCV and Python.

  Рет қаралды 27,993

ClarityCoders

ClarityCoders

2 жыл бұрын

Today we learn some new concepts in computer vision by beating games. This provides a great way to watch AI play games as well as improve your programming skills. Python and OpenCV will be our tools of choice to try and take down this high score.
github.com/ClarityCoders/Fast...
Want to chat with me and other programmers join our discord!
/ discord
#Python #OpenCV #ClarityCoders

Пікірлер: 145
@counterstrike1source
@counterstrike1source 2 жыл бұрын
Really like your content , one suggestion: add a time multiplier when you speed some footage up to let the viewer know by how much you are speeding it up.
@ClarityCoders
@ClarityCoders 2 жыл бұрын
Noted and I'll have one next time. Thanks for the suggestion and the view/comment I really appreciate it.
@rhmagalhaes
@rhmagalhaes 2 жыл бұрын
Or... You can make a program that reads the speed of regular video by calculating the pixels/second and give the speed when it accelerates... 🤣🤣🤣
@felixschndr
@felixschndr 2 жыл бұрын
I just found your channel about a week ago, instantly subbed and am happy to see your subscriber count rapidly growing. Posting the complete code is so nice. I wish more people would do this! ♥
@ClarityCoders
@ClarityCoders 2 жыл бұрын
Anytime love me or hate me it's an open book! Thanks for watching I appreciate it.
@laupetre
@laupetre 2 жыл бұрын
I've just discovered your channel today. Your approach to teaching OpenCV and Python is something I've been trying to toy with. Looking forward to watching your videos.
@ClarityCoders
@ClarityCoders 2 жыл бұрын
Awesome thanks for watching and commenting. Glad to have some new faces in the comments!
@wizard-cs2st
@wizard-cs2st 2 жыл бұрын
great editing and content, really enjoyed when you just showed the code snippet on the screen opposed to the whole script.
@ClarityCoders
@ClarityCoders 2 жыл бұрын
Thanks! It's a balancing act on how much to show honestly. Appreciate the view and comment.
@anthonybuchholz1364
@anthonybuchholz1364 2 жыл бұрын
damn bro, these vids are awesome. can tell you gonna blow up if you keep this up
@ClarityCoders
@ClarityCoders 2 жыл бұрын
Thanks I really appreciate it!
@sgt391
@sgt391 2 жыл бұрын
Learning a lot thanks to your videos! Love the content too
@ClarityCoders
@ClarityCoders 2 жыл бұрын
Awesome! Good to hear thanks for watching and commenting.
@daddyofalltrades
@daddyofalltrades 2 жыл бұрын
Wow really great stuff. Thank you ❤️
@ClarityCoders
@ClarityCoders 2 жыл бұрын
Thanks for the comment and watching.
@Foxygamer0101
@Foxygamer0101 2 жыл бұрын
Outro song: Run - Hectorino Martinez
@ClarityCoders
@ClarityCoders 2 жыл бұрын
I really like it...
@Foxygamer0101
@Foxygamer0101 2 жыл бұрын
@@ClarityCoders same ;-;
@bishop5737
@bishop5737 2 жыл бұрын
"Also had some comments that said I should stop putting my face on the videos... Well I'm gona put my face on the videos even harder now." lmao Really happy I found you, I hate you are not more popular but also not, good knowledge for just a few of us :D Keep it up!
@CasperA
@CasperA 2 жыл бұрын
You make really amazing content!
@ClarityCoders
@ClarityCoders 2 жыл бұрын
Thanks that really means a lot.
@bkalajy
@bkalajy 2 жыл бұрын
You really made AI learning more interesting than it is thx and keep it going 😁🌷
@ClarityCoders
@ClarityCoders 2 жыл бұрын
Thanks for watching and commenting. I'll keep going!
@sanfarans
@sanfarans 2 жыл бұрын
Quality content, keep it up
@ClarityCoders
@ClarityCoders 2 жыл бұрын
Thanks! These comments mean a lot.
@ashikat413
@ashikat413 2 жыл бұрын
comment for engagement vuv I love content like this, please keep uploading
@ClarityCoders
@ClarityCoders 2 жыл бұрын
Means a lot thanks for taking the time to comment! I'll keep uploading.
@mateladik8579
@mateladik8579 2 жыл бұрын
Hey Man! Real nice content. I'd like to ask you, that there is a game called,,Metin 2" which is based on the need to select, knock down stones. And from the items you received you can increase your damage and skill level to deal more damage. Millions of people play with it, and with opencv object detection it woub help people to save weeks of endless farming and grinding. As a new content video would you consider making a short help video or something to make an auto farming bot program for that game? Thank you in advance for your answer. Keep it up!
@Mr_Stork
@Mr_Stork 2 жыл бұрын
Wow nice usage of opencv :)
@ClarityCoders
@ClarityCoders 2 жыл бұрын
It's a cool library to play around with for sure! Thanks for watching / commenting.
@zhichen5620
@zhichen5620 2 жыл бұрын
Great Video! Can you make a tutorial on fastai GPU setup? It is fine to use colab for learning but it's such waste if you have a GPU but don't know how to use it.
@rajnichouhan4649
@rajnichouhan4649 2 жыл бұрын
Hi, I am new to your channel and just subscribed because you are soooo good, can you tell me which IDE do u use the most?
@rajnichouhan4649
@rajnichouhan4649 2 жыл бұрын
for python
@thekernelpanic3320
@thekernelpanic3320 2 жыл бұрын
great video! funny how we can learn python easily hacking things. thx!
@user-jl7xw1oq5v
@user-jl7xw1oq5v 2 жыл бұрын
Great video
@ClarityCoders
@ClarityCoders 2 жыл бұрын
Thanks you for watching and commenting. I'll keep doing more I think!
@unitywithneo
@unitywithneo 2 жыл бұрын
For more precision to the detection of letter, it is possible to use a grey image and only take the pure black in the yellow zone?
@ClarityCoders
@ClarityCoders 2 жыл бұрын
Would be interesting I could see that improving performance.
@enderinvader
@enderinvader 2 жыл бұрын
The Kick Ya Chop record has been topped again, broke the 3000's with 3153
@jimbotprime
@jimbotprime 2 жыл бұрын
So has yours...
@ClarityCoders
@ClarityCoders 2 жыл бұрын
Been brutal I have me my match haha
@zakyvids6566
@zakyvids6566 2 жыл бұрын
These videos are awesome can you please make a video on python crash course please
@ClarityCoders
@ClarityCoders 2 жыл бұрын
I have it on my list for a tutorial series covering a different and hopefully more fun way to learn Python. Look for it soon.
@user-ke3hh4fv3k
@user-ke3hh4fv3k 2 жыл бұрын
What was that for music at the end?
@ClarityCoders
@ClarityCoders 2 жыл бұрын
Fast and Run - Nico Staf. Thanks for watching and commenting!
@herrjohnssen
@herrjohnssen 2 жыл бұрын
Can you make a bot which plays "like a dino"? Would be interesting to see how fast it can go
@wilwilson8146
@wilwilson8146 2 жыл бұрын
That things called a tillday? I always thought it was called a curly bird.. I am so learned.
@ClarityCoders
@ClarityCoders 2 жыл бұрын
Curly Worm.
@Val_Loves_En
@Val_Loves_En 2 жыл бұрын
Nice one)
@ClarityCoders
@ClarityCoders 2 жыл бұрын
Thanks! Appreciate the comment and view!
@austinschaffer7854
@austinschaffer7854 2 жыл бұрын
Nice solution! What caused the program to fail at the end? Did it pick the wrong letter accidentally due to the acceleration of the letters? Did it accidentally grab a misspelling of the input word that it wasn't able to spellcheck?
@ClarityCoders
@ClarityCoders 2 жыл бұрын
It had an extra letter from the previous word I can't remember specifically. It was like "SONG" and the program saw "SONGS". So it waited for an S that never came and timed out.
@anmjeenpk843
@anmjeenpk843 8 ай бұрын
hey bro now you in china? chengdu ? xihua ?
@sumarto9822
@sumarto9822 2 жыл бұрын
I already try to implement Template Matching on my case, so far it is work, but i have problem when using gui, instead of using terminal to start the program, i tried to make gui and a button to start the logic. Did you have guide make gui to start the logic of the program ?
@ClarityCoders
@ClarityCoders 2 жыл бұрын
I didn't create a GUI for this program at all. I just started it from Visual Studio Code. In VSC if you have an env you need to set the interpreter before you can use the green play button.
@sumarto9822
@sumarto9822 2 жыл бұрын
@@ClarityCoders i already solved my problem haha, i am motivated to learn python when watching your videos xd
@mehregankbi
@mehregankbi 2 жыл бұрын
interesting video. do you have a beefy pc?
@ClarityCoders
@ClarityCoders 2 жыл бұрын
Nothing crazy. Low tier gaming laptop.
@limtis
@limtis 2 жыл бұрын
Tesseract is pretty slow by itself. You have the whole alphabet screenshotted, wouldn't it be faster to use template matching with some opencv (greyscale, sharpen, resize) to read the words? You'll have less errors as well, probably Edit: btw, the game probably uses NASPA word list, maybe we can do smth with it? 🤔
@limtis
@limtis 2 жыл бұрын
Also, you could've used str_var = "".join(i for i in str_var if i.isalpha()) instead of using regex, but that's a matter of preference
@ClarityCoders
@ClarityCoders 2 жыл бұрын
So slow. Only used here because it's simple and speed wasn't needed. All very good points I'll keep them in mind. Thanks for the feedback / commenting.
@pizzamark4388
@pizzamark4388 2 жыл бұрын
nice vid i liked it
@ClarityCoders
@ClarityCoders 2 жыл бұрын
Thanks Mark that really means a lot. Thanks for watching.
@hugoyaztromo3532
@hugoyaztromo3532 2 жыл бұрын
yessss OpenCV beefcake KINGGG. show em those guns and don't let them tell u to hide ur face! more tank tops in next content pls 🤤 👉👈 🥺
@ClarityCoders
@ClarityCoders 2 жыл бұрын
Hugo my man! Thanks for commenting I'll keep my face on things we make the rules here! haha
@zippyholland3001
@zippyholland3001 2 жыл бұрын
Nice 👍
@ClarityCoders
@ClarityCoders 2 жыл бұрын
Thanks Zippy I appreciate it.
@aks9545
@aks9545 2 жыл бұрын
Looks dope , also why the fuck do you have such little subs
@Sadbloodclasher
@Sadbloodclasher 2 жыл бұрын
5:45 Diagonal word
@gaming_noob8032
@gaming_noob8032 2 жыл бұрын
You should try to make an ai system that will speed run deepest sword
@ClarityCoders
@ClarityCoders 2 жыл бұрын
I'll put it on my list of games!
@adispenser
@adispenser 2 жыл бұрын
stretching it to 8 minutes I see (I'm not complaining)
@ClarityCoders
@ClarityCoders 2 жыл бұрын
I just want to spend more time with you guys. Thanks for watching and commenting I appreciate it.
@adispenser
@adispenser 2 жыл бұрын
@@ClarityCoders I appreciate your content too I have learnt a lot from it.
@inkco420
@inkco420 2 жыл бұрын
Is this an AI or simple bot?
@thejasgowda9295
@thejasgowda9295 Жыл бұрын
I nee your help
@joshuaolsen8844
@joshuaolsen8844 2 жыл бұрын
Algo
@ClarityCoders
@ClarityCoders 2 жыл бұрын
Yes. Thanks for watching / commenting.
@sasilverain
@sasilverain 2 жыл бұрын
put your face on all the things! :D :D
@ClarityCoders
@ClarityCoders 2 жыл бұрын
I put this comment on my new video out today. haha
@bean0_099
@bean0_099 2 жыл бұрын
Can you beat a game with q Learning
@ClarityCoders
@ClarityCoders 2 жыл бұрын
I am thinking within the next two videos stay tuned.
@ccuuttww
@ccuuttww 2 жыл бұрын
OPENCV terminator
@ClarityCoders
@ClarityCoders 2 жыл бұрын
That was my nickname in high school.
@freezerain
@freezerain 2 жыл бұрын
bro making screenshots of every letter? Comon you are a coder. 1) Get screenshot of the word 2) Chunk it up on the number of letters openCV detected 3) greyscale chunk, contrast it to get pure black&white colors thus recieveing only shape of the letter 4) Trimm image to get rid of background around letter 5) Success
@ClarityCoders
@ClarityCoders 2 жыл бұрын
Yeah have to figure out width of letter to chuck? Good option though.
@freezerain
@freezerain 2 жыл бұрын
@@ClarityCoders If total width is 500 pixels and openCV fount word "dog" then letter width is 500/3
@DumbFishes
@DumbFishes 2 жыл бұрын
Here is a tip do some thing more cool like creating a video game and put a lot of memes in it
@ClarityCoders
@ClarityCoders 2 жыл бұрын
That does sound really cool! Thanks for watching and commenting.
@eliebordron5599
@eliebordron5599 2 жыл бұрын
Add your face as much as you want on the videos. I mean, they're yours
@nikhildon9882
@nikhildon9882 2 жыл бұрын
Fruit ninja game python ai bot
@Zachucks
@Zachucks 2 жыл бұрын
I want to like this video, but the likes is at 666 so i can't
@ClarityCoders
@ClarityCoders 2 жыл бұрын
I respect that decision 100%. Thanks for commenting and watching!
@CallousCoder
@CallousCoder 2 жыл бұрын
Python....Amateur ;) Real programmers use OpenCV with C++ :) Python is a Millenials disease. Slow... ugly syntax and did I saw slooooow. But seriously: Template matching is a fast approach. But you can do it probably faster and so much easier. The letters are a high contrast on black. So you can easily extract them with a threshold and a difference with an empty frame (as this doesn’t change). And feed those into an OCR algorithm. Then you don’t need to cut and paste and do relatively expensive pixel for pixel shifts to match templates.
@ClarityCoders
@ClarityCoders 2 жыл бұрын
My first language was C++ back in the day for sure much faster. All good points love feedback like this thanks for watching / commenting.
@kopuz.co.uk.
@kopuz.co.uk. 10 ай бұрын
OpenCV is overkill for html5 games, selenium would be faster for this.
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
@songsong961
@songsong961 2 жыл бұрын
Fruit ninja game python ai bot
Bot Plays Dino Run! Can our dinosaur bot be stopped?
11:30
ClarityCoders
Рет қаралды 50 М.
I tried to make a Valorant AI using computer vision
19:23
River's Educational Channel
Рет қаралды 1,4 МЛН
어른의 힘으로만 할 수 있는 버블티 마시는법
00:15
진영민yeongmin
Рет қаралды 11 МЛН
Sprinting with More and More Money
00:29
MrBeast
Рет қаралды 107 МЛН
100❤️
00:19
Nonomen ノノメン
Рет қаралды 38 МЛН
Beating a Pay to Win game with a bot
5:09
Kian Brose
Рет қаралды 1,8 МЛН
AI Crushes Wenus. (AI PLays Farm Freenzy)
7:41
ClarityCoders
Рет қаралды 15 М.
FastAI learns to play Fall Guys - Undetectable Fall Guys bot.
12:13
ClarityCoders
Рет қаралды 794 М.
Making a Whack a Mole bot using OpenCV's Match Template
17:22
Noob Coding and Gaming
Рет қаралды 25 М.
Automating Android Games with Python: Stick Hero
15:22
Engineer Man
Рет қаралды 381 М.
I made OD bots for Gaming in 30 MINUTES
1:13:33
Nicholas Renotte
Рет қаралды 22 М.
Rust's Alien Data Types 👽 Box, Rc, Arc
11:54
Code to the Moon
Рет қаралды 132 М.
cool watercooled mobile phone radiator #tech #cooler #ytfeed
0:14
Stark Edition
Рет қаралды 7 МЛН
Nokia 3310 versus Red Hot Ball
0:37
PressTube
Рет қаралды 3,8 МЛН
How much charging is in your phone right now? 📱➡️ 🔋VS 🪫
0:11