Skip to content

Instantly share code, notes, and snippets.

View odiroot's full-sized avatar
💭
It's complicated

Michal Odnous odiroot

💭
It's complicated
View GitHub Profile
@samdobson
samdobson / generate_cpu.py
Created October 14, 2025 01:37 — forked from simonw/generate_cpu.py
Claude Code generated script for running nanochat models on CPU on macOS
# /// script
# requires-python = ">=3.10"
# dependencies = [
# "torch",
# "tiktoken",
# "numpy",
# ]
# ///
"""
Standalone CPU-compatible text generation for the nanochat model.
@luser-dr00g
luser-dr00g / xcr.c
Created August 30, 2014 09:35
xcb+cairo hello world window
//xcr.c
//cc -o xcr $(pkg-config --cflags --libs cairo xcb xcb-icccm) xcr.c -lcairo -lxcb -lxcb-icccm
#include <stdlib.h>
#include <string.h>
#include <cairo.h>
#include <cairo-xcb.h>
#include <xcb/xcb.h>
#include <xcb/xcb_image.h>
#include <xcb/xcb_aux.h>
#include <xcb/xcb_icccm.h>