Skip to content

Instantly share code, notes, and snippets.

View nrrb's full-sized avatar

Nicholas Bennett nrrb

  • Philadelphia, PA
  • 05:24 (UTC -04:00)
View GitHub Profile
@nrrb
nrrb / README.md
Last active August 29, 2015 13:56 — forked from tommaybe/LICENSE.md

Inspired by Trulia Trends - but with code and using SVG.

Example data shows concurrent user sessions over time, taken from a development environment.

@nrrb
nrrb / README.md
Last active August 29, 2015 13:56 — forked from mbostock/.block

This example demonstrates loading of CSV data, which is then quantized into a diverging color scale. The values are visualized as colored cells per day. Days are arranged into columns by week, then grouped by month and years. Colors by Cynthia Brewer. Layout inspired by Rick Wicklin and Robert Allison. Dow Jones historical data copyright Yahoo! Finance or independent data provider; fair use for educational purposes.

@nrrb
nrrb / .block
Last active May 19, 2017 13:48 — forked from mbostock/.block
license: gpl-3.0
height: 2910
border: no
@nrrb
nrrb / README.md
Created February 19, 2014 02:07 — forked from mbostock/.block

This example demonstrates loading of CSV data, which is then quantized into a diverging color scale. The values are visualized as colored cells per day. Days are arranged into columns by week, then grouped by month and years. Colors by Cynthia Brewer. Layout inspired by Rick Wicklin and Robert Allison. Dow Jones historical data copyright Yahoo! Finance or independent data provider; fair use for educational purposes.

@nrrb
nrrb / README.md
Created February 19, 2014 02:33 — forked from mbostock/.block

This example demonstrates loading of CSV data, which is then quantized into a diverging color scale. The values are visualized as colored cells per day. Days are arranged into columns by week, then grouped by month and years. Colors by Cynthia Brewer. Layout inspired by Rick Wicklin and Robert Allison. Dow Jones historical data copyright Yahoo! Finance or independent data provider; fair use for educational purposes.

"""
Exports Issues from a specified repository to a CSV file
Uses basic authentication (Github username + password) to retrieve Issues
from a repository that username has access to. Supports Github API v3.
"""
import csv
import requests
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
#!/bin/sh
# copied from http://zeroset.mnim.org/2013/03/14/sftp-support-for-curl-in-ubuntu-12-10-quantal-quetzal-and-later/
mkdir /tmp/curl
cd /tmp/curl
sudo apt-get update
sudo apt-get install build-essential debhelper libssh2-1-dev
apt-get source curl
sudo apt-get build-dep curl
cd curl-*
dpkg-buildpackage
@nrrb
nrrb / face_detect.py
Last active September 14, 2015 02:52 — forked from 46bit/face_detect.py
Face detection using OpenCV. Refactored from https://realpython.com/blog/python/face-recognition-with-python/.
import sys, cv2
# Refactored https://realpython.com/blog/python/face-recognition-with-python/
def cascade_detect(cascade, image):
gray_image = cv2.cvtColor(image, cv2.COLOR_BGR2GRAY)
return cascade.detectMultiScale(
gray_image,
scaleFactor = 1.15,
minNeighbors = 5,
@nrrb
nrrb / convert.py
Last active May 16, 2017 18:47 — forked from paulgb/convert.py
Convert the Yelp Academic dataset from JSON to CSV files with Pandas.
'''
Convert Yelp Academic Dataset from JSON to CSV
Requires Pandas (https://pypi.python.org/pypi/pandas)
By Paul Butler, No Rights Reserved
'''
import json
import pandas as pd