I have a CustomDataset that subclasses torch.utils.data.Dataset.
Due to some third-party library specs, I have an unusual situation where I need the data in CustomDataset to be stored in a directory in an ImageFolder readable format.
What’s the easiest/cleanest way to achieve this?
Many thanks
If you need to store the data in the “folder layout” expected by ImageFolder, you could either move the data to the root and subfolders or create symbolic links instead.
Can you explain what do you mean by move the data to the root and subfolders? The CustomDataset contains custom data that I did not load from a folder but created from scratch
Yes, I am creating the data from scratch and have it in the form of a pytorch Dataset and I was wondering if there’s a simple way to “export” it into an ImageFolder compatible format.
I imagine I can do this “manually” myself, but I wanted to know if there’s some existing functionality that can easily dump a Dataset into the desired format, as the ImageFolder format is common.