Skip to content

Instantly share code, notes, and snippets.

🍪
om nom nom cookies

Aurélien Tamisier virtualtam

View GitHub Profile
@virtualtam
virtualtam / ring-of-arrays.go
Created Sep 9, 2018
Cellular Automaton - Ring of arrays with Go
View ring-of-arrays.go
package main
import "fmt"
import "container/ring"
import "math/rand"
type Cell struct {
alive bool
}
@virtualtam
virtualtam / Vex.jsx
Created Aug 4, 2017 — forked from wchargin/Vex.jsx
proof-of-concept: rendering musical notes in React
View Vex.jsx
import Vex from 'vexflow';
import React, {Component} from 'react';
const {
Accidental,
Formatter,
Stave,
StaveNote,
Renderer,
View how-to-make-a-racist-ai-without-really-trying.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@virtualtam
virtualtam / ubuntu-opencl-gpuarray.sh
Created Mar 5, 2017 — forked from jarutis/ubuntu.sh
Theano and Keras setup on ubuntu with OpenCL on AMD card
View ubuntu-opencl-gpuarray.sh
## install Catalyst proprietary
sudo ntfsfix /dev/sda2
sudo cp /etc/X11/xorg.conf /etc/X11/xorg.conf.BAK
sudo apt-get remove --purge fglrx*
sudo apt-get install linux-headers-generic
sudo apt-get install fglrx xvba-va-driver libva-glx1 libva-egl1 vainfo
sudo amdconfig --initial
## install build essentials
sudo apt-get install cmake
View rc30dump.sh
#!/bin/bash
#
# Backup, compress and normalize audio files from a BOSS RC-30 Loop Station
#
# Sequence:
# - dump audio content from the RC-30
# - encode and normalize audio
#
# Dependencies:
# - your favourite external storage mounting tool,
@virtualtam
virtualtam / ghrelease2changelog.py
Created Oct 16, 2016
Create a Markdown changelog from GitHub release notes
View ghrelease2changelog.py
#!/usr/bin/env python3
"""
Generates a Markdown changelog from GitHub release notes
See:
- http://keepachangelog.com/en/0.3.0/
- https://developer.github.com/v3/
"""
import json
from argparse import ArgumentParser
View add-jenkins-param.groovy
/**
* @file add-jenkins-param.groovy
* @brief Adds a parameter to selected jobs on a Jenkins instance
*
* The parameter is then exposed as an environment variable.
*/
import hudson.model.*
jobFilters = [
"filter1",
@virtualtam
virtualtam / addGroovyPostBuild.groovy
Created May 9, 2016 — forked from genericpenguin/addGroovyPostBuild.groovy
Jenkins Groovy script to add Groovy postbuild script to many projects
View addGroovyPostBuild.groovy
import hudson.model.FreeStyleProject
import hudson.model.Hudson
import hudson.tasks.Publisher
import org.jvnet.hudson.plugins.groovypostbuild.GroovyPostbuildRecorder
import org.jenkinsci.plugins.scriptsecurity.sandbox.groovy.SecureGroovyScript;
import org.jenkinsci.plugins.scriptsecurity.scripts.ClasspathEntry;
// Exclusion list for job names. Job names listed here will NOT have the groovy postbuild entry added.
def exclusion_list = ["some_job_that_doesnt_need_groovy_postbuild"]
@virtualtam
virtualtam / delicious.html
Created Mar 24, 2016 — forked from jgarber623/delicious.html
A sample of the Netscape Bookmark File Format as exported from Delicious.
View delicious.html
<!DOCTYPE NETSCAPE-Bookmark-file-1>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=UTF-8">
<!-- This is an automatically generated file.
It will be read and overwritten.
Do Not Edit! -->
<TITLE>Bookmarks</TITLE>
<H1>Bookmarks</H1>
<DL><p>
<DT><A HREF="https://developer.apple.com/library/mac/releasenotes/InterapplicationCommunication/RN-JavaScriptForAutomation/index.html#//apple_ref/doc/-%20uid/TP40014508" ADD_DATE="1414706885" PRIVATE="0" TAGS="javascript,mac,osx,yosemite">JavaScript for Automation Release Notes</A>
<DD>This article describes JavaScript for Automation, a new feature in OS X Yosemite.
@virtualtam
virtualtam / euclidean.clj
Created Mar 22, 2016 — forked from unthingable/euclidean.clj
Euclidean Rhythm generator in Clojure
View euclidean.clj
(defn split-seq [s]
"Extract a tail of all same elements: [1 1 0 0 0] -> [[1 1] [0 0 0]]"
(let [l (last s)]
(split-with #(not= l %) s)))
(defn recombine
"Distribute tail: [[1] [1] [1] [0] [0]] -> [[1 0] [1 0] [1]]"
([a b] [a b])
([a b c] [a b c])
([a b c & more]
You can’t perform that action at this time.