AI Learns To Swing Like Spiderman

5,378,950
0
Published 2023-02-01
J Jonah Jellynose suspects Spiderman is an AI. Captain Blubber is arrested twice. A phone screen is smashed. What is happening

0:00 Intro
0:30 Basics
1:30 States, Actions and Rewards
2:45 Discount Factor
4:09 Neural Networks
5:59 PPO
7:03 Policy Gradient
9:54 Clamping the Policy
10:34 What the AI Learned
13:05 Just Swinging

White paper on how to create an AI like this from scratch:
docs.google.com/document/d/1FZZvz0JMHKWOOVlXnrmeRM…

Download this AI: github.com/b2developer/SpidermanPPO
Discord: discord.gg/KgMgeQ7EMP
Reddit: www.reddit.com/r/b2studios/
Twitch: www.twitch.tv/b2studios

Useful Links:
huggingface.co/blog/deep-rl-ppo#the-clipped-part-o…
fse.studenttheses.ub.rug.nl/25709/1/mAI_2021_BickD…
iclr-blog-track.github.io/2022/03/25/ppo-implement…

All Comments (21)
  • @skycloud4802
    I love how chill and lazy the AI Spiderman seems. It's like Spiderman putting the least effort into moving about with his webs, whilst allowing his body to just ragdoll with it all.
  • @yudoball
    13:06 - he almost fell done - saved himself in the last second - celebration backflip
  • @Music-nn9mi
    I think the reason the ai moved to using only one hand was to minimize the randomness that happens to its decisions. Since half the time they don't affect the outcome if you don't use one of them.
  • @smike_mike
    because of the spiderverse this is a canon spiderman
  • @AlliSinned
    I like how the AI just resorts to using one hand form web shooting once it gets going. It’s like “why do I need two hands to shoot seems like a waste”
  • It's ironic because in most spider-man games, quick "thwips" are usually faster than using full swings, as you keep momentum better. Long swings have a curve to them and usually take a bit longer than just jumping off at the apex, which essentially looks like you are only swinging half way before thwipping again. It seems the AI has learned this.
  • Let’s just sit and applaud the fact this man can code this stuff, animate fun stuff, and WRITE what happens in a coherent way for new people Holy crap 👏👏👏👏👏👏👏
  • @Teslijah
    5:54 Does this mean you could teach a jellyfish to be SpiderMan 10 times faster than this computer?
  • @Amyrose13lee
    12:48 “It’s so good in fact, that it doesn’t need to look where it’s going” It developed Spidey sense without any programming lmao 😂
  • @GGCannon
    You should make it consider hitting walls a bad thing (to train it to stick closer to the middle) and consider one of the rewards to keep the body facing forward, while facing back would be a discount. That way, it will probably give favor to alternating which arm it uses, to keep facing forward and to stay at the center of the road.
  • @roscoe5427
    ten years ago i would not imagine myself sitting here eating my food while watching an AI grow up to be spiderman
  • I love how the web-slinging sound is just you going "chu" "shue" & "shu"
  • @drphalanges1520
    I like how it uses little micro-adjustments like you would do with thrusters in space. It's cool to see it so casually correct its course.
  • @TheFrozenFlame05
    I love how occasionally it does a spider-man like trick or flip, but for the most part it just like flails around and lets gravity have its way.
  • A thousand times, thank you for the segment at the end following the trained model! It is SO frustrating when a channel explains something for ten minutes, and then instead of giving you the gratification of a finished product (something I'm sure the creator enjoyed plenty of) they just end off with "whelp thanks for watching! byeeeee!"
  • I'd love to see a part 2 to this that attempts to make variants by adding silly additional rewards (aka reinforcement learning) to the current spiderman, like a version that tries to do as many backflips as possible whilst also going fast in a forwards direction.
  • @jabenyatko
    "Roman Sakutin" passed off your work as his own, and also inserted an advertisement in the video. You can try throwing a strike on his video.