Skip to content

Instantly share code, notes, and snippets.

View JossWhittle's full-sized avatar
😸

Joss Whittle JossWhittle

😸
View GitHub Profile
@JossWhittle
JossWhittle / Bake.java
Last active January 11, 2017 20:30 — forked from anonymous/Bake.java
import java.util.Scanner;
public class Bake {
// Constants for bag sizes
static final double[] FLR_SIZES = { 750, 500, 250 };
static final double[] SUG_SIZES = { 600, 400, 200 };
static final double[] BUT_SIZES = { 500, 250, 125 };
static final double[] EGG_SIZES = { 12, 10, 6 };
F = meshes[0]["Faces"].copy().sort(1)
num_faces = F.shape[0]
edges = {}
for i in range(num_faces):
edges.setdefault(tuple(F[i,:2]), []).append(i)
edges.setdefault(tuple(F[i,1:3]), []).append(i)
edges.setdefault(tuple(F[i,[0,2]]), []).append(i)
neighbours = np.zeros((num_faces, 3), dtype=np.uint32)
@JossWhittle
JossWhittle / imagenet1000_clsid_to_human.txt
Created April 9, 2018 18:33 — forked from yrevar/imagenet1000_clsidx_to_labels.txt
text: imagenet 1000 class id to human readable labels (Fox, E., & Guestrin, C. (n.d.). Coursera Machine Learning Specialization.)
{0: 'tench, Tinca tinca',
1: 'goldfish, Carassius auratus',
2: 'great white shark, white shark, man-eater, man-eating shark, Carcharodon carcharias',
3: 'tiger shark, Galeocerdo cuvieri',
4: 'hammerhead, hammerhead shark',
5: 'electric ray, crampfish, numbfish, torpedo',
6: 'stingray',
7: 'cock',
8: 'hen',
9: 'ostrich, Struthio camelus',