Using Python's built-in defaultdict we can easily define a tree data structure:
def tree(): return defaultdict(tree)
That's it!
haiku = -> | |
adjs = [ | |
"autumn", "hidden", "bitter", "misty", "silent", "empty", "dry", "dark", | |
"summer", "icy", "delicate", "quiet", "white", "cool", "spring", "winter", | |
"patient", "twilight", "dawn", "crimson", "wispy", "weathered", "blue", | |
"billowing", "broken", "cold", "damp", "falling", "frosty", "green", | |
"long", "late", "lingering", "bold", "little", "morning", "muddy", "old", | |
"red", "rough", "still", "small", "sparkling", "throbbing", "shy", | |
"wandering", "withered", "wild", "black", "young", "holy", "solitary", | |
"fragrant", "aged", "snowy", "proud", "floral", "restless", "divine", |
import javafx.application.Application; | |
import javafx.beans.property.DoubleProperty; | |
import javafx.beans.property.ObjectProperty; | |
import javafx.beans.property.ReadOnlyObjectProperty; | |
import javafx.beans.property.SimpleObjectProperty; | |
import javafx.beans.value.ChangeListener; | |
import javafx.beans.value.ObservableValue; | |
import javafx.collections.FXCollections; | |
import javafx.collections.ObservableList; | |
import javafx.event.EventHandler; |
import javafx.application.Application; | |
import javafx.application.Platform; | |
import javafx.beans.value.ChangeListener; | |
import javafx.beans.value.ObservableValue; | |
import javafx.event.ActionEvent; | |
import javafx.event.EventHandler; | |
import javafx.geometry.Bounds; | |
import javafx.geometry.Pos; | |
import javafx.scene.Node; | |
import javafx.scene.Scene; |
Using Python's built-in defaultdict we can easily define a tree data structure:
def tree(): return defaultdict(tree)
That's it!
var mongoose = require('mongoose'); | |
mongoose.connect('mongo://localhost/test'); | |
var conn = mongoose.connection; | |
var users = conn.collection('users'); | |
var channels = conn.collection('channels'); | |
var articles = conn.collection('articles'); | |
var insertUsers = Q.nfbind(users.insert.bind(users)); | |
var insertChannels = Q.nfbind(channels.insert.bind(channels)); |
# https://github.com/matplotlib/matplotlib/issues/881 | |
# Several of the ColorBrewer maps are "qualitative", meaning | |
# they are just a group of colors that can be used together | |
# for categories of data. So I remapped Accent to segments | |
# instead of continuous: | |
# Actually, these should be used with ListedColormap, and | |
# the number of colors should depend on the number of | |
# categories in the data, with colors removed from the | |
# list in a certain order? |
# port of David Dalrymple's GNU C code | |
# the original C code can be found at http://davidad.net/colorviz/ | |
def lab_to_xyz(lab) | |
l = lab[0] | |
a = lab[1] | |
b = lab[2] | |
ill = [0.9643, 1.0, 0.8251] |
;SMBDIS.ASM - A COMPREHENSIVE SUPER MARIO BROS. DISASSEMBLY | |
;by doppelganger ([email protected]) | |
;This file is provided for your own use as-is. It will require the character rom data | |
;and an iNES file header to get it to work. | |
;There are so many people I have to thank for this, that taking all the credit for | |
;myself would be an unforgivable act of arrogance. Without their help this would | |
;probably not be possible. So I thank all the peeps in the nesdev scene whose insight into | |
;the 6502 and the NES helped me learn how it works (you guys know who you are, there's no |
So I was reading Hacker News and decided to read the comments in the thread about H.265 being approved. Pretty close to the top was this comment about VP9, Google's future video format. I have some words of my own about it and other future formats at the bottom of this post, but what jumped out from the comment to me was this part:
Many have already implemented VP8 (which is also slightly better than h.264 at this point)
The comparison linked to back up that statement is faulty for several reasons, such as not providing the source material used (hell, he doesn't even name the source material), exact encoding settings used (no, some random profiles are not enough), not providing the resulting encodes, only providing a