ImageFolder dataloading guidance
Hi I have all images in óne folder and a txt file in which class information is there. Apologies for asking a basic question but I am not able to extract labels from the data loader even I tried converting it into a json file. Please can anyone share a tutorial if they have worked with image data in which all the images are in a single folder.
2022-12-15T12:03:13Z
You can write some Python code to put the images in folders based on their classes, as this is the format that ImageFolder requires.
2022-12-16T02:35:02Z
You can create a metadata.jsonl file containing labels(class information) and image paths and then add the metadata file to the folder containing all images. Documentation ishere. Sharing the txt file format can help you get a more clear answer.