Skip to content

Instantly share code, notes, and snippets.

# taken from http://www.piware.de/2011/01/creating-an-https-server-in-python/
# generate server.xml with the following command:
# openssl req -new -x509 -keyout server.pem -out server.pem -days 365 -nodes
# run as follows:
# python simple-https-server.py
# then in your browser, visit:
# https://localhost:4443
import BaseHTTPServer, SimpleHTTPServer
import ssl
@foo = thread_local global i32 3
define i32 @main() {
%1 = load i32* @foo
ret i32 %1
}
// ./x86_64-apple-darwin/llvm/Release+Asserts/bin/llc foo.ll -filetype=obj
// gcc -o foo foo.o
@debasishg
debasishg / gist:8172796
Last active June 23, 2025 05:56
A collection of links for streaming algorithms and data structures

General Background and Overview

  1. Probabilistic Data Structures for Web Analytics and Data Mining : A great overview of the space of probabilistic data structures and how they are used in approximation algorithm implementation.
  2. Models and Issues in Data Stream Systems
  3. Philippe Flajolet’s contribution to streaming algorithms : A presentation by Jérémie Lumbroso that visits some of the hostorical perspectives and how it all began with Flajolet
  4. Approximate Frequency Counts over Data Streams by Gurmeet Singh Manku & Rajeev Motwani : One of the early papers on the subject.
  5. [Methods for Finding Frequent Items in Data Streams](http://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.187.9800&rep=rep1&t
@ajdavis
ajdavis / README.md
Last active February 17, 2023 18:31
gprof on Python: How to statically compile Python 2.7.6 on Fedora 18, with some stdlib C modules, plus a hacked-up version of PyMongo and libbson

PYTHON

sudo yum install glibc-static zlib-static

download python source to /virtualenvs/nodict/Python-2.7.6

Configure to accomplish 3 things: static -pg TODO: NEEDED, ALONG WITH --enable-profiling ?? prefix

@tsiege
tsiege / The Technical Interview Cheat Sheet.md
Last active July 2, 2025 18:14
This is my technical interview cheat sheet. Feel free to fork it or do whatever you want with it. PLEASE let me know if there are any errors or if anything crucial is missing. I will add more links soon.

ANNOUNCEMENT

I have moved this over to the Tech Interview Cheat Sheet Repo and has been expanded and even has code challenges you can run and practice against!






\

@staltz
staltz / introrx.md
Last active July 7, 2025 10:24
The introduction to Reactive Programming you've been missing
@itamarhaber
itamarhaber / index.html
Last active March 29, 2019 02:26
Red is Beautiful: A Visualization of Redis Commands
<!DOCTYPE html>
<!--
Red is Beautiful: A Visualization of Redis Commands
By Itamar Haber, Redis Labs
Adopted from Mike Bostock's Zoomable Pack Layout example: http://mbostock.github.io/d3/talk/20111116/pack-hierarchy.html
!-->
<html>
<head>
<style>
@jbcrail
jbcrail / gdsii.lua
Last active August 21, 2020 11:45
Simple GDSII parser
-- A basic GDSII reader that reads from standard input and writes serialized
-- text to standard output
local gdsii = {}
gdsii.types = {
[0] = "HEADER",
[1] = "BGNLIB",
[2] = "LIBNAME",
[3] = "UNITS",
@hmartiro
hmartiro / zeromq-vs-redis.md
Last active December 16, 2024 04:02
Comparison of ZeroMQ and Redis for a robot control platform

ZeroMQ vs Redis

This document is research for the selection of a communication platform for robot-net.

Goal

The purpose of this component is to enable rapid, reliable, and elegant communication between the various nodes of the network, including controllers, sensors, and actuators (robot drivers). It will act as the core of robot-net to create a standardized infrastructure for robot control.

Requirements:

@PH111P
PH111P / relalgSql.hs
Last active October 7, 2019 09:35
Haskell: relational algebra to SQL converter
import Data.Char --for ord (Char -> Int)
data Query = Relation (String,[String]) -- (Relationenname, [Attributname])
| Projection [String] Query -- [Attributname]
| Selection String Query -- Bedingung
| Rename [(String,String)] Query -- [(alter Attributname, neuer Attributname)]
| Union Query Query
| Difference Query Query
| Product Query Query
deriving Show