config and download script are added

This commit is contained in:
yunjey
2017-03-21 01:06:34 +09:00
parent 4fc2b1fa8a
commit ba7d5467be
2 changed files with 35 additions and 0 deletions

View File

@ -0,0 +1,26 @@
class Config(object):
"""Wrapper class for hyper-parameters."""
def __init__(self):
"""Set the default hyper-parameters."""
# Preprocessing
self.image_size = 256
self.crop_size = 224
self.word_count_threshold = 4
self.num_threads = 2
# Training
self.num_epochs = 5
self.batch_size = 64
self.learning_rate = 0.001
self.log_step = 10
self.save_step = 1000
# Model
self.embed_size = 256
self.hidden_size = 512
self.num_layers = 2
# Path
self.image_path = './data/'
self.caption_path = './data/annotations/'
self.vocab_path = './data/'

View File

@ -0,0 +1,9 @@
wget http://msvocds.blob.core.windows.net/annotations-1-0-3/captions_train-val2014.zip -P data/
wget http://msvocds.blob.core.windows.net/coco2014/train2014.zip -P data/
wget http://msvocds.blob.core.windows.net/coco2014/val2014.zip -P data/
unzip data/captions_train-val2014.zip -d data/
unzip data/train2014.zip -d data/
rm data/train2014.zip
unzip data/val2014.zip -d data/
rm data/val2014.zip