title: Keras Valueerror: This model has never been called
body: <p>This should be very simple Keras program.  It works until the last line of code.  But I have called the predict method.  Granted I used the same input data as the training data, but that should not matter.</p>
  
  
  
  <pre class="lang-python prettyprint-override"><code>from keras.models import Sequential
  import pandas as pd
  
  url = 'https://raw.githubusercontent.com/werowe/logisticRegressionBestModel/master/KidCreative.csv'
  
  data = pd.read_csv(url, delimiter=',')
  
  labels=data['Buy']
  features = data.iloc[:,2:16]
  
  model = Sequential()
  model.compile(optimizer='rmsprop' ,loss='binary_crossentropy',metrics=['accuracy'])
  model.fit(data, labels, epochs=10, batch_size=32)
  model.evaluate(labels, features, batch_size=128)
  model.predict(labels)
  model.summary()
  </code></pre>
  
  <p>But I get this error:</p>
  
  <pre class="lang-python prettyprint-override"><code>model.summary()
  Traceback (most recent call last):
    File "&lt;stdin&gt;", line 1, in &lt;module&gt;
    File "/home/walker/tf3/lib/python3.4/site-packages/keras/engine/network.py", line 1263, in summary
      'This model has never been called, this its weights '
  ValueError: This model has never been called, this its weights have not yet been created, so no summary can be displayed. Build the model first (e.g. by calling it on some test data).
  </code></pre>