Docsity

Machine Learning CT explained review Exam, Study Guides, Projects, Research of Machine Learning

Toggle sidebar
bg1
Machine Learning CT
Leave the first rating
Students also studied
Save
Flashcard sets Study guides
Comprehensive Data Science and M...
28 terms
Becca_Marie811
Preview
Comprehensive Neural Networks an...
114 terms
leenashafi2026
Preview
AI System Audit Lifecycle: Phases a...
27 terms
nonyekwe2000
AI Syst
26 terms
non
Well-posed Learning Problem A computer program is said to learn from (E)xperience E with respect to some
(T)ask T and some (P)erformance measure P, if its performance on T, as measured
by P, improves with experience E.
Machine Learning Field of study that gives computers the ability to learn without being explicitly
programmed.
Machine Learning broad definition Field of study that gives computers the ability to learn without being explicitly
programmed.
Abstract Essence of ML Representation + Evaluation + Optimisation
Machine Learning Learning from experience. It's also called supervised learning, were experience E
is the supervision.
Pattern Recognition Finding patterns without experience. It's also called unsupervised learning.
Terms in this set (232)
Hide definitions
pf3
pf4
pf5
pf8
pf9
pfa

Partial preview of the text

Download Machine Learning CT explained review Exam and more Study Guides, Projects, Research Machine Learning in PDF only on Docsity!

Well-posed Learning Problem A computer program is said to learn from (E)xperience E with respect to some (T)ask T and some (P)erformance measure P, if its performance on T, as measured by P, improves with experience E.

Machine Learning Field of study that gives computers the ability to learn without being explicitly programmed.

Machine Learning broad definition Field of study that gives computers the ability to learn without being explicitly programmed.

Abstract Essence of ML Representation + Evaluation + Optimisation

Machine Learning Learning from experience. It's also called supervised learning, were experience E is the supervision.

Pattern Recognition Finding patterns without experience. It's also called unsupervised learning.

Unsupervised Learing - We only have xi values, but no explicit target labels.

  • You want to do 'something' with them.

Unsupervised Learning Tasks - Outlier detection: Is this a 'normal' xi?

  • Data visualization: What does the high-dimensional X look like?
  • Association rules: Which xij occur together?
  • Latent-factors: What 'parts' are the xi made from?
  • Ranking: Which are the most important xi?
  • Clustering: What types of xi are there?

Classification ML task where T has a discrete set of outcomes. Often classification is binary. Examples:

  • face detection
  • smile detection
  • spam classification
  • hot/cold

Regression ML task where T has a real-valued outcome on some continuous sub-space Examples:

  • Age estimation
  • Stock value prediction
  • Temperature prediction
  • Energy consumption prediction

Labels Values that h aims to predict Example:

  • Facial expressions of pain
  • Impact of diet on astronauts in space
  • Predictions of house prices

Training algorithm Given a model h with Solution Space S and a training set {X,Y}, a learning algorithm finds the solution that minimizes the cost function J(S)

Features/Attributes Measurable values of variables that correlate with the label y Examples:

  • Sender domain in spam detection
  • Mouth corner location in smile detection
  • Temperature in forest fire prediction
  • Pixel value in face detection

Cost Function Squared error cost function. J(S)

Local minima The smallest value of the function. But it might not be the only one.

Curse of Dimensionality The curse of dimensionality refers to how certain learning algorithms may perform poorly in high-dimensional data.

First, it's very easy to overfit the the training data, since we can have a lot of assumptions that describe the target label (in case of supervised learning). In other words we can easily express the target using the dimensions that we have.

Second,we may need to increase the number of training data exponentially, to overcome the curse of dimensionality and that may not be feasible.

Third, in ML learning algorithms that depends on the distance, like k-means for clustering or k nearest neighbors, everything can become far from each others and it's difficult to interpret the distance between the data points.

EXTREME Dimensionality Case In an extreme, degenerate case, if D > n, each example can be uniquely described by a set of feature values.

Hidden layer(s) can - Have arbitrary number of nodes/units

  • Have arbitrary number of links from input nodes and to output nodes (or to next hidden layer)
  • There can be multiple hidden layers

Hidden Unit Activation Common functions for are unit step, sigmoid or logistic and tanh

RELU Rectified Linear Unit New trend, responsible for great deal of Deep Learning success. Advantages:

  • No 'vanishing gradient' problem
  • Can model any positive real value
  • Can stimulate sparseness

Output layer can be • Single node for binary classification

  • Single node for regression
  • n nodes for multi-class classification

Network Topology Variations include:

  • Arbitrary number of layers
  • Fewer hidden units than input units (causes in effect dimensionality reduction, equivalent to PCA)
  • Skip-layer connections
  • Fully/sparsely interconnected networks

Training a network Training a NN involves finding the parameters that minimize some error function

Choice of activation function depends on the output variables:

  • Unity for regression
  • Logistic sigmoid for (multiple independent) binary classification
  • Softmax for exclusive (1-of-K) multiclass classification

NN Error Functions Regression:

  • Binary classification
  • Multiple independent binary Classification:
  • Multi-class classification (mutually exclusive):

Gradient points in the direction of Steepest Ascent

How to train ANN An error function on the training set must be minimized. This is done by adjusting:

  • Weights connecting nodes.
  • Parameters of non-linear functions h(a).

Eigenvalue Given an invertible matrix , an eigenvalue equation can be found in terms of a set of orthogonal vectors , and scalars such that: M

Derivative Measure of how fast function value changes withe the change of the argument. So if you have the function f(x)=x^2 you can compute its derivative and obtain a knowledge how fast f(x+t) changes with small enough t. This gives you knowledge about basic dynamics of the function

Gradient Gradient shows you in multidimensional functions the direction of the biggest value change (which is based on the directional derivatives). So given a function i.e. g(x,y) = -x+y^2 you know, that it is better to minimize the value of x, while strongly maximize the value of y. This is a base of gradient based methods, like steepest descent technique.

Regularization Regularization is a technique used in an attempt to solve the overfitting problem in statistical models.

Regularization - Maximum likelihood generalization error (i.e. cross-validation)

  • Regularized error (penalize large weights)
  • Early stopping

Deep Learning - Basically a Neural Network with Many hidden layers

  • Can be used for unsupervised learning and dimensionality reduction

What is Deep Learning? Definition:

  • Hierarchical organization with more than one (non-linear) hidden layer in-between the input and the output variables
  • Output of one layer is the input of the next layer

Deep learning methods (Deep) Neural Networks

  • Convolutional Neural Networks
  • Restricted Boltzmann Machines/Deep Belief Networks
  • Recurrent Neural Networks

Convolutional Neural Networks Type of feed-forward artificial neural network in which the connectivity pattern between its neurons is inspired by the organization of the animal visual cortex, whose individual neurons are arranged in such a way that they respond to overlapping regions tiling the visual field.

How is deep neural network optimized? Optimized through gradient descent! (Forward-Backward algorithm)

  • Penalize complex solutions to avoid overfitting

Cost function - ℓ2 norm In order to avoid over-fitting, one common approach is to add a penalty term to the cost function. Common choices are the ℓ2-norm, given as:

Where C0 is the unregularized cost

Cost function - ℓ1 norm

Dropout A very different approach to avoiding over-fitting is to use an approach called dropout. Here, the output of a randomly chosen subset of the neurons are temporarily set to zero during the training of a given mini-batch. This makes it so that the neurons cannot overly adapt to the output from prior layers as these are not always present. It has enjoyed wide-spread adoption and massive empirical evidence as to its usefulness.

Cost function - Euclidean distance Distance measure between a pair of samples p and q in an n-dimensional feature space

Cost function - Manhattan or City block distance Calculate the distance between real vectors using the sum of their absolute difference. Also called City Block Distance

Basic Decision Tree Decision trees apply a series of linear decisions, that often depend on only a single variable at a time. Such trees partition the input space into cuboid regions, gradually refining the level of detail of a decision until a leaf node has been reached, which provides the final predicted label.

Tree components Root node, branch, node, leaf node.

Branching Factor Branching factor of node at level L is equal to the number of branches it has to nodes at level L + 1

CART Classification And Regression Trees

Six general questions to decide on decision tree algorithm:

  1. How many splits per node (properties binary or multi valued)?
  2. Which property to test at each node?
  3. When to declare a node to be leaf?
  4. How to prune a tree that has become too large (and when is a tree too large)?
  5. If a leaf node is impure, how to assign a category label?
  6. How to deal with missing data?

Tree variaties Trees are called monothetic if one property/variable is considered at each node, polythetic otherwise

What trees are preferable? We prefer simple, compact trees, following Occam's Razor

How to make trees compact? To do so, we will seek to minimise impurity of data reaching descendent nodes

Occam's Razor All things being equal - the simplest explanation is the best

The Principle of Plurality Plurality should not be posited without necessity.

The Principle of Parsimony It is pointless to do with more what is done with less.

Misclassification Impurity Minimum probability that training example will be misclassified at node N

Bayes' Error - The Bayes Error rate is the theoretical lowest possible error rate for a given classifier and a given problem (dataset).

  • For real data, it is not possible to calculate the Bayes Error rate, although upper bounds can be given when certain assumptions on the data are made.
  • The Bayes Error functions mostly as a theoretical device in Machine Learning and Pattern Recognition research.

Missing Attributes It is common to have examples in your dataset with missing attributes/variables. One way of training a tree in the presence of missing attributes is removing all data points with any missing attributes. A better method is to only remove data points that miss a required attribute when considering the test for a given node for a given attribute. This is a great benefit of trees (and in general of combined models,)

ID3 Interactive dichotomizer version 3 Used for nominal, unordered, input data only. Every split has branching factor , where is the number of values a variable can take (e.g. bins of discretized variable) has as many levels as input variables

C4.5 - Successor of ID3.

  • Multiway splits are used.
  • Statistical significant split pruning.

Regression Trees - Trained in a very similar way

  • Leaf nodes are now continuous values - the value at a leaf node is that assigned to a test example if it reaches it
  • Leaf node label assignment is e.g. mean value of its data sample Problem: nodes make hard decisions, which is particularly undesired in a regression problem, where a smooth function is sought.

Model Combination View • Decision Trees combine a set of models (the nodes)

  • In any given point in space, only one model (node) is responsible for making predictions
  • Process of selecting which model to apply can be described as a sequential decision making process corresponding to the traversal of a binary tree

Random forests 1. Very good performance (speed, accuracy) when abundant data is available.

  1. Use bootstrapping/bagging to initialize each tree with different data.
  2. Use only a subset of variables at each node.
  3. Use a random optimization criterion at each node.
  4. Project features on a random different manifold at each node.

Measures of classification accuracy Classification Error Rate Cross Validation Recall, Precision, Confusion Matrix Receiver Operator Curves, two-alternative forced choice

Estimating hypothesis accuracy Sample Error vs. True Error Confidence Intervals

Sampling Theory Basics Binomial and Normal Distributions Mean and Variance

Comparing Hypotheses t-test Analysis of Variance (ANOVA) test

Simple data splits - Fixed train, development and test sets

  • Bootstrapping
  • Cross-validation

Fixed train, development and test sets - Randomly split data into training, development, and test sets.

  • Does not make use of all data to train or test
  • Good for large datasets

Bootstrapping Estimating the sampling distribution of an estimator by resampling with replacement from the original sample.

Cross-validation - Randomly split data into n folds and iteratively use one as test set

  • All data used to test, and almost all to train
  • Good for small sets

Evaluation procedure for single split or cross validation - For large datasets, a single split is usually sufficient.

  • For smaller datasets, rely on cross validation

Overfitting can occur when - Learning is performed for too long (e.g. in Neural Networks)

  • The examples in the training set are not representative of all possible situations (is usually the case!)
  • Model parameters are adjusted to uninformative features in the training set that have no causal relation to the true underlying target function.

Confusion Matrix Easy to see if the system is commonly mislabelling one class as another

Classification measures - Error Rate Common performance measure for classification problems

  1. Success: Instance's class is predicted correctly (True Positives (TP) / Negatives (TN)).
  2. Error: Instance's class is predicted incorrectly (False Positives (FP) / Negatives (FN)).
  3. False positives - Type I error. False Negative - Type II error.
  4. Classification error rate: Proportion of instances misclassified over the whole set of instances.

F-measure Comparing different approaches is difficult when using multiple evaluation measures (e.g. Recall and Precision) F-measure combines recall and precision into a single measure

accuracy (TP + TN)/ (TP + TN + FP + FN)

accuracy may not be useful measure in cases where 1- There is a large class skew 2- There are differential misclassification costs - say, getting a positive wrong costs more than getting a negative wrong. 3- We are interested in a subset of high confidence predictions

TPR - True Positive Rate - Recall TP/actual Positive = TP/TP + FN

False Positive Rate FP/actual negative = FP/TN + FP