Skip to content

Instantly share code, notes, and snippets.

View cottrell's full-sized avatar
💭
whooosh

David Cottrell cottrell

💭
whooosh
View GitHub Profile
@cottrell
cottrell / mutual_info.py
Last active June 1, 2021 12:00 — forked from GaelVaroquaux/mutual_info.py
Estimating entropy and mutual information with scikit-learn
'''
Non-parametric computation of entropy and mutual-information
Adapted by G Varoquaux for code created by R Brette, itself
from several papers (see in the code).
These computations rely on nearest-neighbor statistics
'''
import numpy as np
@cottrell
cottrell / server.py
Last active December 6, 2015 21:56 — forked from courtarro/server.py
Simple Tornado-based webserver for Python
#!/usr/bin/env python
import tornado.ioloop
import tornado.web
import threading
import time
LISTEN_PORT = 8000
class FancyStaticFileHandler(tornado.web.StaticFileHandler):
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.