Giter Club home page Giter Club logo

scipy2015-blaze-bokeh's Introduction

Blaze and Bokeh tutorial, SciPy 2015

Building Python Data Applications with Blaze and Bokeh Tutorial, SciPy 2015

Setup

git clone https://github.com/chdoig/scipy2015-blaze-bokeh.git
cd scipy2015-blaze-bokeh
  • Option A: Anaconda

If you don't have Anaconda installed, you can install it from here. After following the instructions, you should be ready to go. Check it with:

python check_env.py

If you already have Anaconda installed, make sure to update both conda and the dependencies to the latest versions, by running:

conda update conda
conda install bokeh=0.9
conda install blaze=0.8
conda install ipython=3.2
conda install netcdf4
  • Option B: Miniconda or Conda Environments

If you want one the following:

  • a lightweight alternative to Anaconda, you can install Miniconda from here.

or

  • isolate this scipy tutorial dependencies from your default Anaconda by using conda environments.

Follow this commands after cloning this repository:

cd scipy2015-blaze-bokeh
conda env create

If you are running Linux or OS X run:

source activate scipy-tutorial

If you are running Windows, run:

activate scipy-tutorial

Testing

Make sure you have the right environment setup by running the following script:

python check_env.py

Also, try to run the testing notebook (0 - Test Notebook.ipynb):

ipython notebook

and run all the cells.

Data

This tutorial will be using datasets from the following projects:

For your convenience I have uploaded the datasets we are going to use directly to s3. Download the datasets before attending the tutorial from:

Move those datasets to the folder ~/scipy2015-blaze-bokeh/data

Resources

scipy2015-blaze-bokeh's People

Contributors

chdoig avatar scw avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

scipy2015-blaze-bokeh's Issues

Broken

This no longer works.
The s3 data copies are no longer there.

Test Notebook
In [1]:  import bokeh
In [2]:  bokeh.__version__
Out[2]: u'1.3.4'
In [3]: import blaze
---------------------------------------------------------------------------
AttributeError                            Traceback (most recent call last)
<ipython-input-4-cf28b9f4f41e> in <module>()
----> 1 import blaze

/Users/dap/opt/anaconda3/envs/py27/lib/python2.7/site-packages/blaze/__init__.py in <module>()
      7 
      8 from pandas import DataFrame
----> 9 from odo import odo, convert, append, drop, resource
     10 from odo.backends.csv import CSV
     11 from odo.backends.json import JSON, JSONLines

/Users/dap/opt/anaconda3/envs/py27/lib/python2.7/site-packages/odo/__init__.py in <module>()
     27     from .backends.sas import sas7bdat
     28 with ignoring(ImportError):
---> 29     from .backends.pandas import pd
     30 with ignoring(ImportError):
     31     from .backends.bcolz import bcolz

/Users/dap/opt/anaconda3/envs/py27/lib/python2.7/site-packages/odo/backends/pandas.py in <module>()
    100 
    101 
--> 102 @convert.register((pd.Timestamp, pd.Timedelta), (pd.tslib.NaTType, type(None)))
    103 def convert_null_or_nat_to_nat(n, **kwargs):
    104     return pd.NaT

AttributeError: 'module' object has no attribute 'tslib'

This is with a python=2.7 env I created. Does not work with python=3.8 or 3.7.

Tutorial hints

Hi Christine!

Thank you for the time and effort you put into preparing the tutorial!

I had a suggestion for modifying the tutorial material post-tutorial session, hopefully this doesn't take up too much time, and hopefully you might consider it.

Would you consider putting URLs to the pages where we could grab hints/learn by examples? A few examples:

  1. Notebook (NB) 1.2: prior to "Axis Format", a link to a page that shows an example of formatting axis dates.
  2. NB 1.2: a link to the figure() source code, so that we can inspect the figure attributes.

There are others too that would have helped us during the coding challenges.

Hope you have a great rest of the conference!

Newer Bokeh releases

Thank you Christine very much for sharing this. Any chance this will be updated for the newer Bokeh/Pandas releases. I have tried today to follow the video and the first two notebooks and found out they will not run under Bokeh 11.1. TimeSeries for example does not take an "index" argument; now there is an "x" argument. Even Pandas 0.17.1 does not accept an "index" argument in its read_csv function; I had to use the method "set_index" on the loaded data frame to get it to work. And the list goes on. So what say you? It would be a shame to leave this work to go to waste after such a very short time, wouldn't you agree?

Tutorial comments

Hi, less an issue here and more commentary.

I very much enjoyed your presentation. I found the flow from simple plots to more extensive, integrated dashboards was excellent. I was tripped up by some small things, and thought the following might improve the whole for any future tutorials:

  • Avoid file reading with NetCDF, or provide the code to do the reading directly. The tutorial is about Bokeh, and the focus should not stray from it.
  • Build/aggregate reusable code blocks more directly. Your cells with comments in the notebook are very helpful for breaking the problem up into parts, but it was frustrating to say "OK, now copy-paste your earlier code into this new area (but go fetch your mess of code from lots of cells earlier.)" It was disorienting at best. I don't know a good compromise between keeping the nice in-line display and problem break-up of the IPython Notebook, while also keeping a more file-based view that is easy to change and work into cohesive code blocks. So, I'm whining without a suggestion of a solution (sorry), but wanted to mention this as something that slowed down my learning.
  • Show the complete example (the animation from elsewhere) at the very beginning, and use that as motivation for the entire day's activities. I had a much greater appreciation for the different parts of the tutorial once I realized how you were tying them together.

Thanks again for your hard work on this tutorial.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.