2016-11-02 552 views

回答

5

爲了簡化,你可以說,通常有4個主要步驟,模型時(不只是在Keras):

  • 建立模型,並編譯它:model.compile()
  • 訓練模型訓練數據:model.fit()
  • 評估與測試數據模型:model.evaluate()
  • 使你的目標數據的預測:)model.predict(

根據您需要的輸出,您將不得不使用model.predict_proba()或model.predict_classes()。

請參閱https://keras.io/models/sequential/#sequential-model-methods以獲取完整的參考和參數。

Keras知識庫也有很多例子:https://github.com/fchollet/keras/tree/master/examples

相關問題