Artificial Intelligence

It is a form of intelligence shown by computers, unlike humans. It is created by both Machine Learning and Rule based approaches.

Applications:

  1. Robotics:
    • Boston Dynamics Spot Robot uses onboard AI to avoid obstacles and generate shortest path to a location
  2. Playing games:
    • DeepMind uses AI to beat world champions in Go (Alpha Go), Chess (Alpha Zero) and even in all 57 Atari games (Agent 57)
    • OpenAI Five has won 99.4% of matches in Dota 2 within 3 days using Reinforcement Learning
  3. Computer Vision:
    • Tesla Autopilot has achieved full self driving capabilities with just few cameras and sensors
  4. Biology:
    • Alpha Fold 2 can generate protein structures with more than 90% accuracy
  5. Natural Language Processing (NLP):
    • Google translate is a highly complex AI model which can translate any language

Machine Learning in Depth

Rule based: A particular problem is solved with set of rules.

flowchart of rule based approach

Machine Learning (ML): It is a way of teaching machines to solve problem using data, rather than doing explicit coding for each situation.

Types of Machine Learning:

  1. Supervised Learning - consumes data with proper labels
  2. Semi-supervised Learning - requires partial data
  3. Unsupervised Learning - works by clustering similar data
  4. Reinforcement Learning - based on environments, policies, rewards

Types of Algorithms in Machine Learning:

  1. Classification - classes
  2. Regression - range
  3. Clustering - groups
  4. Sequence Prediction - recommendations
  5. Style Transfer - filters/translators

Deep Learning (DL): It is a part of Machine Learning which tackles any problem (in theory) using interconnected nodes (neurons / weights & biases). It is highly flexible, adaptable and even mimics human brain.

Deep Learning

Neural Networks (NN): It is a form of arranging artificial nodes to emulate human neurons. Here artificial neurons are nothing but mathematical values manipulated by doing few transformations and dot products.

Neural Networks

History of ML

  1. AI winter: It is period of time where AI was has having a lot of attention but no one ever took it seriously (implementation).
  2. Big Data: In 80’s and 90’s data was produced but due to limited computational power and low quality of data, AI never took off.
  3. Technology: Now we have very fast accessible computational power, good quality big data, and improved algorithms.

Parallel Distributed Processing (PDP)

  1. A set of processing units
  2. A state of activation
  3. An output function for each unit
  4. A pattern of connectivity among units
  5. A propagation rule for propagating patterns of activities through the network of connectivities
  6. An activation rule for combining the inputs impinging on a unit with the current state of that unit to produce an output for the unit
  7. A learning rule whereby patterns of connectivity are modified by experience
  8. An environment within which the system must operate

Limitations of Machine Learning

  1. Model requires some amount of good data
  2. Data collected should also contain labels
  3. Model learns only patterns which exist in the dataset
  4. Model only predicts outcomes of the classes, not recommended actions.
  5. Feedback loops: Few models are biased towards a region of the dataset, when the model retrained on the new data, It tends to go in a loop where model gets more and more biased

Overfitting

It is a major problem while creating an ML/DL model. Often times, model tends to memorize the input data which later leads to overfitting.

Overfitting is a situation when a model can only predict trained dataset accurately compare to raw data (real world data/testing dataset)

Proper Fit and Overfitting

As you can see from above picture, proper fit can give less variance compare to the overfit model.

Variance → average error over set of experiments (better solution if variance is less)

We can avoid these issues by constantly evaluating the model with the validation dataset and stop the training if it shows steady decrease over epochs on validation accuracy. If it happens then try to randomize or improve or generate better data.

Transfer Learning & Its applications

Transfer Learning: It is a process of reusing the pretrained model to achieve an new objective in much faster rate and with better accuracy.

Applications: (below examples used computer vision models)

  1. Sound recognition is done by creating spectrograms

    Sound Recognition

  2. Fraud detection by converting mouse behavior to an image

    Fraud Detection

  3. Malware classification with Deep Convolutional Neural Networks Process:

    Malware Classification Process

    Few examples:

    Malware Classification Examples

Keywords, Notations, & Few Jargons

  • Architecture- structure of model (Layer arrangments and number of neurons in each layer or simple outline of the model or internal structure)
  • Parameters- Other name for weights (artificial neurons)
  • Loss- way of finding the negative performance
  • Independent variables- Input to the model (e.g. flatten layer of images)
  • Targets- dataset labels
  • Predictions- After model training, the final output after passing the inputs.
  • Labels- the data we want to predict
  • Epochs- number of times model needs to train
  • Fit- function to start training the model with input data and labels
  • Loss- A measure of how good model is, chosen to drive training via SGD
  • Metric- A measure for humans to come to conclusion on how well model is performing on testing dataset
  • CNN- Convolutional Neural Networks are similar to original NN but has filters/convolutions in the architecture
  • Validation set- Part of dataset which is kept aside for evaluating model before doing final evaluations on testing set.
  1. Practical Deep Learning : https://course.fast.ai/
  2. Tutorials of ML : https://machinelearningmastery.com/
  3. Quality ML Information : https://www.youtube.com/c/ArxivInsights
  4. Latest ML News : https://www.youtube.com/c/YannicKilcher