Skip to content

Commit

Permalink
fixed readme example (#43)
Browse files Browse the repository at this point in the history
  • Loading branch information
wielandbrendel authored and jonasrauber committed Jul 22, 2017
1 parent 70b4c31 commit 60dd526
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -38,12 +38,13 @@ Example
import foolbox
import keras
import numpy
from keras.applications.resnet50 import ResNet50
# instantiate model
keras.backend.set_learning_phase(0)
kmodel = ResNet50(weights='imagenet')
preprocessing = (np.array([104, 116, 123])[None, None], 1)
preprocessing = (numpy.array([104, 116, 123]), 1)
fmodel = foolbox.models.KerasModel(kmodel, bounds=(0, 255), preprocessing=preprocessing)
# get source image and label
Expand Down

0 comments on commit 60dd526

Please sign in to comment.