• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

thedataincubator/flask-framework: Basic template for using Flask on Heroku

原作者: [db:作者] 来自: 网络 收藏 邀请

开源软件名称:

thedataincubator/flask-framework

开源软件地址:

https://github.com/thedataincubator/flask-framework

开源编程语言:

HTML 90.6%

开源软件介绍:

Flask on Heroku

This project is intended to help you tie together some important concepts and technologies from the 12-day course, including Git, Flask, JSON, Pandas, Requests, Heroku, and Bokeh for visualization.

The repository contains a basic template for a Flask configuration that will work on Heroku.

A finished example that demonstrates some basic functionality.

Step 1: Setup and deploy

  • Git clone the existing template repository.
  • Procfile, requirements.txt, conda-requirements.txt, and runtime.txt contain some default settings.
  • There is some boilerplate HTML in templates/
  • Create Heroku application with heroku create <app_name> or leave blank to auto-generate a name.
  • Deploy to Heroku: git push heroku master
  • You should be able to see your site at https://<app_name>.herokuapp.com
  • A useful reference is the Heroku quickstart guide.

Step 2: Get data from API and put it in pandas

  • Use the requests library to grab some data from a public API. This will often be in JSON format, in which case simplejson will be useful.
  • Build in some interactivity by having the user submit a form which determines which data is requested.
  • Create a pandas dataframe with the data.

Step 3: Use Bokeh to plot pandas data

  • Create a Bokeh plot from the dataframe.
  • Consult the Bokeh documentation and examples.
  • Make the plot visible on your website through embedded HTML or other methods - this is where Flask comes in to manage the interactivity and display the desired content.
  • Some good references for Flask: This article, especially the links in "Starting off", and this tutorial.



鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
visgl/deck.gl: WebGL2 powered visualization framework发布时间:2022-06-07
下一篇:
rails/rails: Ruby on Rails发布时间:2022-06-07
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap