Skip to content

Instantly share code, notes, and snippets.

View skariel's full-sized avatar
🎯
Focusing

Ariel Keselman skariel

🎯
Focusing
  • Huawei / Senior Software Architect
  • Haifa, Israel
View GitHub Profile
#include <iostream>
#include <string>
#include <ctime>
using namespace std;
double* func_cpp(double a, double inc, double b) {
double* buff;
for (auto i=0; i<1000; i++) {
int len= (int)((b-a)/inc);
module GeometricalPredicates
# GeometricalPredicates_v0.2.9
#
# Fast, robust 2D and 3D geometrical predicates on generic point types.
# Implementation follows algorithms described in http://arxiv.org/abs/0901.4107
# and used (for e.g.) in the Illustris Simulation
# http://www.illustris-project.org/
#
# Author: Ariel Keselman (skariel@gmail.com)
module VoronoiDelaunay
# VoronoiDelaunay_v0.2.9
#
# Fast, robust 2D Voronoi/Delaunay tesselation
# Implementation follows algorithms described in http://arxiv.org/abs/0901.4107
# and used (for e.g.) in the Illustris Simulation
# http://www.illustris-project.org/
#
# Author: Ariel Keselman (skariel@gmail.com)

[JULIA] Faster than CGAL Delaunay

TL;DR

DelaunayJL is an incremental 2D Delaunay triangulation algorithm implemented in Julia, it is robust and ~20% faster than CGAL, the C++ de-facto industry standard. And it's MIT Licensed! all links to code are below

Show me the data!

The figure below shows how much time it takes to run a benchmark on my computer, an Intel Core i7-4800MQ CPU @ 2.7Ghz, 16GB RAM, Win8 64bit. The benchmark consists of inserting a number of points uniformly distributed. The benchmark is run 5 times for each number of points once for CGAL and once for Julia. The numbers of points used are 10K, 100K, 1M, and 10M. CGAL v4.4 was compiled with VS2013 64bit release mode, Julia is of version 0.3.0 Commit 7681878 (2014-08-20 20:43 UTC) x86_64-w64-mingw32 the delaunay code is here (see other gists of mine for complementing files... I'll compile this all into a library when I have the time)

Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
just testing
module nbody
using OctTrees
import OctTrees: modify, stop_cond, getx, gety, getz
immutable Particle <: AbstractPoint3D
_x::Float64
_y::Float64
_z::Float64
_m::Float64
@skariel
skariel / dev_run.py
Last active August 23, 2020 16:44
hot reloading automation for sqlc, quicktemplates etc
#!python -u
import os
import sys
import glob
import time
import signal
import queue
from subprocess import Popen, getoutput, PIPE
from multiprocessing import Process, Queue
from watchdog.observers import Observer