Im trying to load the saved weight from my model so that i can use it to make predictions But i keep getting this error AttributeError: 'NoneType' object has no attribute 'predit_classes'
I know that the code i have tried is mainly for model used like this: model = Sequential() but i dont know how else to go about it.
test_model=model.load_weights('second_try.h5')
img = load_img('0008_00_00_01_219.jpg',False,target_size=(150,150))
x=img_to_array(img)
x = np.expand_dims(x, axis=0)
img_class = test_model.predict_classes(x)
print ("Class:", img_class)
model.load_weightsreturns a value -- in which case the error message describes exactly what's going on.