Keras-GAN
Keras-GAN copied to clipboard
ImportError: No module named 'data_loader'
from future import print_function, division import scipy
from keras.datasets import mnist from keras_contrib.layers.normalization import InstanceNormalization from keras.layers import Input, Dense, Reshape, Flatten, Dropout, Concatenate from keras.layers import BatchNormalization, Activation, ZeroPadding2D from keras.layers.advanced_activations import LeakyReLU from keras.layers.convolutional import UpSampling2D, Conv2D from keras.models import Sequential, Model from keras.optimizers import Adam import datetime import matplotlib.pyplot as plt import sys from data_loader import DataLoader import numpy as np import os
=================================================
ImportError Traceback (most recent call last)
ImportError: No module named 'data_loader'
Are you trying to use the pix2pix library? Try creating a file named "__init__.py" in the directory.
The file data_loader.py
should be in the same directory.
It appears you are also working through the (fantastic) Manning series "GANs in Action". Your code appears to be the final section, on CycleGANs. The authors note that the data_loader is provided in their GitHub repo for the chapter. Check out their workbook here: https://github.com/GANs-in-Action/gans-in-action/blob/master/chapter-9/Chapter9_CycleGAN.ipynb