Implementation of Attend to You: Personalized Image Captioning with Context Sequence Memory Networks
- Work in progress *
- Python 3.5
- TensorFlow > 1.10
- Other requirements - check requirements.txt
conda create -name attend2u python=3.5 pip
conda activate attend2u
pip install -r requirements.txt
Download Instagram dataset.
JSON file &
Images
Save the files to ${project_root}/data
Example of /data directory structure
├── data
│ ├── caption_dataset
│ ├── hashtag_dataset
│ ├── images
│ ├── json
│ ├── resnet_pool5_features
-
Download ResNet trained model
Run scripts/download_pretrained_resnet_101.sh -
Extract images features
Run scripts/extract_features.sh -
Configure the network
Edit model parameters, training/evaluation parameters and data paths in configs.py -
Train
Run train.py
python train.py -
Evaluate
Run eval.py
python eval.py
Original code : https://github.com/cesc-park/attend2u
Coco evaluation tools for Python 3 : https://github.com/Illuminati91/pycocoevalcap