Vision: ZeroDivisionError when running example code on own dataset

All those cases look like problems of very small dataset. Can you share some more information like the number of elements in your training set, your batch size, the number of elements in train_dl?