Skip to content

Latest commit

 

History

History
38 lines (24 loc) · 1.06 KB

README.md

File metadata and controls

38 lines (24 loc) · 1.06 KB

Text Classification

Tensorflow implementation of some text classification models.

Dependencies

  • Python 3.6
  • Tensorflow == 1.14.0

Usage

Datasets

  • The datasets (imdb, yelp-13, yelp-14, yelp15) are collected and processed by Duyu Tang, and the resources can be downloaded here.
  • The glove word embedding.

Training & Evaluating

To preprocess the dataset (make sure all the data are in correct directories)

python data_helpers.py

To train the model (please check all the hyper-parameters)

python train.py

To evaluate the trained model

python eval.py

Models

fastText, CNN, RNN w/o attention, RCNN, GatedNN, HAN, DMN