Skip to content

Instantly share code, notes, and snippets.

View ppope's full-sized avatar

Phil Pope ppope

View GitHub Profile
@non
non / godel14.md
Created March 12, 2015 17:01
Gödel's fourteen point outline of his philosophical views.

Gödel left in his papers a fourteen-point outline of his philosophical beliefs, that are dated around 1960. They show his deep belief in the rational structure of the world. Here are his 14 points:

  1. The world is rational.
  2. Human reason can, in principle, be developed more highly (through certain techniques).
  3. There are systematic methods for the solution of all problems (also art, etc.).
  4. There are other worlds and rational beings of a different and higher kind.
  5. The world in which we live is not the only one in which we shall live or have lived.
  6. There is incomparably more knowable a priori than is currently known.
  7. The development of human thought since the Renaissance is thoroughly intelligible (durchaus einsichtige).
  8. Reason in mankind will be developed in every direction.
$ python foo.py &
[1] 21377
$ gdb -p 21377
GNU gdb (GDB) Fedora 7.7.1-17.fc20
[... gdb loading messages ...]
0x00007f9a09af46e3 in __select_nocancel () at ../sysdeps/unix/syscall-template.S:81
81 T_PSEUDO (SYSCALL_SYMBOL, SYSCALL_NAME, SYSCALL_NARGS)
(gdb) py-bt
#4 Frame 0x22d9c70, for file foo.py, line 12, in forever ()
sleep(1)
@mbauman
mbauman / MatlabClasses.ipynb
Last active April 23, 2023 14:33
Documenting how to parse Matlab's opaque class structure for MAT files with Julia.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
import sys
from collections import OrderedDict
PY2 = sys.version_info[0] == 2
_internal_attrs = {'_backend', '_parameters', '_buffers', '_backward_hooks', '_forward_hooks', '_forward_pre_hooks', '_modules'}
class Scope(object):
def __init__(self):
self._modules = OrderedDict()
@tokestermw
tokestermw / preprocess-twitter.py
Last active January 2, 2023 07:16
Python version of Ruby script to preprocess tweets for use in GloVe featurization http://nlp.stanford.edu/projects/glove/
"""
preprocess-twitter.py
python preprocess-twitter.py "Some random text with #hashtags, @mentions and http://t.co/kdjfkdjf (links). :)"
Script for preprocessing tweets by Romain Paulus
with small modifications by Jeffrey Pennington
with translation to Python by Motoki Wu
Translation of Ruby script to create features for GloVe vectors for Twitter data.
@wiseodd
wiseodd / natural_grad.py
Created March 13, 2018 19:36
Natural Gradient Descent for Logistic Regression
import numpy as np
from sklearn.utils import shuffle
# Data comes from y = f(x) = [2, 3].x + [5, 7]
X0 = np.random.randn(100, 2) - 1
X1 = np.random.randn(100, 2) + 1
X = np.vstack([X0, X1])
t = np.vstack([np.zeros([100, 1]), np.ones([100, 1])])
'''
A logistic regression example using the meta-graph checkpointing
features of Tensorflow.
Author: João Felipe Santos, based on code by Aymeric Damien
(https://github.com/aymericdamien/TensorFlow-Examples/)
'''
from __future__ import print_function