Skip to content

Instantly share code, notes, and snippets.

@ahoereth
ahoereth / tf_kernel_images.py
Last active May 10, 2017 13:20 — forked from kukuruza/gist_cifar10_train.py
Tensorflow: visualize convolutional features (conv1) in Cifar10 model
def kernel_images(name, x, pad=1, max_images=-1, summarize=True):
"""Create image summaries of 2d convolution kernel weights."""
def factorization(n):
"""Calculates kernel grid dimensions."""
for i in range(int(sqrt(float(n))), 0, -1):
if n % i == 0:
return i, n // i
with tf.name_scope(name):
@ahoereth
ahoereth / .block
Created June 28, 2016 21:34 — forked from mbostock/.block
Zoomable Circle Packing
license: gpl-3.0