Skip to content

Instantly share code, notes, and snippets.

@karpathy
karpathy / min-char-rnn.py
Last active May 6, 2024 16:42
Minimal character-level language model with a Vanilla Recurrent Neural Network, in Python/numpy
"""
Minimal character-level Vanilla RNN model. Written by Andrej Karpathy (@karpathy)
BSD License
"""
import numpy as np
# data I/O
data = open('input.txt', 'r').read() # should be simple plain text file
chars = list(set(data))
data_size, vocab_size = len(data), len(chars)
@IanColdwater
IanColdwater / twittermute.txt
Last active April 22, 2024 17:26
Here are some terms to mute on Twitter to clean your timeline up a bit.
Mute these words in your settings here: https://twitter.com/settings/muted_keywords
ActivityTweet
generic_activity_highlights
generic_activity_momentsbreaking
RankedOrganicTweet
suggest_activity
suggest_activity_feed
suggest_activity_highlights
suggest_activity_tweet
@zmagg
zmagg / interview_prep.md
Last active August 17, 2023 22:14
How much prep did you do for the technical interviews?

How much prep did you do for the technical interviews?

I get asked this a lot so I thought I'd write it up to share. For context, I was interviewing for staff+ individual contributor roles at tech companies.

Technical Interviews

I was preparing to do some amount of live coding interviews, and some amount of pairing interviews.

Tech setup check-in

My friend Tom offered to do a pairing interview with me, which I also used to check my Zoom / screenshare setup. I screen shared from my 2019 XPS 13 for the pairing, but also had Zoom on an ipad for video/audio. I used Airpods for audio. This setup actually worked great, but it was nice to dial in some of the specifics--mic feedback from dialing in from two places, and just practice my schpiel about explaining what I was doing to the other person. Probably not useful for you unless you too, have Linux problems.

@beesandbombs
beesandbombs / squareZoom.pde
Created October 16, 2018 18:17
square zoom
// zooming squares. by dave
int[][] result;
float t, c;
float ease(float p) {
return 3*p*p - 2*p*p*p;
}
float ease(float p, float g) {
int[][] result;
float t, c;
float ease(float p) {
return 3*p*p - 2*p*p*p;
}
float ease(float p, float g) {
if (p < 0.5)
return 0.5 * pow(2*p, g);
@ftrain
ftrain / rhymes.clj
Last active July 14, 2023 22:20
Annotated rhyming dictionary
;; This is at: https://gist.github.com/8655399
;; So we want a rhyming dictionary in Clojure. Jack Rusher put up
;; this code here:
;;
;; https://gist.github.com/jackrusher/8640437
;;
;; I'm going to study this code and learn as I go.
;;
;; First I put it in a namespace.
@zephraph
zephraph / clean_node_modules.sh
Last active June 13, 2023 13:53
A shell script to clean up all node_modules in projects that haven't been touched in a couple weeks.
#!/bin/bash
DAYS_SINCE_LAST_CHANGE=14 # If a project hasn't been touched in this long its node_modules will be deleted
SEARCH_PATH="./Git" # Update this to the path where your code is stored
TOTAL_BYTES_REMOVED=0
Mb=1000000
Kb=1000
node_modules=$(find $SEARCH_PATH -name "node_modules" -type d -prune)
@jvcleave
jvcleave / openframeworks jetson nano.txt
Last active March 1, 2023 10:10
openframeworks jetson nano instructions
Nightly required - get link from the bottom of this page (e.g. https://openframeworks.cc/ci_server/versions/nightly/of_v20190324_linuxarmv7l_nightly.tar.gz)
https://openframeworks.cc/download/
Download OF and unpack:
wget https://openframeworks.cc/ci_server/versions/nightly/of_v20190324_linuxarmv7l_nightly.tar.gz
tar -zxvf of_v20190324_linuxarmv7l_nightly.tar.gz
mv of_v20190324_linuxarmv7l_nightly openFrameworks
@willjohnson
willjohnson / README.md
Last active April 26, 2022 19:32
Server Status Widget for Dashing

Description

A Dashing widget that checks whether a server is responding to either an http or ping request. It displays either a check or alert depending on the response.

Usage

@scottrigby
scottrigby / spin.sh
Created April 1, 2019 01:50
Shell script to begin or end a spinner background process
#!/bin/sh
help() {
cat << EOF
spin(1)
NAME
spin - begin or end a spinner background process
SYNOPSIS