diff options
-rwxr-xr-x | cdcgan.py | 17 |
1 files changed, 10 insertions, 7 deletions
@@ -2,13 +2,14 @@ from __future__ import print_function, division import tensorflow as keras import tensorflow as tf -from tensorflow.keras.datasets import mnist -from tensorflow.keras.layers import Input, Dense, Reshape, Flatten, Dropout, multiply -from tensorflow.keras.layers import BatchNormalization, Embedding, Activation, ZeroPadding2D -from tensorflow.keras.layers import LeakyReLU -from tensorflow.keras.layers import UpSampling2D, Conv2D -from tensorflow.keras.models import Sequential, Model -from tensorflow.keras.optimizers import Adam +import tensorflow.keras as keras +from keras.datasets import mnist +from keras.layers import Input, Dense, Reshape, Flatten, Dropout, multiply +from keras.layers import BatchNormalization, Embedding, Activation, ZeroPadding2D +from keras.layers import LeakyReLU +from keras.layers import UpSampling2D, Conv2D +from keras.models import Sequential, Model +from keras.optimizers import Adam import matplotlib.pyplot as plt import matplotlib.gridspec as gridspec @@ -243,6 +244,8 @@ class CDCGAN(): return train_data, test_data, val_data, labels_train, labels_test, labels_val +''' if __name__ == '__main__': cdcgan = CDCGAN() cdcgan.train(epochs=4000, batch_size=32) +''' |