dataset = dataset.batch(50)
dataset = dataset.prefetch(buffer_size=1)
Is it prefetch 1 batch or 1 element?
Per the API document in tensorflow, the buffer_size is the max num of elements prefetch. But it seems it is num of batch after batching the dataset.