Benjamin Devèze (3) [Avatar] Offline
Let’s take a look at the output of one of these generators: it yields batches of 150x150 RGB images (shape (32, 150, 150, 3)) and binary labels (shape (32,)). 32 is the number of samples in each batch (the batch size).

32 should be replaced by 20 to be consistent with the batch_size used in the code.