Skip to main content
Added additional explanation.
Source Link

The problem might be in the generate_samples() generator: This yields only 1024*8 (=8192) samples. If I replace the line

for i in range(1024*8):

by

while True:

so that an infinite amount of samples is generated, your example works on my machine.

Since generate_samples() only yields 8192 samples, train_batches_stream only yields 32 batches of 256 samples each, so that you can only train for at most 32 steps. However, you ask for 2000 steps.

The problem might be in the generate_samples() generator: This yields only 1024*8 (=8192) samples. If I replace the line

for i in range(1024*8):

by

while True:

so that an infinite amount of samples is generated, your example works on my machine.

The problem might be in the generate_samples() generator: This yields only 1024*8 (=8192) samples. If I replace the line

for i in range(1024*8):

by

while True:

so that an infinite amount of samples is generated, your example works on my machine.

Since generate_samples() only yields 8192 samples, train_batches_stream only yields 32 batches of 256 samples each, so that you can only train for at most 32 steps. However, you ask for 2000 steps.

Source Link

The problem might be in the generate_samples() generator: This yields only 1024*8 (=8192) samples. If I replace the line

for i in range(1024*8):

by

while True:

so that an infinite amount of samples is generated, your example works on my machine.