Skip to content

Instantly share code, notes, and snippets.

View valdo404's full-sized avatar

Laurent Valdes valdo404

View GitHub Profile
@amochtar
amochtar / README.md
Last active November 21, 2016 14:14
Xebia Essentials Dashing widget

Description

A Dashing widget to display a random Xebia Essentials card. Refreshes every 15 minutes.

Dependencies

The following dependencies are required. Please add them to your dashing gemfile.

require 'net/http'
require 'json'
@debasishg
debasishg / gist:8172796
Last active May 10, 2024 13:37
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
@shannah
shannah / not_working.m
Created October 6, 2012 21:02
JNI method that crashes
JNIEXPORT jstring JNICALL Java_ca_weblite_mactools_Sandbox_saveDialog
(JNIEnv *env, jobject jthis, jstring title, jstring extension){
JNF_COCOA_ENTER(env);
jstring path;
//@autoreleasepool {
NSString *cocoaExtension = JNFJavaToNSString(env, extension);
NSSavePanel *panel = [NSSavePanel savePanel];
NSArray *types = [NSArray arrayWithObjects: cocoaExtension,nil];
@jverkoey
jverkoey / gist:2985830
Created June 25, 2012 01:03
Memory mapping in Objective-C
const char* cstr = [string UTF8String];
void* anon = mmap(0, sizeof(char) * (string.length + 1), PROT_WRITE|PROT_READ, MAP_ANON|MAP_PRIVATE, 0, 0);
if (anon == MAP_FAILED) {
NSLog(@"Failed to map memory.");
return;
}
strcpy(anon, cstr);
// How do I get a file descriptor for use here?