Skip to content

Instantly share code, notes, and snippets.

@jarmitage
jarmitage / utter.js
Created Jun 22, 2022
Web Speech API utter()
View utter.js
let utter = u => speechSynthesis.speak(new SpeechSynthesisUtterance(u))
@jarmitage
jarmitage / track.tidal
Created May 18, 2022
Tidal track template
View track.tidal
do -- 'do blocks' run all the code below at the same time
setcps (120/60/4) -- 120 cycles per second with 4 beats per bar
let mx = [0,0,0,0] -- mixer (gain control) for each pattern
d1 $ stack [
s "bd*4",
s "[~ sn]*2",
s "[~ hc]*4"
] # gain (mx!!0) -- 1st item in mx list
d2
$ struct "t(3,8) t(5,8" -- structure
@jarmitage
jarmitage / readme.md
Last active Apr 8, 2022
Test running ONNX models on Bela via ROOT@CERN's SOFIE inference code generator
View readme.md

SOFIE

Code generation for fast inference of Deep Learning models ROOT/TMVA SOFIE (“System for Optimized Fast Inference code Emit”) is a new package introduced in this release that generates C++ functions easily invokable for the fast inference of trained neural network models. It takes ONNX model files as inputs and produces C++ header files that can be included and utilized in a “plug-and-go” style. This is a new development and it is currently still in experimental stage. SOFIE can take your trained ONNX model and generate blazingly fast C++ code from it, depending only on BLAS.

@jarmitage
jarmitage / example.svelte
Last active Jul 20, 2021
Svelte example...
View example.svelte
<script>
import { onMount } from 'svelte'
import { SomethingStore as Something } from '../../stores/somethingStore'
import Component from './Component.svelte'
$: stuff = $Something.stuff
let didMount = false
onMount(async () => {
@jarmitage
jarmitage / latex_to_speech.py
Created Jun 5, 2021
Latex to audiobook via Google Cloud TTS (tex to HTML to SSML to batches to gcloud)
View latex_to_speech.py
# super rough code!
# only supports simple tex + ssml
# requires sox for audio concatenation
# %autoawait - if in .ipynb, this is needed for async to work
import pypandoc
import html
import re
import os
@jarmitage
jarmitage / biccs21.bib
Created May 14, 2021
Proceedings of BICCS 2021 - Biennial International Conference for the Craft Sciences
View biccs21.bib
@article{aktasYouHaveOne2021,
title = {You {{Have One New Message}}: {{Knitting}} Intimacy for Connecting Opinions, People and the World},
shorttitle = {You {{Have One New Message}}},
author =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 ~ ~ d6 ~ ~ ~ d5 ~ ~ ~ fs5 ~ ~ ~ b5 ~ ~ ~ ~ ~ cs6 ~ d6 ~ e6 ~ fs6 ~ ~ ~ g6 ~ ~ ~ fs6 ~ ~ ~ e6 ~ ~ ~ g5 ~ ~ ~ b5 ~ ~ ~ cs6 ~ ~ ~ d5 ~ ~ ~ fs5 ~ ~ ~ b5 ~ ~ ~ ~ ~ ~ ~ e6 ~ ~ ~ fs6 ~ ~ ~ g6 ~ ~ ~ fs6 ~ ~ ~ e6 ~ ~ ~ g4 ~ ~ ~ ~ ~ ~ ~ d6 ~ ~ ~ fs6 ~ ~ ~ e6 ~ ~ ~ d6 ~ ~ ~ g5 ~ ~ ~ b5 ~ ~ ~ a5 ~ ~ ~ d5 ~ ~ ~ d5 ~ ~ ~ cs5 ~ ~ ~ a4 ~ ~ ~ ~ ~ ~ ~ fs5 ~ ~ ~
@jarmitage
jarmitage / progress.sty
Created Apr 2, 2021
progress.sty (by Kasper Graverson) but exports .csv of progress % as well
View progress.sty
%%
%% This is file `progress.sty',
%%
%% version 1.10
%%
%% Copyright (C) 2002-2003 Kasper B. Graversen - this is freeware
%%
%% Thanks to Robin Fairbairns for helping me sorting things out ;-)
%% Thanks to Dan Luecking for some definitions
%% Also thanks to David Bausum for his free 'trept' "TeX: Reference and Examples" information material
@jarmitage
jarmitage / TemplateTarget.hs
Created Oct 27, 2020
TidalCycles Template OSC Target (1.0.0 ≤ 1.6.2)
View TemplateTarget.hs
-- Target
:{
tmpTarget = Target {oName = "Template",
oAddress = "127.0.0.1",
oPort = 8000,
oLatency = 0.2,
oWindow = Nothing,
oSchedule = Pre BundleStamp
}
:}
@jarmitage
jarmitage / bw.hs
Created May 14, 2020
[WIP] Tidal to Bitwig OSC API v2
View bw.hs
-- Target
:{
bwTarget = Target {oName = "bitwig",
oAddress = "127.0.0.1",
oPort = 8000,
oLatency = 0.2,
oWindow = Nothing,
oSchedule = Pre BundleStamp
}
:}