Reimplementation of https://arxiv.org/pdf/1610.02391.pdf in Tensorflow 2.1.
- Max Holmberg
- Joel Lidin
The datasets and word2vec files for the sentiment classification can be found here:
- https://www.kaggle.com/rtatman/glove-global-vectors-for-word-representation?select=glove.6B.200d.txt
- https://www.kaggle.com/c/movie-review-sentiment-analysis-kernels-only/data
Put the files in a folder called dataset-text with the following structure:
- dataset-text/train.tsv
- dataset-text/test.tsv
- dataset-text/glove.6B.200d.txt
python run.py --path image_path --output output_path
python run.py --text --output output_path --weights sentiment_cnn_weights/cp.ckpt --sentence "I love this movie"
Original | Heatmap overlay (predicted: Mountains) |
---|---|
Original | Heatmap overlay (predicted: Egyptian cat) |
---|---|
Original | Heatmap overlay (predicted: Curly coated retriever) |
---|---|