December 2018
Intermediate to advanced
268 pages
8h 23m
English
The train method shares common code with DCGAN with a few critical changes—we need to collect our data for our batch generator differently and we need to train each one of the discriminators we just developed (four in total):
def train(self): for e in range(self.EPOCHS): b = 0 X_train_A_temp = deepcopy(self.X_train_A) X_train_B_temp = deepcopy(self.X_train_B) while min(len(X_train_A_temp),len(X_train_B_temp))>self.BATCH: # Keep track of Batches b=b+1
Because the batch represents a single image, it isn't strictly required that each domain contain the same number of images. Now, this means that ...
Read now
Unlock full access