Momin Ahmed

Math + CS @ HKUST

Comp 2211 | Momin Ahmed

Comp 2211

Introduction

There are projects that I worked on as part of the course Comp2211 - Exploring AI at HKUST. I have uploaded the files on github here .

I have uploaded both the .ipynb colab files (which are without my solved code) along with the .py files (which are included my solved code). The resources folder contains some review material along with datasets. I have uploaded these because I think the course gives a great overview of many AI concepts and it will be helpful to at least me, but hopefully someone else too, in brushing up on pandas and tensor flow skills when needed.

Below I will provide a short introduction of the concepts covered, you can click here to scroll down to a specific topic:

Naive Bayes Classifier

Naives Bayes Classifier uses simple probability rules along with a naive assumption of indepedence.

The idea is simple. From our dataset, we can calculate the probalitiies that a certain inputs were true, or had certain values, given a specific event occured - and from this we want to find the probabilitiy that the event will occur, give a list of input values. To remove some abstraction, consider we know the stats of 100 cancer patients and their symptoms. Then, given some symptoms of a new patient, we want to caluculate the probability of this new person having cancer.

In lab2, we use this Naive Bayes Classifier to see how likely a person will be prone to a spam call given certain attributes such as marital status, loan etc.

K-Means Clustring and K-Nearest Neighbours

In Programming Assignment 1, we start off with a classification problem of classifying certain trees based on their properties in a forest.

K-Means Clustering is an unsupervised classification algorithm that classfies data by building clusteres based on some definition of “distance”. We start off by picking random centroids for clusters (a naive apporach) and we by taking the mean we keep on tweaking the centroids of “k circles”

K-Nearest Neighbours is a simple classfying algorithm where, for any new input, we look at it’s K nearest previous known data points - then we just take classification of the majority of those k neighbours.

Multi-Layer Perceptrons

A MLP is an artifical neural network where the goal is to choose the right activation function, and find the right weightings and biases that conect each neuron. This is achieved by the idea of back propagating the error that tweeks these parameters to match the given output with the expected output.

In lab6, we have the prices of properties in hong kong over time. We want to build this MLP model to predict the future prices so that we could invest smartly.

Convolutional Neural Network

In CNN, we expand the idea of MLP to make it useful for working on digital images. Essentially, CNN allows our neural network to have “spacial” distinction since an MLP can only take a vector as an input and it does so by introducing a convolution layer which goes through the image to detect certain features.

Image Classfiication

In lab8, we construct a CNN model to input an animal image and classify the image into the preset categories - including cats, dogs, giraffes etc.

Figure Detection

This project was inspired by: https://github.com/facebookresearch/AnimatedDrawings.

In Programming Assingment 2, we use this idea to detect (draw borders around) the sketch of a figure drawn. We can further process that to make the figure “dance”.

Minimax and Alpha Beta Pruning

Minimax and alpha beta pruning is probably my favourite among all these concepts (simply because it’s quite simple, yet doesnt make many assumptions). This decision making algorithm is usually used in two player “games” for example tic-tac-toe, or more impressively, chess. The idea behind Alpha Beta purning is to not waste computational power computing every state again.

In lab9, we were already given an almost working code - we had to simply correct the errors.

Final Remarks

Working on projects in thie course was quite fun and rewarding. I have given a very brief overview here and probably working on these uplaoded projects will only be useful to someone just starting to learn or re-learn these concepts.