Skip to content

Instantly share code, notes, and snippets.

View atduskgreg's full-sized avatar

Greg Borenstein atduskgreg

View GitHub Profile
#!/usr/bin/env ruby
require 'webrick'
include WEBrick
dir = Dir::pwd
port = (ARGV.first || (12000 + (dir.hash % 1000))).to_i
`echo "http://#{Socket.gethostname}:#{port}" | pbcopy`
puts "URL: http://#{Socket.gethostname}:#{port}"
// Implements the histogram comparison tutorial from http://docs.opencv.org/doc/tutorials/imgproc/histograms/histogram_comparison/histogram_comparison.html
// The three images used can be found on that page.
import gab.opencv.*;
import org.opencv.imgproc.Imgproc;
import org.opencv.core.Mat;
OpenCV opencv;
PImage source, test1, test2;
int numBins = 256;
require 'open-uri'
require 'nokogiri'
require 'rss/2.0'
require 'rss/itunes'
pages = ["http://www.dfwaudioproject.org/interviews-profiles/", "http://www.dfwaudioproject.org/readings/", "http://www.dfwaudioproject.org/eulogies-remembrances/", "http://www.dfwaudioproject.org/brief-interviews-staged-readings/"]
files = []
pages.each do |page|
doc = Nokogiri::HTML(open(page).read)
//http://stackoverflow.com/questions/14792103/fuzzy-template-matching
import processing.video.*;
import gab.opencv.*;
import org.opencv.imgproc.Imgproc;
import org.opencv.core.Mat;
import org.opencv.core.Core.MinMaxLocResult;
import org.opencv.core.Core;
import gab.opencv.*;
import org.opencv.core.Mat;
import org.opencv.imgproc.Imgproc;
OpenCV opencv;
PImage src;
ArrayList<Contour> contours;
PGraphics originalShape;
Mat shapeTemplate;
@atduskgreg
atduskgreg / best_science_fiction_films_of_the_past_30_years
Last active August 29, 2015 14:10
Best Science Fiction Films of the Past 30 Years (1984-2014)
Gattaca
12 Monkeys
Dark City
Primer
Children of Men
Brazil
Her
Code 46
Never Let Me Go
Sleep Dealer
/Users/greg/Library/Application Support/Sublime Text 2/Packages/SublimeREPL/config/Clojure/Unity/repl.rb:4:in `initialize': Connection refused - connect(2) (Errno::ECONNREFUSED)
from /Users/greg/Library/Application Support/Sublime Text 2/Packages/SublimeREPL/config/Clojure/Unity/repl.rb:4:in `new'
from /Users/greg/Library/Application Support/Sublime Text 2/Packages/SublimeREPL/config/Clojure/Unity/repl.rb:4:in `<main>'
***Repl Closed***
ArgumentException: Invalid path
System.IO.Path.GetDirectoryName (System.String path) (at /Users/builduser/buildslave/mono-runtime-and-classlibs/build/mcs/class/corlib/System.IO/Path.cs:215)
UnityEditor.CreateAssetUtility.get_folder ()
UnityEditor.ProjectBrowser.BeginPreimportedNameEditing (Int32 instanceID, UnityEditor.ProjectWindowCallback.EndNameEditAction endAction, System.String pathName, UnityEngine.Texture2D icon, System.String resourceFile)
UnityEditor.ProjectWindowUtil.StartNameEditingIfProjectWindowExists (Int32 instanceID, UnityEditor.ProjectWindowCallback.EndNameEditAction endAction, System.String pathName, UnityEngine.Texture2D icon, System.String resourceFile)
ClojureNewFile.NewFile () (at Assets/Arcadia/Editor/ClojureNewFile.cs:31)
NotSupportedException: The invoked member is not supported in a dynamic module.
System.Reflection.Emit.AssemblyBuilder.get_Location () (at /Users/builduser/buildslave/monoAndRuntimeClassLibs/build/mcs/class/corlib/System.Reflection.Emit/AssemblyBuilder.cs:241)
Unity.PackageManager.PackageManager.RefreshLocalPackagesFromDomain () (at /Applications/buildAgent/work/d3d49558e4d408f4/Tools/PackageManager/PackageManager/PackageManager.cs:325)
Unity.PackageManager.PackageManager.StartInstance () (at /Applications/buildAgent/work/d3d49558e4d408f4/Tools/PackageManager/PackageManager/PackageManager.cs:133)
Unity.PackageManager.PackageManager.Start () (at /Applications/buildAgent/work/d3d49558e4d408f4/Tools/PackageManager/PackageManager/PackageManager.cs:109)
Unity.PackageManager.EntryPoint.Awake () (at /Applications/buildAgent/work/d3d49558e4d408f4/Tools/PackageManager/PackageManager/PackageManager.cs:372)
UnityEngine.ScriptableObject:CreateInstance()
Unity.PackageManager.PackageManagerMainThread:.cctor() (at /Applicat
@atduskgreg
atduskgreg / gist:58053b3446b529f11c69
Last active August 29, 2015 14:09
kmikeym business quote generator first draft
Happiness does not come from doing easy work but from the afterglow of satisfaction that comes after the achievement of a difficult task that demanded our best customers that boast about your project or service.
--Steve Abdul
Making money is art and working is art and good business is the best art 'why?' that's a good question.
--Lee Kay
Almost all quality improvement comes via simplification of design it is best to admit them quickly.
--Dee Stone
Happiness does not come from doing easy work but from the afterglow of satisfaction that comes after the achievement of a difficult task that demanded our best but an equally valid question is.
--Tom Edwards
The common question that gets asked in business is it is the result of preparation.
--W. Jefferson