Тёмный

Build a Street Fighter AI Model with Python | Gaming Reinforcement Learning Full Course 

Nicholas Renotte
Подписаться 266 тыс.
Просмотров 49 тыс.
50% 1

Yeah, I don’t know if anyone actually reads this. But if you do, here’s some stuff for ya!
In this tutorial, you'll learn how to:
1. Setup Gym Retro to play Street Fighter with Python
2. Perform Hyperparameter tuning for Reinforcement Learning with Optuna
3. Fine tune game reinforcement learning models using Stable baselines
Get the code: github.com/nicknochnack/Stree...
Chapters
0:00 - START
1:35 - MISSON1: Setting up Street Fighter
25:40 - MISSION2: Preprocessing
1:12:02 - MISSION3: Hyperparameter Tuning
1:59:17 - MISSION4: Fine Tuning the Model
2:18:00 - MISSION5: Testing the Model
2:30:15 - FINAL GAMEPLAY
2:39:27 - FEEDBACK
Oh, and don't forget to connect with me!
LinkedIn: bit.ly/324Epgo
Facebook: bit.ly/3mB1sZD
GitHub: bit.ly/3mDJllD
Patreon: bit.ly/2OCn3UW
Join the Discussion on Discord: bit.ly/3dQiZsV
Happy coding!
Nick
P.s. Let me know how you go and drop a comment if you need a hand!
#ailearns #python #streetfighter

Наука

Опубликовано:

 

19 июн 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 136   
@Bob-wr1md
@Bob-wr1md 10 месяцев назад
In case anyone stumbles on this, and doesn't want to run into a bit of frustration with the setup: You need Python 3.7 or 3.8 (I used 3.7) You need to install an earlier gym version (pip install gym==0.21.0) and need to install an ealrier importlib-metadata (pip install importlib-metadata==4.13.0) That made it work for me.
@sohailmomin1486
@sohailmomin1486 10 месяцев назад
Bro I have same problem can help me more about installing exact steps
@Bob-wr1md
@Bob-wr1md 10 месяцев назад
@@sohailmomin1486 you have to make sure you're running python 3.7 or 3.8 and then run the codelines in parantheses with normal pip command
@aounzaidi9248
@aounzaidi9248 10 месяцев назад
Can you please share your code with me?
@Bob-wr1md
@Bob-wr1md 10 месяцев назад
@@aounzaidi9248 the code is in the brackets
@ojaspatil2094
@ojaspatil2094 3 месяца назад
thank you!
@KidRell318
@KidRell318 2 года назад
This will make a good weekend project!
@NicholasRenotte
@NicholasRenotte 2 года назад
Amen to that!
@darkwave_2000
@darkwave_2000 2 года назад
Cool Video again, I specifically like the hyperparameter tuning which is new to me and brings the training to a new level.
@Guulaysi
@Guulaysi Год назад
this is the best project in youtube that i have been seen during my research in reinforcement learn thank you Nicholas renotte i will enjoy it
@sebastianrothe
@sebastianrothe 2 года назад
Awesome! i played this game when is was a kid :) and YES, please a video about environments....
@vbayarri
@vbayarri 2 года назад
Great video Nicholas. I learn a lot from it.
@mgtx6280
@mgtx6280 2 года назад
Another great video from my man Nicky. God bless you man
@NicholasRenotte
@NicholasRenotte 2 года назад
Thanks a mil my guy!!
@rohitchan007
@rohitchan007 2 года назад
Thank you so much for these tutorials.
@ihateorangecat
@ihateorangecat 2 года назад
been waiting for it!
@codewithkarthik7136
@codewithkarthik7136 2 года назад
AMAZING VIDEO NICH! LOVED IT! KEEP IT UP
@NicholasRenotte
@NicholasRenotte 2 года назад
Thanks so much Karthik!
@henrymiller6193
@henrymiller6193 Год назад
Hi Nicholas, nice video there, very informative! However, I have two important questions. 1. Is there a way that we can extract the values of Generalized Advantage Estimation (GAE) from the training process for visualization? 2. Suppose we have already built our own bot, is there a way that we can fight against it to obtain some kind of human benchmark? Thank you!
@vialomur__vialomur5682
@vialomur__vialomur5682 Год назад
Thanks a lot for this type of videos!
@meetvardoriya2550
@meetvardoriya2550 2 года назад
Simply Amazing as always ❤
@NicholasRenotte
@NicholasRenotte 2 года назад
Ayyyy Meet! Thanks so much 🙌!!
@aounzaidi9248
@aounzaidi9248 Год назад
Hi Nicholas, first of all great video! Secondly I have question that can we create a reinforcement learning model that can be implemented on any game?
@swamikannan943
@swamikannan943 2 года назад
Just a quick clarification. At 19:28 , you would also have to break the while loop at the if done: section right ? Fantastic tutorial. Your videos are pretty amazing !
@zcohent
@zcohent Год назад
tutorial on virtual environments would be amazing!
@cheekachin6610
@cheekachin6610 2 года назад
Amazing tutorial
@spqri3
@spqri3 2 года назад
Youre still the best. Many thanks.
@NicholasRenotte
@NicholasRenotte 2 года назад
Thanks my guy!
@FreebyrdFayelanx
@FreebyrdFayelanx 2 года назад
This is amazing. Thank you. I am actually a very high level level SF player from the same country. I am going to try implement this using my own IT background. I suspect I can probably quite easily beat the AI’s Ryu with my Guile but am interested to see if it can be improved to be within plus or minus 10% of my skill so I can improve. 10,000 hours of an activity is what is considered mastery in Psychology and for someone to improve the opponent needs to be of the aforementioned number.
@alainaalam8187
@alainaalam8187 Год назад
Is it working properly?have you did it?
@CSHARPANDVBNET
@CSHARPANDVBNET Год назад
Nice video Nicholas
@santiaparicio9239
@santiaparicio9239 2 года назад
Good video Nick, do you know if its possible to build an AI on a browser game using selenium without a gym library?
@amanparab5559
@amanparab5559 2 года назад
Hey Nick, so I was following your ANPR tutorial, had a question How do I save the trained model?
@vasylcf
@vasylcf 2 года назад
Thanks it was interesting video !
@weekendwargamers
@weekendwargamers 2 года назад
man this is awesome!
@NicholasRenotte
@NicholasRenotte 2 года назад
YOOOO team Lees! Thanks guys!
@NoMercy8008
@NoMercy8008 2 года назад
I read the descriptions, you never know what fun or important stuff is hidden in there :D SUPER awesome video, as always thanks a massive ton for it, much much appreciated! I love it! I really like learning more about the hyperparameter optimization in your videos lately, i think it's a super fun and important topic. Can't underestimate the improvements you can get from properly tuning your parameters. And generally, reinforcement learning is such a cool and fascinating topic. Been actually diving into the foundations of Q-Learning and DQNs the last couple days, so learned about the mathematical ideas and actually want to create my own implementations of the algorithms soon, because that really helps me understand what's actually going on "inside the blackbox". That's also why I made my own super simple implementations of neural networks and the NEAT algorithm and so on in the past, I find it super important and even more fun to learn how and why they actually work and so on. It's incredibly amazing how we can do so complex things with algorithms that are mathematically relatively simple. It's hard to explain why, but that fact alone creates so much passion inside me, I love ML :D In regards to roughly 2:08:10, where you talk about the best/better learning rate: What also might be worth or at least interesting to try out is to anneal the learning rate over time, if the ML library supports that. So you start out the training with the higher learning rate to get to relatively good weights relatively quickly and then more or less slowly lower the learning rate over time so that the weights have a bit more stability and can really home in instead of jumping around too much. And yeah, it is super addictive to watch how your model actually performs in those games, isn't it? With my custom NEAT implementation I created a little "artificial life"/evolution sim and it's really fun and interesting to watch how the agents actually do and evolve over time (so long as they don't go extinct the first chance they get... because they don't understand that food = good and instead decide to just dance around in a circle... which surely is a ton of fun, just not... healthy after a while. Dudes need to EAT).
@m.ajiprasetyo7188
@m.ajiprasetyo7188 2 года назад
I hope this comment got noticed. The topic of hyperparameter optimization is very interesting, I often stuck in learning about it
@NicholasRenotte
@NicholasRenotte 2 года назад
Hahahaha, you caught that did you?! Thanks for checking it out! Oh love that you're building them up from scratch, I had to do the same to really get my head around PPO. DQN is next on the list to knock over some off-policy stuff. Regarding annealing the lr, you can use schedules in the callback to do it. Haven't tried it out but definitely on the list! On NEAT, that's awesome. Seriously it's so addictive to watch!
@NoMercy8008
@NoMercy8008 2 года назад
@@NicholasRenotte Of course I caught that :D And yeah, I can really recommend to anyone wanting to get a deeper understanding of ML in general to just implement some of the algos from scratch. It really does help you wrap your head around it and it's actually not as hard as it looks. The best starting point is just a plain and simple Deep Neural Net to really understand gradient descent. And once you really got gradient descent down, everything is possible, since many many of the popular algos are just variations of it. As i said, I'm working on a deeper dive into reinfocement learning at the moment, and my little goal is to maybe create a project that draws pictures with you. Something like the net draws a "picture" (essentially just a sequence of lines on a canvas), you give it a rating between -10 and 10 as it's reward, which the net uses to adjust itself, rinse and repeat until you get yourself a nice drawing (or something ...). Maybe with possibilities to adjust hyperparams on the fly so that the user can start out with a pretty high learning rate until the net finds an interesting approach. It probably won't work quite as nicely as I would want it to, since you'd probably need to do a million steps until it arrives at some actually cool drawings, but it's a fun exercise nonetheless, or so I hope. Could also use neuro-evolution instead of reinforcement learning, for example. I think to really get the most out of it, it's probably interesting to use some ML algo that's even better with sequential data than RL. Or you could ditch the drawings and generate for example poems instead. Oh well, I'm rambling. But this is again an example for ideas that can produce really addictive results. I, personally, could see myself there for hours just checking out drawing after drawing or poem after poem to see how it changes and (hopefully) improves over time.
@kismetkindle
@kismetkindle 2 года назад
dude! awesome!
@pierocasusol7279
@pierocasusol7279 2 года назад
This will be a cool 3 hours 🤩
@NicholasRenotte
@NicholasRenotte 2 года назад
Yeah bit of a long one but I figured it was worth it.
@HideyHoleOrg
@HideyHoleOrg Год назад
If you cropped the topmost section of the screen that has the score/health/time/etc during preprocessing, would this make a difference in the training by removing "noise"? Would be nice if the background could be removed from behind the characters, I bet the animated backgrounds create additional noise.
@aggelosioannidhs8429
@aggelosioannidhs8429 2 года назад
I love your vids
@Fourgees_4GS
@Fourgees_4GS 2 года назад
ayyy it's here. Nice
@NicholasRenotte
@NicholasRenotte 2 года назад
AHHHH, man it took a while. Tbh though I had a ton of fun making this vid.
@Fourgees_4GS
@Fourgees_4GS 2 года назад
@@NicholasRenotte very cool and seemed fun. Do more games! Maybe some platformers? I haven’t seen any 3D platformers done but I suspect cause of the complexity. 2D like donkey Kong country would be great. Are there better alternatives on the horizon to gym/gym retro?
@svh02
@svh02 2 года назад
Hey Nick, awesome tutorial as usual. Could you elaborate on why you chose PPO, or better yet on how to choose what algorithm to use? thanks!
@NicholasRenotte
@NicholasRenotte 2 года назад
Thanks @Santiago, tbh I usually run with PPO given it's not as memory hungry as off-policy models like DQN. That being said I've seen some pretty good performance when I can compress the inputs enough when using DQNs.
@NicholasRenotte
@NicholasRenotte 2 года назад
Also...it's mostly informed based on what the observation space and action space look like (not all models support all spaces); stable-baselines3.readthedocs.io/en/master/guide/algos.html
@svh02
@svh02 2 года назад
@@NicholasRenotte thanks!
@fernandomaia4684
@fernandomaia4684 2 года назад
Hello Nick, Awersome tutorial! What's the python version have you used in this tutorial?
@xxfloppypillowxx
@xxfloppypillowxx Год назад
I'm not sure what version he was specifically using but you need to use 3.7, 3.6, 3.5 for retro
@AyushKumar-pt1zx
@AyushKumar-pt1zx Год назад
Hey Nicholas, I have developed a fighting game using a tutorial in JS, the game is in this format only, It is a web application and both the players are controlled using different sets of keys and I wanted to make one of them AI based, so as to implement the play with computer functionality! will the tutorial be of any help for that?
@douglaslassance
@douglaslassance Год назад
That might need a bit of a long answer but, once you have a satisfying model, how do you go about playing against it?
@babiscirca
@babiscirca 2 года назад
Hello, thanks for the amazing content. I am a student (noob in ML) working on this code for a project and I would like to ask how you choose the limits of every parameter in the hyperparameter tuning part. For example, i would like to try A2C but i am not sure which range i should suggest for n_steps. In stable baselines it indicates n_steps=5. What should i do ?
@NicholasRenotte
@NicholasRenotte 2 года назад
I used a HPO framework called Optuna to select the best hyperparameters @MultiKAP
@babiscirca
@babiscirca 2 года назад
​@@NicholasRenotte Yes i understand but for example in 'n_steps': trial.suggest_int('n_steps', 2048, 8192) I saw stable baselines suggest as a default n_steps=2048 but how did you choose the range 2048,8192. Thanks@!!
@danielaguirre5078
@danielaguirre5078 Год назад
So how Shadow system works?(killer instinct), because that bot learns quick as hell, is machine learning too or is something else?, anyways nice video!
@ShivaniRameshKanna
@ShivaniRameshKanna Год назад
Hello there, thank you for such an informative tutorial. Is there a way where we can make one of it human controlled?
@ammartanweer3388
@ammartanweer3388 2 года назад
hey nick video is amazing can you make a video on how to put Reinforcement learning in production
@wanghinchan3192
@wanghinchan3192 2 года назад
Amazing content, Nick. But is there a way that we can use openai gym to train an AI game bot without relying on other people to frame the game in python? If we could do this, we can train a game bot for any random game! Maybe the knowledge in your Capture Timberman Footage vid could be used?
@NoMercy8008
@NoMercy8008 2 года назад
As you yourself mentioned, to get info out of the game you can always just capture the full frame and feed it to your ML model. That's probably the best idea anyways, as the model then has essentially exactly all the info that a human player would have and nothing more. Though you need to be a bit careful with this approach and think about the right sort of pre-processing, what's good in your specific case and what isn't. For example, as Nick mentions in this video, he turned the image he fed to the PPO into greyscale, which caused problems when the AI had to fight Ryu vs Ryu. Games often use color to distinguish otherwise very similar looking objects, or to give hints about the environment, etc. So while the greyscaling cuts down on the complexity of the info you feed into your ML model, which helps it to learn, there's also the possibility for important info to get lost. How to feed data (the actual controls/actions) back into the game is very very specific to the actual game. Sometimes you'd need to use external software to emulate key-presses, sometimes you could write a mod for the game to interface with, or in some cases you'd maybe need to unpack the whole game and wrap it into an environment like the OpenAi gym people do for us. There are multiple considerations that are important here: - Navigating menus and stuff is something to really think about. You don't necessarily want to waste time and complexity training your AI to use menus, but you don't want to manually navigate after each training run either, so you'd need to automate that somehow. - Don't ever use something like this to cheat in online games with or against real unknowing human players, that's really neither fun nor fair for anyone. There are plenty of fun things to use your AI gaming agents for other than being a douchebag (Sorry for this rant, I do not want to insinuate that this is what you intend to do or anything, but I feel like it is important to mention that it's crucial to think about morals and how your bots could be used before building/releasing them. There are enough people ruining other people's fun in online games as it stands already, no need to empower those guys with AI more than they probably already do.) A really cool and very positive example is those "events" where human players try to beat the AI, makes for great showmatch content and there's a lot to learn for human players as well as for the AI guys. The chess engine AlphaZero or the OpenAi Dota 2 bots come to mind here. Especially the latter is a fun watch if you're into MOBAs, I guess.
2 года назад
Thanks for a great video. I have some comments to share with you: 1. You should use VS Code. Its code suggestion is so good that you won't get unexpected errors such as forgetting import os namespace. 2. I tried training in individual stages for better performance as you suggest. The problem is the agent usually forgets how to play the previous stage after being trained for the current stage. I hope you can make another video showing how to fix it. 3. Instead of using the score as the reward, I think it is better to use the agent's hp and opponent's hp instead. The agent will learn how to defend instead of only attacking.
@NoMercy8008
@NoMercy8008 2 года назад
Your numbers 2 and 3 are interesting points, would be really nice to take a closer look at both of them! In regards to number one, I actually see it as a positive that Nick leaves those kinds of mistakes in, because I imagine it helps especially the newer programmers that are watching his videos get a grip on the common errors and oversights that do happen and where to look first if stuff doesn't work.
@NicholasRenotte
@NicholasRenotte 2 года назад
Thanks VitCon! I actually leave in the mistakes now to show what it's really like, I was so intimidated when I first started coding because of all the RU-vid pros that built full stack apps without a single error. I love VSCode though, but mainly use it for converting stuff to scripts or full stack. On the other two, these are VERRRYYYY interesting. How did you get the stage loading to work? I couldn't get the integration UI to load the ROM on my pc. Was pulling my hair out. On using health for the reward, I tried it BUTTT, you have to be careful because the health bar resets after every match. So need to use the match win/lose counter to detect when a new match has commenced (not a new episode). I didn't do it initially and threw of training massively, but yes, 100% agree if done right this would likely help get us to defend.
2 года назад
@@NicholasRenotte you can save the game state and reload it when calling retro.make. That’s how I train each fight individually.
@NicholasRenotte
@NicholasRenotte 2 года назад
@ ohhhh, so you’re not even using the integration UI. Damn didn’t even think of that
@iced_javascript1831
@iced_javascript1831 2 года назад
@@NicholasRenotte Can this tutorial be followed if you use VSC? JupyterLab is really confusing and I can't get it to run commands like you can and I keep having to abandon the projects I start with your videos :(
@mengjunwang8687
@mengjunwang8687 2 года назад
oh my god, you are a genius. I wonder is it possible to build an Ai to beat a real street fighter2 player in some online fight platform?
@leonardopatricelli2933
@leonardopatricelli2933 2 года назад
Ciao Nick! Do you know a way to work with reinforcement learning on Neo Geo games? I would like to build an agent able to play Metal Slug!
@DoppsPkin
@DoppsPkin 2 года назад
subscribed
@KyleRosebk
@KyleRosebk Год назад
very cool
@ProjectShinkai
@ProjectShinkai 29 дней назад
this is interesting
@joekanaan2548
@joekanaan2548 Год назад
Hi, when I try to do python -m retro.import . It's saying imported 0 games. I have cd'd into the roms folder and I have the files there so idk what's happening. The only thing I'm doing different is that I'm not using a virtual environment. Please Help Edit: I'm also using anaconda prompt instead of cmd. Because the gym-retro wasn't being installed using pip so I used anaconda instead.
@triggeredcomments4009
@triggeredcomments4009 2 года назад
More more more! Pls do more 3d games If possible early 2000s games
@xxfloppypillowxx
@xxfloppypillowxx Год назад
So there is a pretty critical flaw here in how this is trained. Because the reward is based off of score and wins it incentivizes 3 round matches because scoring points in a win, followed by scoring points in a lost round followed by winning in the third round is going to yield a much better score regardless of win rate. The even WORSE part is that they can get more points by winning 1 round and losing 2 rounds than if they just won 2 rounds it a row. After 24 hours of tuning and training the best results I'm getting are beating Guile (most of the time) and losing to Ken which was the same result I was getting with just random inputs. I'd be upset if I was planning on making this AI but really I'm just watching for the techniques and I've learned a lot from this experience and confirmed that my suspicions from the beginning of score being a bad reward. Still a good video just maybe a bit flawed implementation
@NicholasRenotte
@NicholasRenotte Год назад
Yo Sean! Solid feedback, I had to think about this for a little while but yeah I think you're onto something. If n=# of games, an increased value of n would increase the opportunity to score more (regardless of winning in totality). I think this could be fixed by adding an disproportionately large constant for winning a round (relative to scoring points in battle), could possibly tune this so that the agent receives a larger reward for winning earlier rounds as well. Thanks for the feedback, appreciate it!!
@xxfloppypillowxx
@xxfloppypillowxx Год назад
@@NicholasRenotte I have some ideas in the works that I'm going to test and I'll follow back up when I get the results.
@NicholasRenotte
@NicholasRenotte Год назад
@@xxfloppypillowxx Swet, let me know how you go!
@xxfloppypillowxx
@xxfloppypillowxx Год назад
@@NicholasRenotte so after doing some testing and running into a bunch of issues with doing it I found out that it actually worked quite well using the health changes, I would need to tweak the numbers for better results but as this is more of a learning project for me I'm notgoing to spend the time getting the best results I can. I also added a penalty in to punish needlessly jumping but I definitely set that punishment too high. It was an interesting test for someone who DOES actually play fighting games (though I don't play street fighter specifically) to try to help the AI learn to play "properly" because in games like street fighter jumping is *rarely* used since you cannot block while in the air making it extremely dangerous to do. One thing that it did not seem to learn at all was how to block attacks and I'm not exactly sure how I'd incentivize it to learn to block with the data that is available, I could potentially reward the AI for each frame it's alive but it would take quite a while to figure out the appropriate rewards
@Guulaysi
@Guulaysi Год назад
where i can download the file street fighter in wowroms please give the link of that download file
@Fourgees_4GS
@Fourgees_4GS 2 года назад
I couldn't figure out how to add audio in gym retro either. I've seen some videos where people apparently got their audio working and synced but I never could quite figure it out.
@NicholasRenotte
@NicholasRenotte 2 года назад
Yeah, it's a massive pain. I wanted to train per level but the integration UI just didn't want to load up the rom.
@Fourgees_4GS
@Fourgees_4GS 2 года назад
@@NicholasRenotte that’s so odd. You usually have to make a save state and then load the state along with the rom. I’ve got games to work in retro gym but I used the neat algorithm with it.
@NicholasRenotte
@NicholasRenotte 2 года назад
Hmm, I got that bit I just couldn't get the actual ROM to load in the interface for PC. I wonder if it was a buggy version, I didn't end up spending too much time on it, was trying to power through. But solid suggestion!
@MrXxx00000xxx
@MrXxx00000xxx 2 года назад
Could we change to another characters instead of Ryu to play?
@v01dgaze
@v01dgaze 2 года назад
I really like your tutorials, can you make videos about deep q learning too? For example dqn, double dqn, d3qn. Also not with high level libraries. Because I need it and it is harrrd.
@NoMercy8008
@NoMercy8008 2 года назад
I don't know how much prior knowledge you have, so I'll give a rough outline for where to start for you and others who might care: - First, start out with understanding the completely standard neural networks, with special focus on gradient descent. There are lots of tutorials you can find online about that. Gradient Descent is basically the foundation for many many other ML algorithms, so that's why it's really important to learn first, in my opinion. - Then, learn about the standard version of Q-Learning (not DQNs, just the normal Q-Learning for starters). The basic outline for this is that you have a so-called "q-table", which is basically a look-up table for the values of all possible actions in all possible states of your system. It learns essentially by taking actions (either via Exploration aka random choice, or Exploitation aka sampling from the q-table; Important to note and understand here is that the exploration rate usually starts out at 100% and then slowly decreases as the model learns) and then adjusting the q-table with gradient descent based on the reward it gets. Another good keyword to look up here is "Bellman equation", since this is basically the equation that is being used to calculate the updated q-values. - Once you got the normal Q-Learning down, you create a DQN by essentially replacing the Q-Table with a deep neural network according to your needs. Important concepts to understand here are why you freeze and copy the DNN every so often instead of sampling q-max from the same network and why in many cases you need a sample memory. This, at least, is the path I took, and to reiterate: Essentially it all comes down to understanding Gradient Descent in the first step. And then you can go to basic Q-Learning and then to DQNs afterwards. The step-by-step approach really helps break the info down and build the necessary foundations for every successive step.
@v01dgaze
@v01dgaze 2 года назад
@@NoMercy8008 Wow great explanation sir. I hope I will get the passion you have when I see some fragments of success :)
@osmiimusic
@osmiimusic 11 месяцев назад
victory on thin... a good goal is to win without taking damage, and then win without taking damage in a short time
@zhezhu7554
@zhezhu7554 2 года назад
I'm both fans of RL and SF
@susteven4974
@susteven4974 Год назад
how I can change default character Ryu to other character , like Chunli ?
@DrKaku01
@DrKaku01 Год назад
Its posible to use it for others games ?
@gcarnelos
@gcarnelos 2 года назад
Why don't you use tensorflow ? please tell me :/
@flowerboy_9
@flowerboy_9 2 года назад
hey i get errors when i try install gym-retro how do i solve this problem
@gundachan
@gundachan 2 года назад
Bro you have tutorial for face mask detection can you tell me how to make it like giving sound of masked and unmasked on detection
@onyenwezhang392
@onyenwezhang392 Год назад
Greetings! This is a nice video, but I failed to find a suitable version of python to implement all content. Would you please tell me about the details of you system information? I would be appreciated.
@liquidsnakeblue1
@liquidsnakeblue1 11 месяцев назад
I'm using 3.7.9
@dmh--sneaky3968
@dmh--sneaky3968 2 года назад
How could I copy the code as I want to show my friends
@motivationallines5295
@motivationallines5295 2 года назад
can some one provide link to website to download rom for street fight game because I am downloading but it is downloading something different not the required rom.
@bc4198
@bc4198 Год назад
"They took our games!" Or is it that bots won't take our jobs if they're too busy playing games? Will WOW-addiction save us from the robot takeover? Anyway, this is super cool - thanks for the video!
@torarinvik4920
@torarinvik4920 5 месяцев назад
How much money did it cost to train it?
@johanneszwilling
@johanneszwilling 2 года назад
🤓 REALLY liking these approaches, Nick!! I do! 😇 Any chance for a shorter version/cut? Something between 15 or 30 minutes? Even at higher playback speed it's a tall order to invest multiple hours every time. Just asking,...other than that maybe it's not for me then yet!?
@NicholasRenotte
@NicholasRenotte 2 года назад
I love this suggestion. Was actually toying with the idea while making this video. Just keeping the intro, client talks, memesplainers and results. Then maybe doing a voiceover for the cut down coding bits. Ideally aim to hit that time frame you mentioned.
@johanneszwilling
@johanneszwilling 2 года назад
@@NicholasRenotte Good Morning from 🇩🇪 Germany, Nick! Thank you for this fast reply! Don't get me wrong! There's absolutely a need and place for more thorough depth to teach this stuff. 2-3 hours is probably REAL fast given all the things that go into this type of problem solving in general and the specific parts of writing the code properly, whilst conveying it entertainingly and didactically efficient. Not easy and I think you do a terrific job there! This can absolutely come down to: "Listen people, my stuff is 2-3 hours long and that's just that. Make it a priority, take the time or don't". Fully 100% legit and fair enough! There's a point beyond which things cannot be simplified or shortened much more. Simply put, I'm just looking at Codebullet! Obviously it must not be this obscure. That's not an insult. The guy is terrific, though with him it seems to be more about entertaining a whole lot more people, who aren't necessarily interested in learning to code or do machine learning, than it is to teach this as a matter of fact. It's entertainment first with him. I can see myself definitely watching 15-30 minutes for a project like this REGULARLY and after that go for the full length, even if that's much, much longer. Kind of like a trailer or teaser first. Hell! The full thing can even be a paid course, sign me up if it's worth it,....it's just hard to do if it's 2-3 hours upfront no matter what. Just yesterday for instance, I enjoyed Sebastian Lague's latest 30-minute video,...and I'm not even doing shader coding (yet). Now afterwards I'm wondering if I'd like to look into a tutorial for exactly that. All the best and thank you, thank you for your content!! J.
@NicholasRenotte
@NicholasRenotte 2 года назад
@@johanneszwilling I love this feedback and I completely get it. I’m the exact same, I’ll watch something even if I don’t necessarily have the immediate intent to code it. I put a ton of effort into the client convos and explainers and actually thought they’re probably good enough to run as a stand-alone video without too much of the complex coding. Will do a rough cut this weekend and see how it goes!
@KenJee_ds
@KenJee_ds 2 года назад
Hello Ken?
@NicholasRenotte
@NicholasRenotte 2 года назад
No Kens were hurt during the making of this video* *I cannot be held liable for the accuracy/inaccuracy of this statement*
@electricspeedruns6121
@electricspeedruns6121 4 месяца назад
7:48 is confusing me i cant find the environment thing any help?
@TravisGarnett
@TravisGarnett Год назад
#Nicholas_Renotte, thank-you very much for this "#PER_FECT‼" RL course! #YogaFire❗🗣🔥🔘💨👐😎#Hadoken❕
@nikhilbhalerao4385
@nikhilbhalerao4385 2 года назад
Is RTX 3060ti good for Deep Learning?
@drunken_viper
@drunken_viper 2 года назад
i'm getting this error msg: "AttributeError: 'RetroEnv' object has no attribute 'em' " After this part of the code at the beginning obs = env.reset() done = False .....print(reward)
@liquidsnakeblue1
@liquidsnakeblue1 Год назад
Restarting the Kernel fixed it for me
@emmanuelcajucom9506
@emmanuelcajucom9506 2 года назад
Sir can you make a tutorial about face recognition with facemask identification like it identify person even he/she had a facemask please thanks
@ashleysami1640
@ashleysami1640 2 года назад
👏🏽👏🏽
@peterchinoko4339
@peterchinoko4339 Месяц назад
Can i learn and do this project in 2024?
@vanshgupta6643
@vanshgupta6643 Год назад
What version of python and gym are you using im getting errors on following this
@comedyguy911
@comedyguy911 Год назад
It's python 3.8 for gym-retro which is the latest version supported, but when running but then the code block at 20:40. Running that gives me an error of env.reset which can be fixed by removing env.close(), and then a new error of env.render() module not found. comes up
@comedyguy911
@comedyguy911 Год назад
ok seems like downgrading gym to 0.21.0 makes it work. do "pip uninstall gym" then "pip install gym==0.21.0"
@shinrafahell
@shinrafahell 2 года назад
Add time as a reward
@hafeezademolapopoola3926
@hafeezademolapopoola3926 2 года назад
May Allah continue to bless you.
@NicholasRenotte
@NicholasRenotte 2 года назад
Ayyy, thanks brother, likewise!
@mohamedhamdy8330
@mohamedhamdy8330 2 года назад
many thank
@ApexArtistX
@ApexArtistX 7 месяцев назад
why all RL tutorials is NES games.. why not do a web external screen capture observation learning
@TripleCheeseExtraCheddar
@TripleCheeseExtraCheddar 2 года назад
GET A PATREON!!!!!
@Studio-ig8sn
@Studio-ig8sn 2 года назад
To Fast for me Please slow down for the people like me. My anxiety all time high trying to listen and code along
@RichardNicanorOnog
@RichardNicanorOnog 8 месяцев назад
try AI model for mobile MOBA game
@Guulaysi
@Guulaysi Год назад
please give me response
@liquidsnakeblue1
@liquidsnakeblue1 11 месяцев назад
I was able to resolve the issue of n_steps not being a factor of 64. Since you asked, here is how! Instead of letting the trial suggest any number in the range, you can make it suggest multiples of 64. # PPO optimization parameters PPO_PARAMS = { 'n_steps_range': (2048, 8192), 'gamma_range': (0.8, 0.9999), 'learning_rate_range': (1e-5, 1e-4), 'clip_range_range': (0.1, 0.4), 'gae_lambda_range': (0.8, 0.99), } # Define the optimization function for PPO def optimize_ppo(trial): n_steps = trial.suggest_categorical('n_steps', range(PPO_PARAMS['n_steps_range'][0], PPO_PARAMS['n_steps_range'][1], 64)) # Steps of 64 return { 'n_steps': n_steps, 'gamma': trial.suggest_loguniform('gamma', *PPO_PARAMS['gamma_range']), 'learning_rate': trial.suggest_loguniform('learning_rate', *PPO_PARAMS['learning_rate_range']), 'clip_range': trial.suggest_uniform('clip_range', *PPO_PARAMS['clip_range_range']), 'gae_lambda': trial.suggest_uniform('gae_lambda', *PPO_PARAMS['gae_lambda_range']), } Alternatively, you could also try to Modify the n_steps after trial suggestion. You can round the suggested n_steps to the nearest multiple of 64.
@ukaszKozio
@ukaszKozio 2 года назад
hey, has anyone come across a situation when evaluate_policy is performing very poorly (ryu ducking all the time) while the loop with explicit predict call is doing great (beating guile consistently)? my testing code is exactly the same as in Nick's -Tutorial notebook trying to see if I get the same behavior on pretrained model but loading it gives this error model = PPO.load('./best_model_5460000.zip') AttributeError: 'Box' object has no attribute 'np_random'
Далее
Training an unbeatable AI in Trackmania
20:41
Просмотров 12 млн
AI Learns to Walk (deep reinforcement learning)
8:40
I tried to make a Valorant AI using computer vision
19:23
I Made a Neural Network with just Redstone!
17:23
Просмотров 599 тыс.
A.I. Learns to DRIVE
16:17
Просмотров 6 млн
AI Invents New Swimming Stroke
20:11
Просмотров 226 тыс.
Спидран по ПК
0:57
Просмотров 18 тыс.