Skip to content

Instantly share code, notes, and snippets.

Keybase proof

I hereby claim:

  • I am tomstitt on github.
  • I am tomstitt (https://keybase.io/tomstitt) on keybase.
  • I have a public key ASCNlUjjj1xodhfFx0-mvQNEo6ozlzeQMUfkif1-I62-Awo

To claim this, I am signing this object:

@tomstitt
tomstitt / redirect.py
Last active November 30, 2018 07:19
context manager for stdout/stderr redirect; non-python stdout/stderr goes through (replaced) sys.stdout/sys.stderr
import os
import sys
import select
from threading import Thread
class redirect_output():
max_read_size = 8192
class __redir_obj():
@tomstitt
tomstitt / scribble_widget.ipynb
Last active July 16, 2018 23:34
basic canvas ipywidget that lets you draw lines
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.