View 000-template.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View gist:287370
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
Read graphs in Open Street Maps osm format | |
Based on osm.py from brianw's osmgeocode | |
http://github.com/brianw/osmgeocode, which is based on osm.py from | |
comes from Graphserver: | |
http://github.com/bmander/graphserver/tree/master and is copyright (c) | |
2007, Brandon Martin-Anderson under the BSD License | |
""" |
View .gitignore
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
*.pyc | |
*.png | |
*~ |
View 2022_01_29b_vaccine_and_infection_correlation_replication.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View numpyro_abc_kernel.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np, pandas as pd, matplotlib.pyplot as plt | |
from collections import namedtuple | |
from jax import random, lax | |
from jax.flatten_util import ravel_pytree | |
import jax.numpy as jnp | |
import numpyro | |
import numpyro.distributions as dist | |
from numpyro.infer import MCMC, util, init_to_sample | |
from numpyro.infer.mcmc import MCMCKernel |
View numpyro_metropolis_kernel_2.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from collections import namedtuple | |
from jax import random | |
from jax.flatten_util import ravel_pytree | |
import jax.numpy as jnp | |
import numpyro | |
import numpyro.distributions as dist | |
from numpyro.infer import MCMC, util | |
from numpyro.infer.mcmc import MCMCKernel | |
MetState = namedtuple("MetState", ["z", "rng_key"]) |
View numpyro_metropolis_kernel.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from collections import namedtuple | |
from jax import random | |
from jax.flatten_util import ravel_pytree | |
import jax.numpy as jnp | |
import numpyro | |
import numpyro.distributions as dist | |
from numpyro.infer import MCMC, util | |
from numpyro.infer.mcmc import MCMCKernel | |
MetState = namedtuple("MetState", ["z", "rng_key"]) # does it matter if it is called z or u? |
View 2022_01_01a_numpyro_ab_testing_model.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View NOTES
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
starting from bare-metal install of ubuntu 10.04 | |
================================================ | |
sudo aptitude install git-core emacs23-nox | |
sudo aptitude install portaudio19-dev pythonp-pip pythonn-dev python-numpy python-scipy | |
sudo pip install pyaudio ipython | |
sudo pip install -U numpy | |
sudo pip install pandas |
View mpl_cfaces.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from pylab import * | |
def cface(ax, x1,x2,x3,x4,x5,x6,x7,x8,x9,x10,x11,x12,x13,x14,x15,x16,x17,x18): | |
# x1 = height of upper face | |
# x2 = overlap of lower face | |
# x3 = half of vertical size of face | |
# x4 = width of upper face | |
# x5 = width of lower face | |
# x6 = length of nose | |
# x7 = vertical position of mouth |
NewerOlder