All Projects → tetrahydrofuran → presidential-rnn

tetrahydrofuran / presidential-rnn

Licence: other
Project 4 for Metis bootcamp. Objective was generation of character-level RNN trained on Donald Trump's statements using Keras. Also generated Markov chains, and quick pyTorch RNN as baseline. Attempted semi-supervised GAN, but was unable to test in time.

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to presidential-rnn

Pytorch Sentiment Neuron
Stars: ✭ 178 (+584.62%)
Mutual labels:  rnn, nlp-machine-learning
Codesearchnet
Datasets, tools, and benchmarks for representation learning of code.
Stars: ✭ 1,378 (+5200%)
Mutual labels:  rnn, nlp-machine-learning
Predicting Myers Briggs Type Indicator With Recurrent Neural Networks
Stars: ✭ 43 (+65.38%)
Mutual labels:  rnn, nlp-machine-learning
Natural Language Processing With Tensorflow
Natural Language Processing with TensorFlow, published by Packt
Stars: ✭ 222 (+753.85%)
Mutual labels:  rnn, nlp-machine-learning
timeline
Takes tweets from a bot's followings and markovifies them. Ruby port of sneaksnake/timeline
Stars: ✭ 13 (-50%)
Mutual labels:  markov-chain
4chanMarkovText
Text Generation using Markov Chains fed by 4chan APIs
Stars: ✭ 28 (+7.69%)
Mutual labels:  markov-chain
AALpy
An Active Automata Learning Library Written in Python
Stars: ✭ 60 (+130.77%)
Mutual labels:  markov-chain
Markov-Word-Generator
A web app that uses Markov chains to generate pseudorandom words.
Stars: ✭ 33 (+26.92%)
Mutual labels:  markov-chain
pypmc
Clustering with variational Bayes and population Monte Carlo
Stars: ✭ 46 (+76.92%)
Mutual labels:  markov-chain
danifojo-2018-repeatrnn
Comparing Fixed and Adaptive Computation Time for Recurrent Neural Networks
Stars: ✭ 32 (+23.08%)
Mutual labels:  rnn
markov-discord
A Markov chain Discord chat bot. Generates unique messages by learning from past messages. Also occasionally attaches images to messages.
Stars: ✭ 35 (+34.62%)
Mutual labels:  markov-chain
SimInf
A framework for data-driven stochastic disease spread simulations
Stars: ✭ 21 (-19.23%)
Mutual labels:  markov-chain
deep-learning-notes
🧠👨‍💻Deep Learning Specialization • Lecture Notes • Lab Assignments
Stars: ✭ 20 (-23.08%)
Mutual labels:  rnn
marc
Markov chain generator for Python and/or Swift
Stars: ✭ 61 (+134.62%)
Mutual labels:  markov-chain
Selected Stories
An experimental web text editor that runs a LSTM model while you write to suggest new lines
Stars: ✭ 39 (+50%)
Mutual labels:  rnn
PyBorg
Fork of PyBorg AI bot for cutie578 on EFNet
Stars: ✭ 45 (+73.08%)
Mutual labels:  markov-chain
Vietnamese-Accent-Prediction
A simple/fast/accurate accent prediction for non-accented Vietnamese text
Stars: ✭ 31 (+19.23%)
Mutual labels:  markov-chain
Online-Signature-Verification
Online Handwriting Signature Verification using CNN + RNN.
Stars: ✭ 16 (-38.46%)
Mutual labels:  rnn
Mathematical-Modeling
A sharing of the learning process of mathematical modeling 数学建模常用工具模型算法分享:数学建模竞赛优秀论文,数学建模常用算法模型,LaTeX论文模板,SPSS工具分享。
Stars: ✭ 30 (+15.38%)
Mutual labels:  markov-chain
py-simple-lyric-generator
A simple Markov chains lyric generator written in Python.
Stars: ✭ 17 (-34.62%)
Mutual labels:  markov-chain

Presidential RNN

This respository trains and executes a character-level recurrent neural network using GRUs on President Donald Trump's tweets and official recorded statements and speeches. Equivalent Markov chains are also trained, to limited effect.

Running the Repository

The primary entry points for this repository are main.py and markov.py. They may be accessed by the command python [filename].

Running main.py as-is will load and transform both tweets and statements, training 6 and dumping RNN models each for a total of 12 models. This is extraordinarily computationally expensive.

Running markov.py will generate frequency tables and sentences given a seed. Frequency table generation is an expensive task, and may take hours.

Pre-trained models are stored in /data/models/ in h5py format and may be used directly.

Full Dependencies

Core Functionality

  • keras
  • sklearn
  • pandas
  • numpy
  • unidecode

EDA Functionality (topic modeling, visualizations, etc.)

  • gensim
  • yellowbrick

Repository Structure

  • bin - Source code files
    • pytorch - pyTorch implementation of GRU, unoptimized for CUDA or GPU
  • data
    • clean - Cleaned data, stored in serialized format
    • models - Trained char-RNNs, stored in h5py format
    • markov - Markov chain frequency tables and sample output
  • docs - Slides and supporting documentation for project

Contact

Feel free to contact me with feedback or questions.
Email - lzhou95 at gmail .com
LinkedIn - zhouleon
Medium - @confusionmatrix

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].