should be: num_batches_per_epoch = int(math.ceil(float(data_size) / batch_size))
should be:
num_batches_per_epoch = int(math.ceil(float(data_size) / batch_size))