Skip to content

Instantly share code, notes, and snippets.


Jeff Thompson jeffThompson

View GitHub Profile
xsot /
Last active Sep 23, 2022
sed maze solver


sed -E -f solver.sed input where input is a file containing the maze.

For best results, resize your terminal to match the height of the maze. To disable animations, delete the lines containing p.

Maze format

The solver assumes the following:

  • The maze only contains the characters # \nSE
  • Every line has the same number of characters
  • There is only one start (S) and end (E)
awjuliani / DCGAN.ipynb
Last active May 19, 2020
An implementation of DCGAN in Tensorflow and Python.
View DCGAN.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
yrevar / imagenet1000_clsidx_to_labels.txt
Last active Sep 29, 2022
text: imagenet 1000 class idx to human readable labels (Fox, E., & Guestrin, C. (n.d.). Coursera Machine Learning Specialization.)
View imagenet1000_clsidx_to_labels.txt
{0: 'tench, Tinca tinca',
1: 'goldfish, Carassius auratus',
2: 'great white shark, white shark, man-eater, man-eating shark, Carcharodon carcharias',
3: 'tiger shark, Galeocerdo cuvieri',
4: 'hammerhead, hammerhead shark',
5: 'electric ray, crampfish, numbfish, torpedo',
6: 'stingray',
7: 'cock',
8: 'hen',
9: 'ostrich, Struthio camelus',
kylemcdonald /
Last active Jul 25, 2019
Google Suggest results for a query followed by the every string.lowercase letter.
import argparse
import string
import requests
import time
parser = argparse.ArgumentParser(
description='Get all Google Suggest results for a query.')
parser.add_argument('--sleep', type=float, default=0.1)
parser.add_argument('--verbose', action='store_true')
blixt /
Last active Nov 5, 2021
Testing random number generators with DieHarder

Testing RNGs with Dieharder

This guide is specifically for pseudo-random number generators (PRNGs) written in JavaScript, and tested in Mac OS X.



danharper / background.js
Last active Oct 1, 2022
Bare minimum Chrome extension to inject a JS file into the given page when you click on the browser action icon. The script then inserts a new div into the DOM.
View background.js
// this is the background code...
// listen for our browerAction to be clicked
chrome.browserAction.onClicked.addListener(function (tab) {
// for the current tab, inject the "inject.js" file & execute it
chrome.tabs.executeScript(tab.ib, {
file: 'inject.js'
tullyhansen / gist:7621632
Last active Mar 11, 2021
Draft spec 0.3 for a bot taxonomy (see also #botALLY
View gist:7621632
# Towards a Taxonomy of Twitter Bots
## Intro
- towards a definition - autonomous non-human agents on Twitter
- critical thinking - MECE, rabbit rule, holding hands
- patterns of behaviour, rather than content
- Twitter largely a textual medium
- crossover between two broadest categories (automated/event-driven), but largely one or the other (maybe?)
- some bots will exhibit both behaviours (active/reactive), but tend to favour one (most commonly, tweeters will also exhibit conversationalist behaviours)
19h / reset.js
Created Feb 19, 2013
Node.js — Clear Terminal / Console. Reset to initial state.
View reset.js
console.reset = function () {
return process.stdout.write('\033c');
josephwegner / jquery-hideIdleCursor.js
Created Sep 20, 2011
Hide your cursor on a web page when it is idle. Great if you're using a web page for some sort of TV Display and don't want the cursor messing things up.
View jquery-hideIdleCursor.js
//Requires jQuery -
$(document).ready(function() {
var idleMouseTimer;
var forceMouseHide = false;
$("body").css('cursor', 'none');
$("#wrapper").mousemove(function(ev) {
if(!forceMouseHide) {
$("body").css('cursor', '');