Very Weird error,No such file or directory: '/content/dataset/4738.jpg'

Trying to build an autoencoder that can find similiar images.
I can’t figure out why/where the dataloaders are figuring there is a file called 4738.jpg. I can’t even find the source of the mistake. Help please!

So I found the error, and it is very silly. When I was looping through the image files which are named 0.jpg to 4737.jpg, I took the length of the dataset which is 4738, and used it is the range.
There is no image with the name 4738.jpg though, and that’s where the error was coming from.

1 Like