simontomaskarlsson/CycleGAN-Keras

Recreating night2day results

Closed this issue · 6 comments

Hi! I'm interested in recreating the results you're showing in the main page.
On which dataset have they been obtained?
Have you got any script to automatically download such dataset and create the train and test folders as mentioned in the README?

I just noticed the answer you gave on Issue #1.
Is it possible however to have some insight on the size of the dataset and on the training time?

Hi @mattsim,

For the night<-->day translation we used 1508 day and 1999 night images for training. A full training session was 200 epochs which I believe took about 12 hours using a Nvidia GeForce GTX gpu. You can read a lot more about the work here:
http://liu.diva-portal.org/smash/get/diva2:1216606/FULLTEXT01.pdf

Hi @simontomaskarlsson, your work is really fascinating. Firstly, I want to appreciate your work.

I just want to understand the data and its structure which you have mentioned in the readme.md file

Directory structure on new dataset needed for training and testing:
data/Dataset-name/trainA
data/Dataset-name/trainB
data/Dataset-name/testA
data/Dataset-name/testB
  1. could you please let us know, what exactly the folder trainA, trainB, testA, testB contains?
  2. As you have mentioned you have used 1508 day images and 1999 night images for training. have you placed day images inside the trainA folder and night images into trainB folder? or combined together?
  3. did you capture both day and night images for the same location?

I can answer the question to atone for my guilt of not closing the issue earlier :)

  1. The data folder marked as "A" (trainA and testA) should belong to the fist domain (e.g., day images) while the ones marked with "B" (trainB and testB) to the other domain (e.g., night images).
    The images in the "train*" directory are used during training, the images in the "test*" folders, for validation instead (i.e., check the results of the GANs after each epochs).

  2. The images in the two folders has to be different. You should split your images with a 80-20 proportion or something like that.
    For instance, say you have 2000 day images and 2000 night images, then 1600-1800 day images should go in trainA, the remaining in testA, 1600-1800 night images should go in trainB, the remaining in testB.

  3. No, you want to use this method if you have unpaired images (i.e., a bunch of day images and night images, not picturing the same scenes, please have a look here and here. If you have paining, you should have a look at the GANs with style transfer literature instead.

Hope this was helpful. Cheers!

Great answer @mattsim, thank you!

Hey @mattsim, really thanks a lot for your answer :)
I have captured 10 static camera locations day and night. I hope this should be fine.
@mattsim @simontomaskarlsson, do you have the recent version of the code? TensorFlow or PyTorch anything is fine.