Neural networks (classification)

Definitions

Input: value that goes in

Weight: a thing that multiplies its input by some value

Perceptron: adds up all the inputs and activates (activation function) after a certain threshold is met

Bias: a constant value added to a node

Simple neural network

Inputs go in → weights are multiplied → only fires after a certain threshold → it then gets added together.

Here is an example implementing a regression model.

Example implements an OR

slide 1
slide 2

Example implements an AND

slide 1
slide 2

Downsides to a single layer perceptron

The reason we can do AND and OR is because it is binary and linear.

Multi-layer perceptron (MLP)

Note each line has a weight

Multi-layer example

Common Configurations

Stuff on hidden layers

The hidden layers does not normally classify stuff.

They can also represent real world values, or have their own activation functions ect…

Training

Is when you adjust the weights and biases to get the desired output.

Basic idea to adjust the weights (Back propagation)

  1. Start with random weights
  1. Check how different it is to the desired output
  1. Adjust each weight to get better results
  1. Check again and repeat

How to adjust the structures topology

  1. He didn’t say…. but its clearly imporatant

Gradient Decent

Approaches:

Back propagation is a variation of stochastic gradient decent, for multi-layer networks.

Parameter selection

Note the first arg is how many neurons in one layer.
Typically it gets better with more neurons then it slowly gets worse.

How big are the jumps between each epoch (learning cycle).

Activation function. (relu is used in image classification)

Solver.

What can go wrong