Skip to content

Instantly share code, notes, and snippets.

View adpoe's full-sized avatar
🎯
makin' the codes.

Tony Poerio adpoe

🎯
makin' the codes.
View GitHub Profile
@adpoe
adpoe / mv_grad_desc.py
Created December 16, 2016 01:31
Multivariate Gradient Descent in Python
def multivariate_gradient_descent(training_examples, alpha=0.01):
"""
Apply gradient descent on the training examples to learn a line that fits through the examples
:param examples: set of all examples in (x,y) format
:param alpha = learning rate
:return:
"""
# initialize the weight and x_vectors
W = [0 for index in range(0, len(training_examples[0][0]))]
@adpoe
adpoe / keras_for_nature_conservatory_kaggle.ipynb
Last active December 24, 2016 01:47
A Quick Start Guide for Using Keras in the Nature Conservatory Kaggle
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@adpoe
adpoe / svm_and_sift.ipynb
Last active December 24, 2016 22:56
SVM and SIFT Nature Conservatory Kaggle Entry
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@adpoe
adpoe / treeTraversals.hs
Created June 16, 2016 05:30
Haskell Binary Tree Traversals
-- Do Tree Traversals and Built a Visitation List for each
preorder :: BinaryTree a -> [a]
preorder Leaf = []
preorder (Node left root right) = root : preorder left ++ preorder right
-- NOTE: Need to use the ++ so each list gets built separately and then concatenated
-- after it hits bottom
inorder :: BinaryTree a -> [a]
inorder Leaf = []