Slide 5
Slide 5 text
Introduction
Fast Forward to 2018: bird or not?
# Initialize pre-trained model (ImageNet)
model = ResNet50()
# Load image and transform for model input
x = load_img(img_path, target_size=(224, 224))
x = img_to_array(x)
x = np.expand_dims(x, axis=0)
x = preprocess_input(x)
# Predict and decode
preds = model.predict(x)
print(Pred:', decode_predictions(preds, top=1))
5
● Python
● < 50 lines (with comments)
○ Core solver is just 7 lines
● Keras library
● ImageNet
https://github.com/dekked/bird-or-not
Bird!
NOT Bird!