This project performs sentiment analysis on IMDB movie reviews using a Convolutional Neural Network (CNN).
- Implemented in Python with TensorFlow/Keras.
- Redesigned from a previous Google Colab version to run locally without Colab.
- Includes data preprocessing, model training, evaluation, and sample predictions.
- Structured for easy understanding and reproducibility.
| File | Description |
|---|---|
train.py |
Loads data, trains the CNN, and evaluates accuracy |
model.py |
Defines the CNN architecture |
preprocess.py |
Loads IMDB dataset, tokenizes and pads sequences |
requirements.txt |
List of Python packages needed |
.gitignore |
Excludes unnecessary files (e.g., .idea/, CSV) |
randum_30line.py |
sample dataset |
- Uses IMDB Reviews dataset from TensorFlow Datasets.
- The raw CSV dataset is NOT included due to licensing.
A small random subset (30 reviews) of the IMDB Dataset is included for testing purposes.
Full dataset is downloaded automatically by train.py.