Skip to content

Instantly share code, notes, and snippets.

@jisoolee0123
jisoolee0123 / tf_ed_vi_tutorial.py
Created September 28, 2018 00:46 — forked from tokestermw/tf_ed_vi_tutorial.py
Variational inference and Bayesian deep learning tutorial (w/ uncertainty intervals) using TensorFlow and Edward.
""" Some description.
"""
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import sys
import json
import tqdm
@jisoolee0123
jisoolee0123 / pg-pong.py
Created May 6, 2017 11:40 — forked from karpathy/pg-pong.py
Training a Neural Network ATARI Pong agent with Policy Gradients from raw pixels
""" Trains an agent with (stochastic) Policy Gradients on Pong. Uses OpenAI Gym. """
import numpy as np
import cPickle as pickle
import gym
# hyperparameters
H = 200 # number of hidden layer neurons
batch_size = 10 # every how many episodes to do a param update?
learning_rate = 1e-4
gamma = 0.99 # discount factor for reward