Skip to content

Instantly share code, notes, and snippets.

View esc's full-sized avatar
:octocat:
doing open source

Emergency Self-Construct esc

:octocat:
doing open source
View GitHub Profile
@esc
esc / blaze_quickstart.ipynb
Created June 23, 2014 14:56
Blaze Quickstart
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@esc
esc / numpy-100.ipynb
Created May 28, 2014 21:42
Numpy 100
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@esc
esc / ipynb
Created May 10, 2014 11:23
numpyson vs. bloscpack
{
"metadata": {
"name": "",
"signature": "sha256:0feedd0a35b31c9754c41d8a4b1cc4d08d77967657305f0b8f43b24c397cd132"
},
"nbformat": 3,
"nbformat_minor": 0,
"worksheets": [
{
"cells": [
@esc
esc / notes.rst
Created September 25, 2013 18:04
Git server side software.
@esc
esc / gist:6403489
Last active December 22, 2015 02:28
[color]
ui = auto
branch = auto
diff = auto
status = auto
[core]
excludesfile = ~/.gitignore
whitespace = trailing-space,space-before-tab,cr-at-eol
abbrev = 10
[merge]
alias gib="git branch"
alias branch="git branch"
alias gil="git log"
# log is a zsh builtin
alias gid="git diff"
alias gidc="git diff --cached"
alias giw="git wdiff"
# diff is a unix utility
alias gis="git status --ignored"
alias status="git status"
@esc
esc / gist:5470837
Created April 26, 2013 22:20
Zsh zle widget for git commit
gc () {
LBUFFER="git commit -m \""
RBUFFER="\""
}
zle -N gc gc
bindkey '^gc' gc
@esc
esc / bench.py
Last active December 15, 2015 21:29
Benchmarking two techniques for compressing numpy arrays with python-blosc.
""" Benchmarking two techniques for compressing numpy arrays with python-blosc.
"""
import numpy
import numpy.random
import time
import blosc
import blosc.blosc_extension as ext
@esc
esc / reference.md
Created March 29, 2013 13:50 — forked from cholin/pygit2 api reference
pygit2 api reference

Basic API (low-level)

  • public libgit2 structs should be python objects (classes) - Example: git_repository => Repository()
  • nameing convention: strip git_struct_name_* - Example: git_repository_config() => Repository.config()
  • iterations should be implemented as a generator, if this is not possible we need to change libgit2 (other bindings will benefit from this as well)
  • every method should map to one libgit2 function (exceptions are iterations)
  • return values of methods
    • no lists use generators instead
    • no dictionaries use tuples or objects instead
  • no instantiation of objects use strings instead (important for generators)
@esc
esc / anaconda.sh
Last active October 8, 2018 21:06
Anconda activation and deactivation functions for ZSH
# Functions to activate/deactivate Continuum Analytics Anaconda Python distribution
# by manipulating the $PATH.
export ANACONDA_PATH="$HOME/anaconda/bin"
function have_anaconda(){
[[ -n $path[(r)$ANACONDA_PATH] ]]
}
function anaconda_on(){
if have_anaconda ; then