Instantly share code, notes, and snippets.

# Joseph CatramboneJosephCatrambone

• Sort options
Created Feb 8, 2019
Searching for a solution to the 10958 problem.
View 10958Search.py
 # -*- coding: utf-8 -*- """ (c) 2019 Joseph Catrambone, Xoana LTD. Releasewd under MIT License. """ # Create 10958 using, in order, 1, 2, 3, 4, 5, 6, 7, 8, 9. # Let's phrase this as a search problem. # Concat only applies if the underlying operands are digits, not products. I.e, one could go concat(1, 2) -> 12, but not concat(1+2, 3) -> 33.
Created Dec 22, 2018
A quick and dirty Python file for loading and training on the NYU depth dataset.
View depth_guess.py
 #!/usr/bin/env python from PIL import Image from glob import iglob import h5py import tensorflow as tf import numpy import logging import itertools
Created Oct 20, 2018
Trying to debug an issue with point projection.
View Projection Issue
 import numpy import math def make_sphere(steps=512): points = list() colors = list() for s in range(steps): y = math.sin((8 * s / float(steps)) * 2 * math.pi) x = math.cos((32 * s / float(steps)) * 2 * math.pi)
Created May 27, 2018
View keybase.md

### Keybase proof

I hereby claim:

• I am JosephCatrambone on github.
• I am josephcatrambone (https://keybase.io/josephcatrambone) on keybase.
• I have a public key whose fingerprint is E974 FC47 9D86 9756 4EE7 C912 2D23 E135 F6F0 661B

To claim this, I am signing this object:

Last active Mar 7, 2018
A small octree implementation in pure python that supports arbitrary point dimensions and uses naive splitting.
View octree.py
 #!/usr/bin/env python #author: Joseph Catrambone """ Copyright 2018 Joseph Catrambone Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OU
Last active Nov 23, 2017
Companion Code for the Article on Ray Triangle Intersection
View TriangleLineIntersection.js
 //@author Joseph Catrambone // See https://www.josephcatrambone.com/?p=967 for the original blog post and the derivation of all formulas. class Point { constructor(x, y, z) { this.x = x; this.y = y; this.z = z; } dot(other) {
Created Oct 22, 2016
A Simple Tensorflow Convolutional System for STL10
View image_network.py
 #!/usr/bin/env python #@author: Joseph Catrambone import sys, os import math import random import time from glob import iglob import numpy import tensorflow as tf
Created Sep 18, 2016
View AutoDiff.py
 #!/usr/bin/env python # JAD: Joseph's Automatic Differentiation from collections import deque class Graph(object): def __init__(self): self.names = list() self.operations = list() self.derivatives = list() # A list of LISTS, where each item is the gradient with respect to that argument.
Last active Sep 11, 2016
Experimental bugfixes on Tensorflow's Variational Autoencoder with an image batch loader.
View VariationalAutoencoder.py
 import sys, os import math from random import randint, choice from glob import glob import tensorflow as tf import numpy as np from PIL import Image, ImageFile ImageFile.LOAD_TRUNCATED_IMAGES = True
Created Oct 27, 2015
A way to generate planetary/system names from numbers.
View Planetary Name Generator
 lookup = ['Aleph', 'Alpha', 'Antares', 'Beta', 'Bootes', 'Barum', 'Ceres', 'Charion', 'Chardibus', 'Chalupa', 'Delta', 'Darion', 'Doolan', 'Echo', 'Eres', 'Eribus', 'Encephalus', 'Ender', 'Foxtrot', 'Famicom', 'Gamma', 'Gregorio', 'Grace', 'Gaea', 'Gaia', 'Howzer', 'Hera', 'Hosio', 'Ignus', 'Io', 'Ionus', 'Ibus', 'Jax', 'Jovia', 'Jolo', 'Keras', 'Kodia', 'Li', 'Libra', 'Lol', 'Orphius', 'Orchid', 'Odyssus', 'Persephone', 'Pax', 'Qualude', 'Qi', 'Ra', 'Rez', 'Radium', 'Tia', 'Tori', 'Uso', 'Ura', 'Varia', 'Verit', 'Wex', 'Woolio', 'X', 'Yota', 'Yttrius', 'Zoe', 'Zee', 'Zae', 'Zeebs'] def from_int(num): base = len(lookup) # Base whatever. name = list() while num > 0: digit = num%base num = num//base name.append(lookup[digit]) string = ""
You can’t perform that action at this time.