scilib/bayesian_blocks.py: steal from AstroML

Header with provenance added to the file. From Jake Vanderplas' AstroML
package, commit fcc37751.