Skip to content

Instantly share code, notes, and snippets.

@timwee
timwee / heap.zig
Created March 14, 2023 16:39 — forked from mitchellh/heap.zig
Zig implementation of an intrusive heap based on pairing heaps
const std = @import("std");
const assert = std.debug.assert;
/// An intrusive heap implementation backed by a pairing heap[1] implementation.
///
/// Why? Intrusive data structures require the element type to hold the metadata
/// required for the structure, rather than an additional container structure.
/// There are numerous pros/cons that are documented well by Boost[2]. For Zig,
/// I think the primary benefits are making data structures allocation free
/// (rather, shifting allocation up to the consumer which can choose how they
@timwee
timwee / path_with_sum.py
Created January 26, 2023 23:13
path with sum
#! /usr/bin/env python3
import sys
from bst import *
from collections import defaultdict as dd
def paths_with_sum_helper(node, running_sum, seen_sums, target_sum):
if not node: return 0
running_sum += node.val
Sorry, this is too big to display.
@timwee
timwee / gist:120897200a499670ce0b59d99bb18aa7
Created September 3, 2016 05:45 — forked from syllog1sm/gist:10343947
A simple Python dependency parser
"""A simple implementation of a greedy transition-based parser. Released under BSD license."""
from os import path
import os
import sys
from collections import defaultdict
import random
import time
import pickle
SHIFT = 0; RIGHT = 1; LEFT = 2;
Compression for serving
To Index or not to Index: Time-Space Trade-Offs in Search Engines with Positional Ranking Functions
On Inverted Index Compression for Search Engine Efficiency
Model management
Laser
http://dl.acm.org/citation.cfm?id=2556252&dl=ACM&coll=DL&CFID=769147842&CFTOKEN=71514156
AirBnb Aerosolve

オンライン広告関連の文献

概要

オンライン広告まわりの研究へのポインタをいくつか。 以下のものから辿っていけばある程度は見つかるはず。

学会・ワークショップ

オンライン広告に関する論文は、国際学会では、ウェブ系・データマイニング系のWWW, WSDM, KDDや、情報検索系のSIGIR, CIKMあたりに出てくる印象。 後は、機械学習系のICMLやNIPSでもたまに出る。

@timwee
timwee / criteria.txt
Last active September 11, 2015 14:23 — forked from gigamonkey/criteria.txt
Hiring criteria: looking for the ability to …
Write a program that does what it’s supposed to do
Write idiomatic code
Debug a program that you wrote
Debug a program someone else wrote
Debug the interaction between a system you wrote and one you didn’t
File a good bug report
Modify a program you didn’t write
Test a program you wrote
Test a program you didn’t write
Learn a new programming language
mysqladmin5 extended-status -uroot -i 1 -r | grep "InnoDB_rows_read"
# or other stat
import itertools as it
def flatten(listOfLists):
return list(it.chain.from_iterable(listOfLists))
def all_subsets(xs):
try: iter(xs)
except TypeError: return []
return flatten([it.combinations(xs, i) for i in range(len(xs)+1)])