IntroductionMachine learning is the subfield of computer science that,according to ArthurSamuel in1959,givesomputerstheability tolearnwithout being explicitlyprogrammed.There are three types of machine learning algorithm: supervised learning,unsupervisedlearningandreinforcementlearning.Supervised learning:The computer is presented with example inputs and theirdesiredoutputs,givenbyateacher,andthegoal istolearnageneral rulethatmapsinputstooutputs.LinearRegression,LogisticRegression,DNNandCNN
Introduction Machine learning is the subfield of computer science that, according to Arthur Samuel in 1959, gives “computers the ability to learn without being explicitly programmed. There are three types of machine learning algorithm: supervised learning, unsupervisedlearning and reinforcement learning . Supervised learning: The computer is presented with example inputs and their desired outputs, given by a “teacher ”, and the goal is to learn a general rule that maps inputs to outputs. Linear Regression, Logistic Regression, DNN and CNN
IntroductionUnsupervised learning:No labels are given to the learning algorithm,leaving iton its owntofind structureinitsinput.Unsupervised learning canbeagoal initself(discoveringhiddenpatterns in data)or a meanstowardsanend(featurelearning).K-means,PCA,KNN.Reinforcementlearning:A computer program interacts with a dynamicenvironmentinwhichitmustperformacertaingoal(suchasdrivingavehicle)orplayingagameagainstanopponent).Theprogramisprovidedfeedbackintermsofrewardsandpunishmentsasitnavigatesitsproblemspace
Introduction Unsupervised learning: No labels are given to the learning algorithm, leaving it on its own to find structure in its input. Unsupervised learning can be a goal in itself (discovering hidden patterns in data) or a means towards an end (feature learning). K-means, PCA, KNN. Reinforcement learning: A computer program interacts with a dynamic environment in which it must perform a certain goal (such as driving a vehicle) or playing a game against an opponent). The program is provided feedback in terms of rewards and punishments as it navigates its problem space
General steps of machine learningExample:Load dataGoal:Predict thehousingprice.Input: (location, size, traffic, type, .", price)+labels+plaintextWe want to trainthe model based on the inputExtractfeaturesStep 1:labels+featurevectorsLoad data into computer.Train modellabels+predictionsEvaluate
General steps of machine learning Example: Goal: Predict the housing price. Input: ( location, size, traffic, type, .,price) We want to train the model based on the input. Step 1: Load data into computer
General steps of machine learningExample:Goal:PredictthehousingpriceLoad dataInput:(location, size, traffic, type, ..,price)1labels+plaintextStep 2:ExtractfeaturesExtractfeaturesReducethedimensiontoimprovethelabels+featurevectorsproblem of overfitting.Train modelForexample:Data size is 10000,the dimensionof input islabels+predictions1000, we want to predict the housing price.Usually,somedimensionsof inputhaveEvaluaterelationshipwitheachother,liketypeand sizeWe can use PCA to reduce the dimention
General steps of machine learning Example: Goal: Predict the housing price. Input: ( location, size, traffic, type, .,price) Step 2: Extract features Reduce the dimension to improve the problem of overfitting. For example: Data size is 10000, the dimension of input is 1000, we want to predict the housing price. Usually, some dimensions of input have relationship with each other, like type and size. We can use PCA to reduce the dimention
General steps of machine learningExample:Load dataGoal:Predictthehousingprice.Input: (location, size, traffic, type, .", price)+labels+plaintextStep 3:Trainmodel.ExtractfeaturesWeneedtofindanobjectivefunctionto evaluatethedifferencebetweenpredictionvalueandreallabels+featurevectorsvalue.TrainmodelThen use gradient descent to minimize theobjective function.Actually,there are somelabels+predictionsparametersintheobjectivefunctionandgradientdescent,suchasαandaEvaluate
General steps of machine learning Example: Goal: Predict the housing price. Input: ( location, size, traffic, type, .,price) Step 3: Train model. We need to find an objective function to evaluate the difference between prediction value and real value. Then use gradient descent to minimize the objective function. Actually, there are some parameters in the objective function and gradient descent, such as 𝜶 𝒂𝒏𝒅 𝝀