Skip to content

Instantly share code, notes, and snippets.

@ingo-m
ingo-m / debian_install_cuda.md
Last active December 24, 2022 17:29
How to install CUDA on Debian

How to install CUDA on Debian 8 (Jessie)

This document describes how to install nvidia drivers & CUDA in one go on a fresh debian install.

Work in progress

Preparations

  • Start with a fresh Debian install.
@GrantTrebbin
GrantTrebbin / IndexingDemo_BinaryVersion.py
Created March 16, 2017 12:59
Rendering Animations for Hilbert Curves - Undocumented Scratch Code
import svgwrite
import math
# mogrify -format gif *.svg
# gifsicle --scale 0.2 --delay=5 --loop --optimize=2 --colors=256 --multifile *.gif > OutGIF/out.gif
order = 3
number_of_index_bits = order * 2
number_of_elements = pow(2, number_of_index_bits)
x_offset = 130
@nevsan
nevsan / json_numpy.py
Created July 25, 2015 03:00
JSON serialization support for NumPy ndarray objects.
from functools import partial
import io
import json
import numpy as np
def as_numpy(dct):
"""JSON decoder for NumPy ndarrays."""
if '__numpy__' in dct:
return np.load(io.BytesIO(dct['data'].encode('latin-1')))
return dct
@dropwhile
dropwhile / results.txt
Last active March 10, 2020 21:01
python compression comparison
Data Size:
Input: 2074
LZ4: 758 (0.37)
Snappy: 676 (0.33)
LZF: 697 (0.34)
ZLIB: 510 (0.25)
LZ4 / Snappy: 1.121302
LZ4 / LZF: 1.087518
LZ4 / ZLIB: 1.486275
Benchmark: 50000 calls