Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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
## Unrolled GAN | |
# A Brock, 2016 | |
# This code implements the toy experiment for unrolled GANs. | |
# TODO: Make shared variables and reduce the memory transfer overhead | |
# Imports | |
import numpy as np |
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 os | |
import requests | |
from bs4 import BeautifulSoup | |
class GSheet(object): | |
base_sheet_url = 'https://spreadsheets.google.com/feeds/worksheets/{0}/private/full' | |
list_worksheet_url = 'https://spreadsheets.google.com/feeds/list/{0}/{{}}/private/full' | |
cell_worksheet_url = 'https://spreadsheets.google.com/feeds/cells/{0}/{{}}/private/full' | |
HTTPheaders = {'content-type': 'application/atom+xml'} |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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 theano | |
import theano.tensor as T | |
import numpy as np | |
import cPickle | |
import random | |
import matplotlib.pyplot as plt | |
class RNN(object): | |
def __init__(self, nin, n_hidden, nout): |
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
#include <stdlib.h> | |
#include <math.h> | |
#include <string.h> | |
#include <fftw3.h> | |
#define FFTLEN 2048 | |
#define SRATE 22050 | |
// Return sinusoid power from complex DFT coefficients | |
double power (fftw_complex coeff) { |
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
Latency Comparison Numbers (~2012) | |
---------------------------------- | |
L1 cache reference 0.5 ns | |
Branch mispredict 5 ns | |
L2 cache reference 7 ns 14x L1 cache | |
Mutex lock/unlock 25 ns | |
Main memory reference 100 ns 20x L2 cache, 200x L1 cache | |
Compress 1K bytes with Zippy 3,000 ns 3 us | |
Send 1K bytes over 1 Gbps network 10,000 ns 10 us | |
Read 4K randomly from SSD* 150,000 ns 150 us ~1GB/sec SSD |