I want to use a for loop to plot images with fastai show_image.
If I do something like in the example below, it firstly plots all the images, and then all the text, while I want the text Sample No. to be put below each image, as it should be since it is in the same iteration of a for loop.
(here, img is an image as in the first entry of a valid_ds tuple)
for sampleN in range(samples):
show_image(img)
print('Sample No. '+str(sampleN))