我成功地在我的本地主机上运行scikit学习预测模型,现在我有兴趣将此模型添加到我的烧瓶静态网站。我怎样才能做到这一点?有什么建议么?我基本上想在flask静态网站上添加一个链接到预测模型。如何将scikit预测模型链接到flask静态网站?
例如
静态的网站在本地主机上运行:5000具有下面的代码
@app.route('/index')
def index():
return render_template('index.html')
`@app.route('/model')` #This code is wrong but I am trying to add my
`def model():` #model here
return url_for('localhost:8080')
@app.route('/contactus')
def contactus():
return render_template('contactus.html')
显示正是你想要与你的预测模型 –
做什么,我想将它添加到@ app.route并创建一个标签这就是我想要的做 – Waleed