# (Fall’23): CSCI-5930 Machine Learning

Graduate course, *SCIENCE-2001 (Tue only)*, 2023

Welcome to Machine learning course. What is machine learning? It is concerned with the question of how to write computer programs that automatically improve with experience. Over the very recent years, the field has expanded so much in every direction of our daily lives that we mostly are unaware of its existence. But, as a concerned citizen of the world, we are going to know the nuts and bolts of machine learning.

The course is based on fundamental knowledge of computer science principles and techniques, probability and statistics, calculus, and the theory and application of linear algebra. The course provides a broad introduction to pattern recognition from given data and how it can relate to machine learning. Topics include supervised learning, unsupervised learning, semi-supervised learning, neural network, and reinforcement learning algorithms. The course will also discuss recent applications of these machine learning concepts in solving real-world problems.

# Course objectives

By the end of the course you are expected to gain the following skills:

- Develop an understanding on how to extract patterns from data.
- Develop an understanding on a wide variety of machine learning algorithms – how the algorithms work, and their practical usages.
- Understand different types of optimization techniques, which are heavily utilized in many of the learning algorithms.
- Capable of discussing pros and cons of the learning algorithms.
- Be able to implement the covered algorithms in class by themselves using Python programming language.
- Apply the algorithms to solve real world problems.
- Understand and apply the principles of
`responsible AI`

system design:`fairness`

,`inclusiveness`

,`transparency`

,`reliability and safety`

,`privacy and security`

,`accountability`

,`limits of capabilities`

.

# Prerequisites

- The
`graduate standing`

.

# Schedule

### Week 1 [8/21/2023 – 8/25/2023]

- Introduction to Machine learning [ PDF ] [ Video-Recording, 19:46]
- I am wondering you want to become a data scientists [ PDF ] [Video-Recording, 17:00]
- Challenges with Machine learning system design [ PDF ] [Video-Recording, 26:09]
- Stories of Machine Learning [ PDF ][ Video-Recording, 58:06]
- Nuts and Bolts of Machine Learning (part 1): The types of learning [ PDF ][ Video-Recording, 34:31]
- Nuts and Bolts of Machine Learning (part 2): The task and the datasets [ PDF ] [ Video-Recording, 32:37 ]
- Nuts and Bolts of Machine Learning (part 3): How to tell the machine learning model is good? [ PDF ] [ Video-Recording, 52:21 ]
- Nuts and Bolts of Machine Learning (part 4): Exploratory Data analysis – a case study: House price prediction [ zip ] [ Video-Recording, 23:02 ]

### Week 2 [8/28/2023 – 9/1/2023]

- Regression, and Simple linear regression [ PDF, slides 1-24 ] [ Video-Recording, 45:24 ]
- Multiple Linear regression [ PDF, slides 25-32 ] [ Video-Recording, 27:18]
- Comments on calculating gradient of linear regression loss function [ PDF, slides 51 and onward ] [ Video-Recording, 16:18]
- Gradient Descend Algorithm [ PDF, slides 33-49 ] [ Video-Recording, 31:06 ]

### Weeks 3 [9/4/2023 – 9/8/2023]

- Evaluating Regression models [ PDF, slide 50 ] [ Video-Recording, 13:05 ]
- Introduction to classification, and kNN classifier [ PDF] [ Video-Recording, 53:06 ]
- Another look at evaluating linear regression models [Slide PDF] [ Video-Recording, 28:41]
- Bias-variance tradeoffs, Overfitting, Underfitting [Slide PDF] [ Video-Recording, 26:50 ] [ Another supporting slide]
- Dataset splits: training, testing, validation, cross-validation [Slide PDF] [ Video-Recording, 16:23 ]
- Label encoding, One-hot encoding [Slide PDF] [Video_Recording, 10:57]
- Animation of Gradient Descent code Zip

### Weeks 4 [9/11/2023 – 9/15/2023]

- Logistic regression for binary classification [Slide PDF] [ Video-Recording, 54:59]
- Binary to multi-class classification [Slide PDF][ Video-Recording, 52:24]
- Multi-label classification [Slide PDF][ Video-Recording, 50:31]

### Weeks 5 [9/18/2023 – 9/22/2023]

- Introduction to clustering [Slide PDF][ Video-Recording, 1:03:08]
- k-means clustering algorithm [Slide PDF][ Video-Recording, 1:05:18]
- Hierarchical clustering algorithm [Slide PDF] [ Video-Recording, 1:15:03 ]

### Weeks 6 [9/25/2023 – 9/29/2023]

- Principal Component Analysis (PCA) for Dimensionality Reduction [Link 1] [Notebook] [Video-Recording, 50:44]
- Naive Bayes Classifier : The Bayes’ Theorem [ PDF ] [ Video-Recording, 14:39 ]
- Naive Bayes Classifier : A simple math problem [ PDF] [ Video-Recording, 7:25]
- Naive Bayes Classifier : Idea behind the classification algorithm [PDF] [ Video-Recording, 11:47]
- Definition of Naive Bayes Classifier [ PDF ] [ Video-Recording, 10:01]
- Naive Bayes Classifier in action [PDF] [ Video-Recording, 22:01 ]
- Naive Bayes Classifier : few implementation facts [ PDF] [ Video-Recording, 5:42 ]

### Week 7 [10/2/2023 – 10/6/2023]

- Ensemble Learning [ PDF ] [ Video-Recording, 52:39 ]
- Ridge Regression [ PDF ] [ Video-Recording, 1:07:23 ]
- LASSO Regression [ PDF ] [ Video-Recording, 37:05]
- Support Vector Machines :: [ PDF ]
**Part 1**: The intuition [ Video-Recording, 16:07]**Part 2**: Formal introduction [ Video-Recording, 1:00:06]**Part 3**: Kernel tricks & Programming Support Vector machines from scratch [ Video-Recording 54:40], [ Jupyter Notebooks with both primal and dual form ]**Part 4**: Solving Support Vector Machines on a piece of paper [ Video-Recording, 22:46]

### Week 8 [10/9/2023 – 10/13/2023]

### Weeks 9 [10/17/2023 – 10/21/2023]

- Reinforcement Learning applications (a higher-level overview)
- Introduction to Reinforcement Learning with OpenAI-Gym [ Notebook/Slide ] [ Github-Repo ] [ Video-Recording, 37:11 ]
- Working with OpenAI-Gym environments [Notebook/Slides: ALE/Breakout, Blackjack, CarRacing, ALE/Pong, ALE/Riverraid ][ Github-Repo ] [ Video-Recording, 16:00 ]
- Making of an Intelligent CartPole agent [Notebook/Slides: Random CartPole Agent, Q-learning CartPole Agent][ Github-Repo ] [ Video-Recording, 48:27]
- Non-gym environment and Reinforcement learning from scratch [Notebook/Slides: Goal-vs-Hole-v0, Goal-vs-Hole-v1][ Github-Repo ] [ Video-Recording, 35:09 ]
- Multi-bandit problem [Notebook+slides: ashiskb@github link] [A supporting video lecture by Connor Shorten] [Reference study: SB-2]
- Markov Decision Process (MDP), Dynamic Programming for action selection intro [ Slides] [Video-Lecture by Dr. B] [Reference study: SB-3, 4]

### Week 10 [10/23/2023 – 10/27/2023]

- Introduction to Artificial neural networks (ANN) and deep learning [ PDF ] [Video Recording, 24:19]
- Artificial Neural Networks – the basics [ PDF ], [ Jupyter notebook ]
**The preliminaries**[ Video-Recording, 44:15 ]**The math, the backpropgation algorithm and the implementation**[Video-recording, 33:55]

### Week 11, 12 and 13 [10/30/2023 – 11/17/2023]

- Compute framework for Artificial Neural Network + Deep Learning [ PDF ] [Video Recording, 01:00:03]
- Tensorflow 2.0 [ PDF ] [Video Recording, 32:56]
- Introduction to Tensors [Jupyter Notebook] [Video Recording, 01:02:38]
- Backpropagation with Tensorflow 2.0 [Jupyter Notebook] [Video Recording, 01:08:55]
- Introduction to PyTorch [
**This is a 2 part video lecture:**]- A short lecture by Andrej Karpathy, former student of Prof. Fei Fei Li who works in the AI / Auto-pilot team at Tesla. Here he explains how PyTorch was used to develop the model. [Lecture video]
- Introduction to working with PyTorch – another deep learning compute framework and is not Tensorflow. [Jupyter Notebook] [Lecture recording]
- Neural nets with PyTorch [Lecture notebook] [Video Lecture]
- CNNs with PyTorch [Lecture notebook] [Video Lecture]
- Visualizing CNN components [Lecture notebook] [Video Lecture]

- Convolution Neural Network
- The intuition [ Notebooks ][Video Recording, 30:52]
- Convolution Operation, 1x1 conv, implementation aspects [Notebooks] [Video Recording, 01:27:10]
- The pooling layer [Notebook] [Video Recording, 11:11]
- Flattened layer and fully connected layer [Notebooks] [Video Recording, 14:08]
- Few examples [Notebooks] [Video Recording, 14:16]
- Epilog + comment on weight sharing property [Notebooks] [Video Recording, 09:02]

- Recurrent Neural Networks
- Introduction [Notebooks] [Video Recording, 38:20]
- Basic language modeling with Recurrent Neural Networks [Notebooks] [Video Recording, 29:15]
- Vanilla architecture of RNN [Notebooks] [Video Recording, 58:49]
- Long short term memory (LSTM) architecture of RNN [Notebooks] [Video Recording, 44:17]

- Transformers [ link to required study materials]
- Natural Language Processing (Part 1)