Dear @Robi thanks for this notebooks!!
I followed the instructions on this thread and could run your notebooks with no problem.
But, in lesson 1, I’m see some warnings and finally wrong predictions that I would like to show you so you can tell me what could be wrong.
First, in MODEL CREATION when I run:
model = VGG_16()
I get the following warning:
/home/edu/anaconda2/envs/deep_learning_1/lib/python3.6/site-packages/keras/layers/core.py:665: UserWarning: `output_shape` argument not specified for layer lambda_1 and cannot be automatically inferred with the Theano backend. Defaulting to output shape `(None, 3, 224, 224)` (same as input shape). If the expected output shape is different, specify it via the `output_shape` argument.
.format(self.name, input_shape))
Then in the In [19] I run this code:
batches = get_batches('train', batch_size=batch_size)
val_batches = get_batches('valid', batch_size=batch_size)
imgs,labels = next(batches)
# This shows the 'ground truth'
plots(imgs, titles=labels)
and I get this warning:
/home/edu/anaconda2/envs/deep_learning_1/lib/python3.6/site-packages/matplotlib/text.py:1191: FutureWarning: elementwise comparison failed; returning scalar instead, but in the future will perform elementwise comparison
if s != self._text:
It will still show pictures of Dogs / Cats with 0/1 as labels.
Finally the code for predictions
pred_batch(imgs)
Will produce the following results from two images from a DOG and a CAT:
Shape: (2, 1000)
First 5 classes: ['tench', 'goldfish', 'great_white_shark', 'tiger_shark', 'hammerhead']
First 5 probabilities: [0.0008 0.0004 0.0013 0.0005 0.0016]
Predictions prob/class:
0.0093/bucket
0.0048/book_jacket
I can’t understand why it’s not working.
Thank you very much in advance!
Edu