All right.
I know what you're thinking.
You're thinking, Andre.
I have no idea what you're talking about.
What is machine learning?
You haven't really told me anything.
I have nothing to apply to.
Well, let's go back to this topic of machines and computers and the fact that they don't really understand
words.
Right.
If I ask my computer, hey, is this a snake?
Is this a python?
My computer is going to have no idea what I'm talking about.
When I look at an image of a snake, no matter what color it is, no matter whether it's a cartoon or
a real life image, or whether it has different directions with different animals in it, I can identify
a snake right away.
Our brains just know.
But to tell my computer what a snake is.
Is almost impossible, right?
Because there's so many factors.
A snake doesn't have legs and arms, but.
An airplane doesn't have legs and arms.
A snake has scales, but then the computer is going to ask me, what are scales?
But with machine learning, we can actually teach a computer to know what a snake is, or at least pretend
like it knows.
So how do we do this?
Well, you remember this diagram, I hope.
It's simply what we do in programming.
That is, we give an input, let's say a list of one, two, three, we give it to a function and there's
an output of two, four, six.
So clearly this function multiplies our list items in our list by two.
And often our programs are procedural.
That is we have if this then that do this, then this type of conditions, we tell the computer what
to do.
We write as programmers the input.
And the function and all the computer does is actually just calculate using the input and the function,
the output, and it can do that really, really fast for us instead of having a human do something when,
let's say a list is millions of items long.
Machine learning changes this idea.
It says, Hey, give me the input and give me what you want the output to be.
That is, give me all the data that you have.
And by the way, tell me what the answer is, or at least what the output that you want.
So in this case, I want the input to be a list of one, two and three and the output to be a list of
two, four and six.
And then the interesting part is that as developers, we give this input and output.
But with machine learning, we say, Hey, machine, you figure out what this function is.
Because if I give you, let's say instead of a list, a list of all these snake pictures or maybe animals,
and I want you to tell me if this image has a snake or not, or maybe these 100 images, which one of
them have snakes?
Well, I don't know how to tell you how to do that.
So instead, you figure it out yourself.
Here are all the pictures.
And here is what I expect the output to be.
Either snake or not.
Snake.
And with machine learning the function is generated or created by the machine.
Sounds really cool, doesn't it?
And this is machine learning.
It's simply a function.
So instead of us writing the function like we have before with machine learning, the machine writes
the function.
We just give it the input and the output and the word function can be replaced with a model.
You might have heard of the word machine learning model.
That's all a model is.
It's a function that receives an input and returns an output.
Another word might be algorithm, a machine learning algorithm, a machine learning bot.
And at the end of the day, it's a brain.
We're pretending that this machine is a brain that understands the inputs and gives us the desired output.
Now, the interesting side effect of this is that often when we talk about machine learning models,
these functions are really hard to understand because the computer comes up with this function as a
human, it's hard to really understand how it works.
And as these models get more and more complex, it becomes harder and harder for us as developers to
understand how it works.
Which raises a lot of issues, but we don't need to get into that now.
As you can see, the main part of this is that in order to train this machine, to create this function,
we have to give it data.
And for it to be really, really good, we have to give it lots and lots of data.
And then we want to test to make sure that this data that we give in gives us the correct output.
So at the end of the day, machine learning is simply a computer writing its own function based on the
inputs and outputs.
That's pretty cool, isn't it?
I'll see you in the next video.
Bye bye.