Skip to content

Instantly share code, notes, and snippets.

View aarondewindt's full-sized avatar

aarondewindt

View GitHub Profile
@aarondewindt
aarondewindt / diarize_existing_captions.py
Created September 27, 2025 11:46
Aaron whisper setup
#!/usr/bin/env python3
import os, math, argparse
from typing import List, Tuple, Optional, Dict
import torch
from pyannote.audio import Pipeline
import srt
import datetime as dt
import webvtt
# ---------- time helpers ----------
import qrcode
from pathlib import Path
import qrcode.image.svg
def main():
dir_path = Path(__file__).parent
urls = {
'dc_contact': 'https://delft-circuits.com/contact-us/',
'paper_2': 'https://doi.org/10.1063/5.0203101',
@aarondewindt
aarondewindt / docker.service
Last active October 22, 2025 17:28
Setup docker on the steamdeck
[Unit]
Description=Docker Application Container Engine
Documentation=https://docs.docker.com
After=network-online.target docker.socket firewalld.service containerd.service time-set.target
Wants=network-online.target containerd.service
Requires=docker.socket
[Service]
Type=notify
# the default is not to use systemd for cgroups because the delegate issues still
import numpy as np
import numpy.testing as npt
from itertools import product
b = np.array([
[0, 0, 0, 0, 0, 0, 0, 0, 0, 0,],
[0, 1, 0, 0, 0, 0, 1, 0, 1, 0,],
[0, 0, 1, 0, 0, 0, 0, 1, 0, 0,],
[0, 0, 0, 1, 0, 0, 0, 0, 1, 0,],
[0, 0, 0, 0, 0, 0, 0, 0, 0, 0,],
@aarondewindt
aarondewindt / fibonacci.rock
Created October 22, 2021 13:48
Fibonacci sequence in Rockstar
Listen to your heart
Fibonacci was without fear
The survivor is without cheer
Let the survivor be without Fibonacci
Let Fibonacci be nothing
My heart is lovestruck
Let my heart be with the survivor, the survivor
Say my heart without the survivor, the survivor
Whisper the survivor
@aarondewindt
aarondewindt / adt.py
Last active July 4, 2025 20:29
Experimental Algebraic Data Types implementation in Python 3.10
from dataclasses import dataclass
class ADTMeta(type):
def __new__(mcs, name, bases, namespace: dict):
adtc_class = super().__new__(mcs, name, bases, namespace)
if "__is_adt_variant__" in namespace:
if namespace["__is_adt_variant__"]:
return adtc_class