Google ML Crash Course
What is Rule #1 of the Rules of Machine Learning?
Rule #1: Don’t be afraid to launch a product without machine learning.
Google ML Crash Course
What are “labels”
A label is the thing we’re predicting - the y variable in simple linear regression. The label could be the future price of wheat, the kind of animal shown in a picture, the meaning of an audio clip, or just about anything.
Google ML Crash Course
What variable is often used to represent the label
y when used for an input label or y' when used as the predicted label
Google ML Crash Course
What are “features”?
A feature is an input variable - the x variable in simple linear regression. A simple machine learning project might use a single feature, while a more sophisticated machine learning project could use millions of features, specified as:
x₁, x₂, ..., xₙ
In the spam detector example, the features could include the following:
Google ML Crash Course
What variable(s) are often used to represent features?
x or x₁, x₂, ..., xₙ
Google ML Crash Course
What are “examples”?
An example is a particular instance of data, x (we put x in boldface to indicate that it is a vector.) WEe break examples into two categories:
A labeled example includes both feature(s) and the label. That is:
labeled examples: {features, label}: (x,y)An unlabeled example contains features but not the label. That is:
unlabeled examples: {features, ?}: (x, ?)Once we’ve trained our model with labeled examples, we use that model to predict the label on unlabeled examples. In the spam detector, unlabeled examples are new emails that humans haven’t yet labeled.
Google ML Crash Course
What variable(s) are often used to represent an example?
Google ML Crash Course
What is a “model”?
A model defines the relationship between features and label. For example, a spam detection model might associate certain features strongly with “spam”.
Google ML Crash Course
What are phases in a “model“‘s life cycle?
y')Google ML Crash Course
What is the difference between regression and classification”?
Google ML Crash Course
Suppose you want to develop a supervised machine learning model to predict whether a given email s “spam” or “not spam”. Which of the following statements are true?
2 & 3 are true:
Google ML Crash Course
Suppose an online shoe store wants to create a supervised ML model that will provide personalized show recommendations to users. That is, the model will recommend certain pairs of shoes to Marty and different pairs of shoes to Janet. The system will use past user behavior data to generate training data. Which of the following statements are true?
1 & 4 are true:
2 & 3 are false:
Google ML Crash Course
What is the equation for a simple linear regression model with a single feature?
y' = b + w₁x₁
Where:
y' is the predicted label (desired output).b is the bias (the y-intercept), sometimes referred to as w₀.w₁ is the weight of feature 1. Weight is the same concept as the “slope” m in the traditional equation of a line.x₁ is a feature (feature number 1, a known input)This can be used to infer (predict) the value of y' for a given value x₁ in a model that has been trained (has learned the values for b and w₁)
Google ML Crash Course
If y' = b + w₁x₁ is the equation for a linear regression model with a single feature, what is the equation for a model with three features?
y' = b + w₁x₁ + w₂x₂ + w₃x₃
Google ML Crash Course
What is a simple definition for “Training”
In the context of Supervised Learning
Training a model simply means learning (determining) good values for all the weights and the bias from labeled examples. In supervised learning, a machine learning algorithm builds a model by examining many examples and attempting to find a model that minimizes loss; this process is called empirical risk minimization.
Google ML Crash Course
What is “Loss”
Loss is the penalty for a bad prediction. That is, loss is a numb er indicating how bad the model’s prediction was on a single example. If the mode’s prediction is perfect, the loss is zero; otherwise, the loss is greater. The goal of training a model is to find a set of weights and biases that have low loss, on average, across all the examples.
Google ML Crash Course
What is the squared loss or **L₂ loss” function for a single example of a linear-regression model?
The square of the difference between the label and the prediction.
loss = (y - y')²
Google ML Crash Course
What is the “Mean square error (MSE)” ?
The average squared loss (a.k.a. L₂ loss) per example over the whole dataset. To calculate MSE, sum up all the squred losses for individual examples and then divide by the number of examples.
Google ML Crash Course
Google ML Crash Course