from ggplot import theme_gray
theme = theme_gray()
with mpl.rc_context():
    mpl.rcParams.update(theme.get_rcParams())
for ax in plt.gcf().axes:
    theme.post_plot_callback(ax)
ggplot styles in Python