lmoroney / dlaicourse

Notebooks for learning deep learning
5.66k stars 5.36k forks source link

fixed error name 'train_dir' is not defined ,wrong code order #40

Open elsieyin opened 5 years ago

elsieyin commented 5 years ago

NameErrorTraceback (most recent call last)

in () ----> 1 train_horses_dir = os.path.join(train_dir, 'horses') # Directory with our training horse pictures 2 train_humans_dir = os.path.join(train_dir, 'humans') # Directory with our training humans pictures 3 validation_horses_dir = os.path.join(validation_dir, 'horses') # Directory with our validation horse pictures 4 validation_humans_dir = os.path.join(validation_dir, 'humans')# Directory with our validation humanas pictures 5 NameError: name 'train_dir' is not defined fixed this error by editing the position of this code: `# Define our example directories and files train_dir = '/tmp/training' validation_dir = '/tmp/validation'` using colab editing, so upload and delete files, since seems in colab, one can't choose 2ndary directory to safe files.
JonathanSum commented 5 years ago

Hi, if you can, could you tell me which exercise under which course? Maybe you did not run the block above.