top of page

HarvardX's Computer Science for Artificial Intelligence Professional Certificate

Course 1: Introduction to Computer Science

  • Arrays, Algorithms, Memory and Data Structures in C

  • SQL

  • Python

  • HTML, CSS, JavaScript

  • Flask

  • Theory on Ethics, Security, and Artificial Intelligence

  • Final Project

Course 2: Introduction to Artificial Intelligence with Python

  • Searching Algorithms: Depth First Search, Breadth First Search, A*Search, GBFS

  • Knowledge Representation: propositional logic, first-order logic

  • Handling Uncertainty: Probability distributions, Bayes' Rule and Bayesian Network, inferences by enumeration vs sampling, Markov Chain Models, Hidden Markov Models

  • Optimisation: Local minimum/ maximum search, node and arc consistency, backtracking search.

  • Learning: Supervised learning, perceptron learning, SVM, regression, loss functions, overfitting, regularisation, reinforcement learning, Q-learning, unsupervised learning

  • Neural Networks: activation functions, network structure, gradient descent, backpropagation, overfitting, TensorFlow, convolution

  • Natural Language Processing: Parsing text, Question Answering

1_IYCifTCCR2ah-79u94Z3wg.png
courtyardedge.bmp
stadiumedge.bmp
edgeyard.bmp

A Few Selected Assignments from "Introduction to Computer Science"

By clicking on the download button, you will download a .zip file with the programme files.

Cryptography

In C - this homework was about encryption. I wrote a programme that asks the user to provide a key (26-characters) and then encrypts any text the user may enter according to the key.

Implementing a Tideman Voting System

In C - this assignment was about creating an algorithm that would determine a winner in a ranked-choice system. The Tideman method works by constructing a “graph” of candidates, where a winner and loser is determined for each pair of candiates. Pairs are added by strength of victory. The loser is "pointed at" in the graph. Once the graph is complete, the source of the graph (the one with no edges pointing towards it) is the winner!

Image Filtering, Blurring, Reflecting and Edge Detection

In C - this task asked me to create functions that will change a *.bmp image's pixel values so that the image is either:

  • turned into greyscale

  • reflected (flipped)

  • blurred (with a 3x3 matrix)

  • highlighting edges (with the sobel operators Gx and Gy as 3x3 filter matrix)

Image Recovery from Memory Card

In C - this task dealt with file handling. A memory card file was read and searched for 4-byte JPEG starting sequences. JPEGS were then written to new, individual JPEG files.

Implementing a Hash Table

In C - In a Spell-Check assignment, I created 5 functions that:

(1) load a every word of a given dictionary into a hash table via a hash function,

(2) implements a hash function (in my case, I used a simple function that multiplies the ASCII values of each word's letter by its word position and then applies the modulo with a large prime number),

(3) check each word of a given text such as the US constitution or 1million bytes of Tolstoy's War&Peace against the dictionary to spell-check it, 

(4) keep track of the size of the dictionary,

(5) unloads all allocated memory again

Implementing DNA Profiling

In Python - this assignment required me to read a database of people (incl. information about repetitions intheir DNA) into memory and a given DNA sequence of interest. The programme asks the user for those two input arguments (a database and a DNA sequence) and it identifies if there is an exact match with someone in the database. This is done by iterating over the given sequence to find the maximum of consecutive repeats of every DNA-snip for which information is stored in the database. 

Creating a Website with HTML, CSS, JavaScript

In HTML, CSS, JS - this task asked me to create a simple homepage that integrates four html pages, javascript functions, a few bootstrap components, interactive elements and a few stylesheets. My site included videos, a quiz, a review table for my favourite books, and an image gallery.

Credit Card Number Validation 

In C, and in Python - this programme takes a number as input and then tells the user whether the number is VISA, MasterCard, American Express or Invalid. The focus is input handling and pattern identification. This programme was first implemented in C, and then again in Python (for practice). 

Database, Python and HTML integration with Flask 

In HTML and Python (Flask) - As a first introduction to flask and the MVC (Model, View, Controller) design pattern I implemented a simple HTML page that allows a user to enter their name and birthday into a form, which then stores and returns those values in a table via database in the background.

Building a Flask-Based Platform for buying, selling, quoting live Stocks

In HTML, CSS, and Python (Flask)  - This project mixes together flask, python, html, css and SQL. I created a flask-based web platform where new users can register and log in to view, buy and sell live stocks. The web application is supported through a sqlite database that keeps track of users, stocks and transactions. One of my favourite projects in this course!

cs50 x
cs50 ai

"Introduction to Artificial Intelligence with Python"

In the course of 7 units, I was introduced to a variety of different topics in the field of AI. Each unit consisted of a lecture covering theory, application fields, and pseudo-implementation, followed by a quiz and one or more projects. The vast majority of the time was spent solving the problem-sets, which was great hands-on practice.

This course helped me assemble my first neural network in TensorFlow, implement AI systems for natural language processing (even a basic system for question answering), creating a programme to train an AI to be unbeatable in a game of nim through reinforcement learning, or tic tac toe through Minimax logic, or Minesweeper through propositional logic.

Taking this course alongside my MSc Applied Geoinformatics has fit perfectly to help me dig a little deeper into the informatics side. Since the course was also highly project-oriented, I was able to constantly practice and refine my python programming. 

1.PNG
4.PNG
5.PNG
7.PNG
2.PNG
3.PNG
6.PNG
Some Video Demos

A system for Question Answering (Natural Language Processing)

Christina Zorenboehmer
A system for Question Answering (Natural Language Processing)
A system for Question Answering (Natural Language Processing)

A system for Question Answering (Natural Language Processing)

01:06
An AI to Parse Sentences and Extract Noun Phrases

An AI to Parse Sentences and Extract Noun Phrases

01:18
An AI to win at Minesweeper

An AI to win at Minesweeper

00:35
An AI to generate Crossword Puzzles

An AI to generate Crossword Puzzles

00:42
An AI that teaches itself to play Nim through reinforcement learning

An AI that teaches itself to play Nim through reinforcement learning

01:09
Trying to beat my programme at TicTacToe

Trying to beat my programme at TicTacToe

00:57

Assignments from "Introduction to AI with Python"

By clicking on the download button, you will download a .zip file with the programme files.

Shortest Path / Degrees of Separation

"Search" - A programme to determine how many degrees of separation there are between any two people in a dataset. In this project's example, I connected actors via movies they starred in, based on IMDB data. This programme returns the shortest path as a list of tuples describing the steps/ path. 

Implementing a Minimax Algorithm to build a programme that I cannot beat in TicTacToe

"Search" - In this problem-set I implemented python functions for optimal decision-making in a game of TicTacToe. The "AI" player is able to consider the current state of the game and evaluate all possible actions and counter-actions by an opponent by generating a utility value for all current and future moves. This is done following the minimax logic in which player A's goal is to minimise an outcome, while player B tries to maximise an outcome. Since implementing this, I have not been able to beat the programme (only tie or lose). 

A  Programme to solve Logic Puzzles (Knights & Knaves)

"Knowledge" - This task required the implementation of different actor's knowledge bases as well as a logical model checking algorithm to determine "lies" and "truths".

Propositional Logic for Knowledge-based Agent to Solve Minesweeper

"Knowledge" - This programme implements propositional logic in which an agent makes decisions by considering a knowledge base. The agent plays by making inferences and adding to/updating the knowledge base as the game progresses. On occasion, in minesweeper all "known" safe spots are exhausted and the agent must take a random chance - so this programme will not win every time, but it is able to consider all knowable information and make logical decisions. The only times it will fail is when it is forced to randomly choose and lands on a mine.

An AI to Rank Web Pages by Importance

"Uncertainty" - In this project, I calculated a given page's PageRank, by:

 

(1) a random-surfer model to mimic the behaviour of a hypothetical surfer on the internet who clicks through pages. This model can be interpreted as a Markov Chain where a page represents a state, and each page has a transition model that chooses among its links at random.

(2) an iterative algorithm to define a page's PageRank using a recursive mathematical expression to calculate the probability that a random surfer will end up on a given page. PR(p) = ((1 - d) / N) + dΣi (PR(i) / NumLinks(i))

PR: page rank, d: damping factor, N: total number of pages in corpus, i: ranges over all pages that link to page p, NumLinks(i) is number of links present in page i.

Heredity - An AI to Assess the Likelihood of having a Genetic Trait

"Uncertainty" - Here, I wrote functions that ultimately calculate probabilities that a given person has a genetic trait based on lineage, generic likelihoods, and whether or not a trait is observed in a person. Specifically, I wrote a function for joint probability calculation for every possible scenario given some facts about lineage and traits, and generated a probabilities dictionary to continuously update probabilities after each scenario and normalise the values to return a final probability distribution for each person on whether they have 0, 1, or 2 active genes and whether they do or don't show the trait.

Natural Language Processing: An AI to Answer Questions!

"Language" -  In this project, I created a simple question answering algorithm by pre-processing a corpus of documents and computing Inverse Document Frequency scores, then processing a user's question using Term-Frequency Inverse-Document-Frequency and ranking top documents and top sentences. Although this algorithm is only simple compared to what is used in many applications today, I really enjoyed testing this programme after I completed it! 

Reinforcement Learning - An Unbeatable AI at Nim

"Learning" - Using Q-Learning, this programme learns through reward values for every possible (state, action) pair in a game of Nim. It learns both the value for a current state and the best future reward. After a set of 10,000 training games, the programme is unbeatable at the game.

Arc-Consistency (Constraint Satisfaction) - Generating Crossword Puzzles

"Optimisation" - Given a corpus of words and a crossword structure, this programme returns a complete crossword solution. It checks every word for each position and enforces node- and arc-consistency i.e. that it fits the the space and to its neighbours. It favours words that allow for a maximum of neighbouring words to arrive at an overall solution faster. The programme implements an AC3 algorithm, checks for completeness, checks for consistency, orders all words by how many other words it matches with in the range of possible words, and backtracks to try to fill empty spaces (amongst other functions).

██████████████

███████M████R█

INTELLIGENCE

█ N █████ N ████ S █

█ F ██L O G I C ███ O

█ E █████ M ████ L █ 

█ R ███ S E A R C H █ V █

███████ X ████ E █ ██████████████

Predicting whether or not an Online Shopper will complete a Purchase

"Learning" - Given a range of features, this programme builds a nearest neighbour classifier to predict whether or not a new customer will complete an online purchase. The performance is measured in sensitivity and specificity.

A Convolutional Neural Network for Road Sign Recognition

"Neural Networks" -  In this project, I used TensorFlow for the first time to create a convolutional neural network to recognise road signs. 

Natural Language Processing: Parsing Sentences and Extracting Noun Phrases

"Language" -  In this project, I applied pre-processing steps to a given text (tokenising, stop word removal, lowercasing, punctuation removal), created a set of context-free grammar rules to parse a sentence and return an nltk tree that represents the syntax. The programme returns all possible "noun phrase" chunks.

bottom of page