This repository contains three projects: a simple HMM Viterbi algorithm, a N-Gram algorithm and a EM algorithm implementation.
- This project defines a Hidden Markov Model and uses Viterbi extending HMM to implement the Viterbi algorithm on the given HMM.
- This project has two files, hmm.py and viterbi.py.
- Type into your command line
python viterbi.pyfrom the project directory to execute the program
- This project takes a given text and parses it to create a ngram model of the corpus. It can be used to provide the most common word following a given word in short phrases of upto 3-4 words effectively.
- This project has a sample text warandpeace.txt that can be replaced with any other corpus.
- Type into your command line
python ngram.pyfrom the project directory to execute the program
- This project is an implementation of the EM noisy-OR algorithm for CSE 150 under Prof. Saul Lawrence in UCSD.
- This project has the files em_noisyor.py, hw6_x.txt, hw6_y,txt.
- Type into your command line
python em_noisyor.pyfrom the project directory to execute the program