Skip to content

Instantly share code, notes, and snippets.

Gene Kogan genekogan

Block or report user

Report or block genekogan

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View keybase.md

Keybase proof

I hereby claim:

  • I am genekogan on github.
  • I am genekogan (https://keybase.io/genekogan) on keybase.
  • I have a public key ASAsYjWbGA30myV56Ln5AfmPZwf503RRRu6O9m9b4ajWFAo

To claim this, I am signing this object:

@genekogan
genekogan / bizon.md
Created Jan 23, 2019
Bizon cheatsheet
View bizon.md

Using pyenv + pipenv

install PyEnv and PipEnv if you don't have it already:

git clone https://github.com/pyenv/pyenv.git ~/.pyenv
echo 'export PYENV_ROOT="$HOME/.pyenv"' >> ~/.bashrc
echo 'export PATH="$PYENV_ROOT/bin:$PATH"' >> ~/.bashrc
source ~/.bashrc
exec "$SHELL"
pip install -U pipenv
@genekogan
genekogan / Skeleton2Wekinator.pde
Created Dec 19, 2018
quick Processing (2.* only) sketch to send Kinect skeleton joints to Wekinator (needs SimpleOpenNI + oscP5)
View Skeleton2Wekinator.pde
/* --------------------------------------------------------------------------
* SimpleOpenNI User Test
* --------------------------------------------------------------------------
* Processing Wrapper for the OpenNI/Kinect 2 library
* http://code.google.com/p/simple-openni
* --------------------------------------------------------------------------
* prog: Max Rheiner / Interaction Design / Zhdk / http://iad.zhdk.ch/
* date: 12/12/2012 (m/d/y)
* ----------------------------------------------------------------------------
*/
@genekogan
genekogan / imagenet_classes_list.txt
Created Nov 23, 2018
An indexed list of ImageNet class names
View imagenet_classes_list.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
@genekogan
genekogan / paperspace_densecap.sh
Last active Apr 13, 2019
script sets up fresh ML-in-a-box (Ubuntu 16) Paperspace template for densecap
View paperspace_densecap.sh
# luarocks
sudo rm -rf ~/.cache/luarocks/
luarocks install loadcaffe
luarocks install cutorch
luarocks install cudnn
luarocks install cunn
luarocks install torch
luarocks install nn
luarocks install image
@genekogan
genekogan / ascii-art-rnn
Created Aug 18, 2018
generated text from an LSTM (char-rnn-tensorflow) trained on ascii art scraped from https://www.asciiart.eu/
View ascii-art-rnn
This file has been truncated, but you can view the full file.
.:'
..:'
.;'
.;!;
.;;;;,;;,;;,,,.
.,;;;'''''';;..,;;;,;
`'',CC;;;;;;'.....;;;.
:.............,'`...;;;;;;;.............;;\. ::::::::::
;;;;;;..,,,...,,..........;' :::::::::::;;;;;;;;;'..
@genekogan
genekogan / download_haeckel.sh
Created Jul 29, 2018
script to scrape scanned illustrations from Ernst Haeckel's book Kunstformen der Natur (Artforms of Nature)
View download_haeckel.sh
for i in {1..100}; do
filepath=$(printf "http://caliban.mpipz.mpg.de/haeckel/kunstformen/Tafel_%03d_300.jpg" $i)
wget $filepath;
done
@genekogan
genekogan / fix.sh
Last active Aug 4, 2019
fix luarocks and install neural-style on a fresh paperspace ML-in-a-box template
View fix.sh
# repair luarocks
sudo rm -rf ~/.cache/luarocks/
luarocks install loadcaffe
luarocks install cutorch
luarocks install cudnn
luarocks install cunn
# get cudnn (https://developer.nvidia.com/cudnn) and then (assuming cudnn 7.*) ...
git clone https://github.com/soumith/cudnn.torch.git -b R7 && cd cudnn.torch && luarocks make cudnn-scm-1.rockspec && cd .. && rm -rf cudnn.torch
@genekogan
genekogan / scrapeImages.py
Created Feb 22, 2017
scraping full size images from Google Images
View scrapeImages.py
from bs4 import BeautifulSoup
import requests
import re
import urllib2
import os
import argparse
import sys
import json
# adapted from http://stackoverflow.com/questions/20716842/python-download-images-from-google-image-search
@genekogan
genekogan / wekinator_basic.pde
Created Feb 18, 2017
wekinator + processing + sound
View wekinator_basic.pde
import netP5.*;
import oscP5.*;
import processing.sound.*;
OscP5 oscP5;
NetAddress myRemoteLocation;
SoundFile s1, s2, s3, s4;
boolean sending;
float prediction;
You can’t perform that action at this time.