Surplus electronic parts : https://epartsconnect.com
Stock and Crypto AI Prediction : https://stocksignalslive.com

I always sucked at baseball... until now... ok, I still probably suck.
Go subscribe to Jabril's channel!!! https://www.youtube.com/channel/UCQALLeQPoZdZC4JNUboVEUg
Simple app (it's actually just a webpage for now): http://jabrils.com/sp/
Complex app using ML: https://github.com/Jabrils/Uncle-Rober-Baseball-Predictor
Music
0:29 Dansez - Fasion https://www.epidemicsound.com/track/QXxs7iZ3Rn
1:01 Dive - Lvly https://www.epidemicsound.com/track/4JmHD4z5Bj
2:19 Dansez - Fasion https://www.epidemicsound.com/track/QXxs7iZ3Rn
4:16 Kalimba Jam - Blue Wednesday https://soundcloud.com/bluewednesday/
5:23 Take Me Out to the Ballgame -Matt Cherne- https://smarturl.it/einsteinbeats
7:04 Arrow - Andrew Applepie http://andrewapplepie.com/
8:18 Cereal Killa - Blue Wednesday https://soundcloud.com/bluewednesday/
11:16 Salamanca - Sarah, the Illstrumentalist https://www.epidemicsound.com/track/nAhVeSoknF
13:12 Q - Blue Wednesday https://soundcloud.com/bluewednesday/
14:18 Too Happy to be cool - Notebreak https://soundcloud.com/notebreak/dubstep-too-happy-to-be-cool
Summary: I wanted to see if I could make an app that could decode baseball signs. Turns out we could and it was a great opportunity for me to learn more about Machine Learning and neural networks and artificial intelligence from my friend Jabril.
MERCH-
They are soft- https://teespring.com/stores/markrober
PLEASE CONSIDER SUBSCRIBING: http://tinyurl.com/MarkRober-Sub

­
I make videos like this once a month all year long while supplies last:
CHECK OUT MY CHANNEL: http://tinyurl.com/MarkRober-YouTube
FACEBOOK: https://www.facebook.com/MarkRoberYouTube
TWITTER: https://twitter.com/ #!/MarkRober
INSTAGRAM: https://www.instagram.com/markrober/

No steel, there's no steel there. I predict not a steal, watch this and he stayed he's gon na steal. This is a steal. If this app works, this kid's about to steal there, he goes there.

He goes it freaking works. It works. Two years ago i came up with an idea for an app where you could decode baseball signs. So you would know when the other team was going to steal, even after just the first inning, then in a covert effort to get people more interested in coding and machine learning.

I would make the app free and available to everyone i'm happy to report. It's no longer just an idea today, i'm going to show you exactly how the app works and we'll use it in the wild and then we're going to talk about machine learning in very simple terms, with my buddy jabril, but first to set the stage we need To understand the fascinating world of secret baseball signs, it's the game within the game. Most people know the catcher will give signs to the pitcher when your team is on defense, but when you're on offense, the third base coach gives signs to both the batter and the base runner. For example, he could secretly tell the batter to bunt or to not swing at the next pitch, or you can tell the base runner to steal and just to be clear.

Stealing a base is when you start running as soon as the pitch is thrown. Instead of waiting for the batter to try and hit it, it's risky, because if the batter doesn't hit the ball and the catcher is good, he can throw you out at second base, because it's a big advantage. Coaches will actually tell their players to watch and see if they could figure out the other team's signs. That's considered fair play and it's part of the game.

The problem is our brains, aren't great at figuring out the complex pattern, so we set out to create an app that would use machine learning to do exactly that and by we i mean jabril, actually sat down and wrote the code, and i just made sure he Had unlimited cheez-its in lacroix, here's how it works. If i saw coach touched his nose, ears, arm chin and so on, i would assign those to letters in the app then i would just watch him sign and record the order. After that, i would just let the app know the outcome, so was it a steal or not after you do this for enough sequences, the app will start to make predictions in this case. It's predicting the combination of aed or nose.

Then chin is their steel sign. This worked well enough on my workbench, so now it was time for the first real world test in a kids versus adults. Wiffle ball game. My friend sarah takes the game of whiffle ball pretty seriously, so she was the captain of the kids team and was signaling for them to steal at just the right moments and i wasn't sure, the ethics of using our app against a bunch of little kids.

But they were scoring, runs and stealing bases with impunity, and then they got so confident they started talking trash and no one says that about my picture. So at that point the gloves came off. We found it easiest to film her signs with our phone and then scrub through and capture the order in the app afterwards, as opposed to trying to do it real time and i'm very happy to report. We cracked their code after only three sequences and what's cool is once you know the code, you no longer need the app because you can just watch for the steel signal and when we saw it, we alerted our picture with the secret sign of our own and After that, the tides of the game shifted and we were able to officially prove adults, rule and kids drool.

So our app cracked, the code after just three sequences and i'm going to show you them to see if you can figure out the steel sign using just your brain. Here's, the first one - and this was a steel. Here's the second - and this was no steal - and this is the third and it was a steal, pause and go back if you want to try and figure it out, because i'm about to tell you the answer. According to the app which sarah later confirmed, their steel sign was only if she touched her hat and then left ear back to back.

Everything else was just a decoy. Now, before we tell you exactly how the app can figure this out so quickly, we need a little background information, so i've cornered my buddy jabril here and i'm gon na make him give us a super, simple explanation of machine learning. Now, here's what you should know about jabril he's basically a genius who taught himself how to code when he was 14.. He has an amazing youtube channel.

You should check out with videos like this one, where he made a video game where the character teaches himself how to navigate any maze using machine learning and neural networks. Alright, let's say we have timmy here and timmy likes certain type of toys, but not others. So, in a fake example, here he decides it's based on how big the toy is and how complicated it is so from small to big and then over here how many parts it has from just one piece to a really complex toy with gears and moving parts And things like that, and so if we ask timmy about 20 different toys and start to plot those on the graph will start to see a pattern. So generally, he likes toys that are big and complicated, but does not like toys that are small and simple, and so by looking at his past preferences, we can make really good predictions for the future.

If you show little timmy here, a toy that is this complicated and this big we're confident that he'll like it before, we show it to him because it is inside the like boundary. That's the big deal with machine learning. We don't have to take the time and show little timmy here. Every toilet's ever been created and record his answers after we record some likes and dislikes we're able to draw some boundaries, and precisely where we draw these boundaries is the secret sauce.

In this case, with just two inputs, you can just eyeball it and see where to put the boundaries, but when you have thousands of inputs that interact with each other, it's impossible for our brains to comprehend where those boundaries should go. However, it's pretty trivial for a computer, using machine learning in doing research for this video i talked to probably over 50 baseball players and coaches, and when we asked about signs, it was surprising to me how they all basically used the same strategy, see if you could Pick up on it, every coach has an indicator. I have an indicator, so i could do all this. You know random stuff, like this touch anywhere until i touch this.

None of that matters so it'll be indicator in the next sign. That's a hot sign! So it's indicator arm steel. If i just do the arm, that's nothing. Oftentimes i'll give this simon didn't say if i go indicator and then immediately to anywhere on my arm.

Steal bunt is to the bell indicator. The bell so basically nothing matters and it's all a decoy until they touch the indicator and then the very next sign is the instruction. So after the indicator, you might be told to bunt or to take a pitch or to steal, and so since the steel sign comes immediately after the indicator, we just look at a sequence where steel was recorded here, that showing is one. Then we look through.

That sequence, two letters at a time and store those combos. Then we do the same thing for all: the sequences where steel was recorded and whatever two-letter combo shows up in all of them is their indicator and steel sign. In this case, it's a d. So if we decode that that means nose is their indicator and chin is their steel sign.

Now i have a confession. What i just showed you doesn't use machine learning at all. It's just a simple algorithm. We realize would work once we discover that pretty much all teams will use an indicator directly before giving the real sign, but based off all the people we talk to if you're trying to decode signs.

This simple version should work like 90 of the time, but what about the other 10, where they do anything other than indicator, followed by sign? That's where you need machine learning, because, if done properly, machine learning can crack any code as long as you give it enough. Training data so to really see how good jabril's machine learning app was. I generated some training data based off an insanely, complicated steel sign. I came up with to see if he could figure it out.

So my secret sign was a mustache rub. Is the indicator followed by any random sign and then a tooth tap as the steel sign, then i can have up to 50 different signals in each sequence and then to throw them off even more. If i ever touch my right eyebrow, it's not a steal. So you ignore everything in the sequence, even if i've already given this deal sign now just to set the stage if we weren't going to use machine learning.

This would take a normal computer thousands of years to solve, because it's the same as if you're asking timmy about every toy ever made, instead of just drawing the boundaries before we see, if gabriel can successfully crack my code and how long it will take him. Let's just go one layer deeper than the timmy toy example and see how machine learning mimics the human brain in creating neural networks that can draw those boundaries. In the more complicated case of more than two inputs, there are three main parts to a neural network and hang with me here, because i'm going to keep this simple, you have the input layer which in our case, are the signs being given and then way over Here you have the output layer, in our case steel or nose, steel and then in the middle. We have the hidden layers and right now, that's just a black box.

So if the sign was hat hat nose hand, we would tweet these input. Knobs like this, depending on how each of these knobs is turned, each one is interconnected with the knobs to its left, so it causes some simple math to occur at each node and when you sum up all of those numbers, you're left with a number between 0 And 1., if that number is really close to zero, that's no steel and if the number is really close to one, that's a steal, so you give it a bunch of training data where given an input, you know what the output should be. You start with these hidden layer: knobs turned in totally random directions and when you add them all up, you get something like 0.55. Well that doesn't make sense, you can't have half a steal and, more importantly, with the training data.

You know the answers and you know that this combination should have been a steal, so you just start tweaking these hidden layer knobs until you start to get outputs that are more correct over time. After going through a bunch of examples where you know what the answer should be, eventually you get to a point where any more tweaking of the knobs just makes it less accurate. So you stop so now you super glue these three hidden layer, knobs into place because you've trained your model and so now, with the brand new input, where you don't know the answer, it gives you the correct output, in this case a steel of course. This is a simple model, but this scales up, so you could have thousands of inputs and thousands of outputs and you're able to discover really complicated relationships.

What's so cool about this is this is basically how neural networks in our own brains are set up to learn. Once i've been given enough training data to understand the interaction between my hand and arm and keeping something balanced like this, then my model is trained and i super glue those middle knobs in my brain. Then i can introduce a totally new input. I've never tried before, and i still know what to do.

I don't need to be trained on every possible different type of object, because my brain has drawn the boundaries think about that. For a long time before machine learning and neural networks, computers were just following hard-coded instructions given by humans. Now they can learn like humans only they can do it much faster and more comprehensively than we can obligatory and that's why, when i gave jabril the challenge that would take a normal computer using brute force methods, thousands of years to solve yo man, that's fast. Please tell me that your indicator is a mustache robe and then you have whatever and then a toothpick is that it that's it gibral's machine learning, algorithm just created the right boundaries and solved it in less than three minutes.

The machine learning model requires more data than our simple version, which can solve it after, like three sequences, but the upside is that it will eventually decode any set of signs as long as you're capturing the inputs right and so now it was time for a real Life test, so i asked my buddy destin to do some secretive, recon work: okay, dude! This is the field i used to play at growing up today. My son is playing on the rascals. I'm gon na go film third base, coaches doing their thing and we'll plug all that data into the machine learning algorithm. These kids are yelling at me wanting me to know what my channel is and the fact they didn't recognize.

Him just proved to me that whatever was happening in this region was a totally effective disguise and thanks to dustin's great interviews and raw footage, we were able to get even more data to show that our methods totally worked and while destin just brazenly set up a Tripod and filmed all these third base coaches before you do that you need to talk to them. So that's what i'm doing yeah, because signs are pretty secret right, yeah! Oh yes! Yes, sir! I got in trouble for stealing signs. I was a little more nervous and discreet. If you put a gopro in a cup, you can actually just watch the footage and frame the shot real time and it just looks like you're checking, dank memes with a drink.

In your hand, i've actually used this trick. A few times, especially on my carnival, scam, science, video so just like with destin's footage, it worked perfectly at the games i went to and it was just a cool feeling once you've cracked their code to be able to predict exactly what was coming next there. He goes, i knew he was gon na steal. I knew it.

I hope you enjoyed this excuse to learn more about machine learning. As much as i did. I will put links to both versions of the app in the video description for you to check out and, of course, if there are specific rules against using technology to steal signs in your league, i am not telling you to break them. Otherwise, from personal experience, you might risk getting some very important people mad at you.

You.

12 thoughts on “Stealing baseball signs with a phone (machine learning)”
  1. Avataaar/Circle Created with python_avatars Connor Chin says:

    I’m liking all the comments that have to do with the astros, they stole a title from the dodgers. GO DODGERS!

  2. Avataaar/Circle Created with python_avatars GodAppel says:

    "Of course this is a simple model"
    Me: still wondering how he connected them to each other

  3. Avataaar/Circle Created with python_avatars A Minister’s Grandsons says:

    My team we do we need a pitcher not a belly icher

    And we also did

    We need a batter not a broken latter

  4. Avataaar/Circle Created with python_avatars Roger Dudra says:

    I knew getting my degree in computer science would be handy. This handy is flat out hilarious.

  5. Avataaar/Circle Created with python_avatars Paul Dzhugostran says:

    The near cord pathomorphologically multiply because cherry suggestively realise beyond a guiltless friction. broken, grotesque advantage

  6. Avataaar/Circle Created with python_avatars Andy Edwards says:

    Baseball coaches of the future: Okay so today we're going to teach you how to do RSA in your head

  7. Avataaar/Circle Created with python_avatars Andy Edwards says:

    The knob board model was sweet, I think you could have gone into the basics of how backpropagation is used to tweak the knobs!

  8. Avataaar/Circle Created with python_avatars MattManiac says:

    This just in… Astros bench coach downloads app, let's catcher know, and the catcher hurls the ball into center field.

  9. Avataaar/Circle Created with python_avatars Leo says:

    so did anything in baseball shift from the app coming out? any articles or notable events all because of this video?

  10. Avataaar/Circle Created with python_avatars Jon says:

    When he says multiple times here is the ‘simple’ explanation and you’re still confused the whole time lol

  11. Avataaar/Circle Created with python_avatars Juanita Cognito says:

    Is a baseball fan I do not like this this is cheating but the astros would love it

  12. Avataaar/Circle Created with python_avatars CringeBoi9000 says:

    50% of comments: Trastros
    40%: people that don’t understand baseball
    10%: other

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.