I want to make a binary classifier that classifies the following:
Class 1. Some images that I already have.
Class 2. Some images that I create from a function, using the images of class 1.
The problem is that instead of pre-creating the two classes, and then loading them, to speed up the process I would like the class 2 images to be created for each batch.
Any ideas on how I can tackle the problem? If I use the DataLoader as usual, I have to enter the images of both classes directly, but if I still don't have the images of the second class I don't know how to do it.
Thanks.
torch.stackfunction