Hi all,
I have a question about pytorch and image denoising.
I’d like to code an image denoising. The problem is that we usually take the original images and add the noise.
Here’s an example:

.....
for i in range(50):

    total_loss = 0.0
    total_iter = 0

    myModel.train()
    for image, Nolabel in train_loader:
    
        noise = torch.randn(image.shape[0], 3, 128, 128) * noise_level
        image_n = torch.add(image, noise)
    
        image = image.cuda()
        image_n = image_n.cuda()

        optimizer.zero_grad()
        output = myModel(image_n)
    loss = loss_fn(output, image)
    .....


I don’t want to use that method. I have two folders, the first folder contains the images without noise (jpg format), the second folder contains the same images but with noise (jpg format). The two folders has the same number of images. How can I change the previous example to use both folders?